change the color_ts in a better class anc rename VectorType in Vector
This commit is contained in:
parent
c992d4a830
commit
9640f3c527
@ -94,7 +94,7 @@ int32_t BufferEmpty::Display(ewol::OObject2DTextColored& OOTextNormal,
|
||||
tmpDisplay = "No Buffer Availlable to display";
|
||||
OOTextNormal.Text(textPos, tmpDisplay);
|
||||
|
||||
OOColored.SetColor(etk::color::color_White);
|
||||
OOColored.SetColor(etk::color::white);
|
||||
OOColored.Rectangle( 0, 0, sizeX, sizeY);
|
||||
|
||||
return ERR_NONE;
|
||||
|
@ -80,7 +80,7 @@ class classBufferManager: public ewol::EObject
|
||||
|
||||
private:
|
||||
|
||||
etk::VectorType<Buffer*> listBuffer; //!< element List of the char Elements
|
||||
etk::Vector<Buffer*> listBuffer; //!< element List of the char Elements
|
||||
|
||||
void RemoveAll(void); //!< remove all buffer
|
||||
int32_t m_idSelected;
|
||||
@ -148,7 +148,7 @@ void classBufferManager::OnReceiveMessage(ewol::EObject * CallerObject, const ch
|
||||
APPL_ERROR("Request select buffer ID = \"\" ");
|
||||
} else {
|
||||
int32_t newID = -1;
|
||||
sscanf(data.Utf8Data(), "%d", &newID);
|
||||
sscanf(data.c_str(), "%d", &newID);
|
||||
if(true == Exist(newID)) {
|
||||
m_idSelected = newID;
|
||||
} else {
|
||||
@ -192,7 +192,7 @@ void classBufferManager::OnReceiveMessage(ewol::EObject * CallerObject, const ch
|
||||
}
|
||||
} else {
|
||||
int32_t newId;
|
||||
sscanf(data.Utf8Data(), "%d", &newId);
|
||||
sscanf(data.c_str(), "%d", &newId);
|
||||
if (false == Exist(newId)) {
|
||||
APPL_ERROR("Request a save As with a non existant ID=" << newId);
|
||||
} else {
|
||||
@ -219,7 +219,7 @@ void classBufferManager::OnReceiveMessage(ewol::EObject * CallerObject, const ch
|
||||
APPL_DEBUG("Close specific buffer ID" << closeID);
|
||||
} else {
|
||||
// close specific buffer ...
|
||||
sscanf(data.Utf8Data(), "%d", &closeID);
|
||||
sscanf(data.c_str(), "%d", &closeID);
|
||||
APPL_DEBUG("Close specific buffer ID="<< closeID);
|
||||
}
|
||||
if(true == Exist(closeID)) {
|
||||
@ -260,7 +260,7 @@ void classBufferManager::OnReceiveMessage(ewol::EObject * CallerObject, const ch
|
||||
APPL_ERROR("Null data for changing buffer ID file ... ");
|
||||
} else {
|
||||
int32_t newId;
|
||||
sscanf(data.Utf8Data(), "%d", &newId);
|
||||
sscanf(data.c_str(), "%d", &newId);
|
||||
if (true == Exist(newId)) {
|
||||
m_idSelected = newId;
|
||||
} else {
|
||||
|
@ -125,7 +125,7 @@ BufferText::BufferText(etk::File &fileName) : Buffer(fileName)
|
||||
FILE * myFile = NULL;
|
||||
// try to open the file. if not existed, new file
|
||||
|
||||
myFile = fopen(fileName.GetCompleateName().Utf8Data(), "r");
|
||||
myFile = fopen(fileName.GetCompleateName().c_str(), "r");
|
||||
if (NULL != myFile) {
|
||||
m_EdnBuf.DumpFrom(myFile);
|
||||
// close the input file
|
||||
@ -152,7 +152,7 @@ void BufferText::Save(void)
|
||||
{
|
||||
APPL_INFO("Save File : \"" << GetFileName() << "\"" );
|
||||
FILE * myFile = NULL;
|
||||
myFile = fopen(GetFileName().GetCompleateName().Utf8Data(), "w");
|
||||
myFile = fopen(GetFileName().GetCompleateName().c_str(), "w");
|
||||
if (NULL != myFile) {
|
||||
m_EdnBuf.DumpIn(myFile);
|
||||
fclose(myFile);
|
||||
@ -225,7 +225,7 @@ void BufferText::DrawLineNumber(ewol::OObject2DTextColored* OOText, ewol::OObjec
|
||||
#define CURSOR_THICKNESS (1.2)
|
||||
void BufferText::DrawCursor(ewol::OObject2DColored* OOColored, int32_t x, int32_t y, int32_t letterHeight, int32_t letterWidth, clipping_ts &clip)
|
||||
{
|
||||
color_ts & tmpppppp = ColorizeManager::Get(COLOR_CODE_CURSOR);
|
||||
etk::Color & tmpppppp = ColorizeManager::Get(COLOR_CODE_CURSOR);
|
||||
OOColored->SetColor(tmpppppp);
|
||||
if (true == ewol::IsSetInsert()) {
|
||||
OOColored->Rectangle( x, y, letterWidth, letterHeight);
|
||||
@ -317,8 +317,8 @@ int32_t BufferText::Display(ewol::OObject2DTextColored& OOTextNormal,
|
||||
// Get color :
|
||||
Colorize * myColor = ColorizeManager::Get("normal");
|
||||
Colorize * myColorSel = ColorizeManager::Get("SelectedText");
|
||||
color_ts & myColorSpace = ColorizeManager::Get(COLOR_CODE_SPACE);
|
||||
color_ts & myColorTab = ColorizeManager::Get(COLOR_CODE_TAB);
|
||||
etk::Color & myColorSpace = ColorizeManager::Get(COLOR_CODE_SPACE);
|
||||
etk::Color & myColorTab = ColorizeManager::Get(COLOR_CODE_TAB);
|
||||
Colorize * selectColor = NULL;
|
||||
ewol::OObject2DTextColored* OOTextSelected = NULL;
|
||||
|
||||
@ -913,7 +913,7 @@ void BufferText::AddChar(uniChar_t unicodeData)
|
||||
bool haveSelectionActive = m_EdnBuf.GetSelectionPos(SelectionStart, SelectionEnd, SelectionIsRect, SelectionRectStart, SelectionRectEnd);
|
||||
if (unicodeData == 0x09) {
|
||||
if (false == haveSelectionActive) {
|
||||
etk::VectorType<int8_t> tmpVect;
|
||||
etk::Vector<int8_t> tmpVect;
|
||||
tmpVect.PushBack(0x09);
|
||||
m_EdnBuf.Insert(m_cursorPos, tmpVect);
|
||||
SetInsertPosition(m_cursorPos+1, true);
|
||||
@ -922,7 +922,7 @@ void BufferText::AddChar(uniChar_t unicodeData)
|
||||
// count the number of line :
|
||||
int32_t nbSelectedLines = m_EdnBuf.CountLines(SelectionStart, SelectionEnd);
|
||||
if (0 == nbSelectedLines) {
|
||||
etk::VectorType<int8_t> tmpVect;
|
||||
etk::Vector<int8_t> tmpVect;
|
||||
tmpVect.PushBack(0x09);
|
||||
m_EdnBuf.ReplaceSelected(tmpVect);
|
||||
SetInsertPosition(SelectionStart+tmpVect.Size(), true);
|
||||
@ -935,7 +935,7 @@ void BufferText::AddChar(uniChar_t unicodeData)
|
||||
}
|
||||
}
|
||||
} else if (unicodeData == '\n') {
|
||||
etk::VectorType<int8_t> tmpVect;
|
||||
etk::Vector<int8_t> tmpVect;
|
||||
if (true == ewol::IsSetShift()) {
|
||||
tmpVect.PushBack('\r');
|
||||
} else {
|
||||
@ -991,7 +991,7 @@ void BufferText::AddChar(uniChar_t unicodeData)
|
||||
if (true == m_EdnBuf.GetUTF8Mode()) {
|
||||
char tmpUTF8[16];
|
||||
unicode::convertUnicodeToUtf8(unicodeData, tmpUTF8);
|
||||
etk::VectorType<int8_t> tmpVect;
|
||||
etk::Vector<int8_t> tmpVect;
|
||||
int32_t localOfset = strlen(tmpUTF8);
|
||||
tmpVect.PushBack((int8_t*)tmpUTF8, localOfset);
|
||||
if (false == haveSelectionActive) {
|
||||
@ -1006,7 +1006,7 @@ void BufferText::AddChar(uniChar_t unicodeData)
|
||||
char output_ISO;
|
||||
unicode::convertUnicodeToIso(m_EdnBuf.GetCharsetType(), unicodeData, output_ISO);
|
||||
//printf(" insert : \"%s\"==> 0x%08x=%d ", UTF8data, (unsigned int)output_ISO, (int)output_ISO);
|
||||
etk::VectorType<int8_t> tmpVect;
|
||||
etk::Vector<int8_t> tmpVect;
|
||||
tmpVect.PushBack(output_ISO);
|
||||
if (false == haveSelectionActive) {
|
||||
m_EdnBuf.Insert(m_cursorPos, tmpVect);
|
||||
@ -1030,7 +1030,7 @@ int32_t BufferText::FindLine(etk::UString &data)
|
||||
return 0;
|
||||
}
|
||||
APPL_INFO("Search data line : \"" << data << "\"");
|
||||
etk::VectorType<uniChar_t> mVectSearch;
|
||||
etk::Vector<uniChar_t> mVectSearch;
|
||||
mVectSearch = data.GetVector();
|
||||
//APPL_INFO("search data Forward : startSearchPos=" << startSearchPos );
|
||||
/*
|
||||
|
@ -119,7 +119,7 @@ bool EdnBuf::DumpFrom(FILE *myFile)
|
||||
}
|
||||
|
||||
|
||||
void EdnBuf::GetAll(etk::VectorType<int8_t> &text)
|
||||
void EdnBuf::GetAll(etk::Vector<int8_t> &text)
|
||||
{
|
||||
// Clean output vector
|
||||
text.Clear();
|
||||
@ -128,9 +128,9 @@ void EdnBuf::GetAll(etk::VectorType<int8_t> &text)
|
||||
}
|
||||
|
||||
|
||||
void EdnBuf::SetAll(etk::VectorType<int8_t> &text)
|
||||
void EdnBuf::SetAll(etk::Vector<int8_t> &text)
|
||||
{
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
|
||||
// extract all data of the buffer :
|
||||
GetAll(deletedText);
|
||||
@ -148,7 +148,7 @@ void EdnBuf::SetAll(etk::VectorType<int8_t> &text)
|
||||
eventModification(0, m_data.Size(), deletedText);
|
||||
}
|
||||
|
||||
void EdnBuf::GetRange(int32_t start, int32_t end, etk::VectorType<int8_t> &output)
|
||||
void EdnBuf::GetRange(int32_t start, int32_t end, etk::Vector<int8_t> &output)
|
||||
{
|
||||
// Remove all data ...
|
||||
output.Clear();
|
||||
@ -162,14 +162,14 @@ void EdnBuf::GetRange(int32_t start, int32_t end, etk::UString &output)
|
||||
// Remove all data ...
|
||||
output = "";
|
||||
// import data :
|
||||
etk::VectorType<int8_t> localOutput;
|
||||
etk::Vector<int8_t> localOutput;
|
||||
m_data.Get(start, end-start, localOutput);
|
||||
// transcript in UNICODE ...
|
||||
if (true == m_isUtf8) {
|
||||
localOutput.PushBack('\0');
|
||||
output = (char*)&localOutput[0];
|
||||
} else {
|
||||
etk::VectorType<uniChar_t> tmpUnicodeData;
|
||||
etk::Vector<uniChar_t> tmpUnicodeData;
|
||||
// transform in unicode :
|
||||
convertIsoToUnicode(m_charsetType, localOutput, tmpUnicodeData);
|
||||
output = tmpUnicodeData;
|
||||
@ -202,7 +202,7 @@ int8_t EdnBuf::operator[] (int32_t pos)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
int32_t EdnBuf::Insert(int32_t pos, etk::VectorType<int8_t> &insertText)
|
||||
int32_t EdnBuf::Insert(int32_t pos, etk::Vector<int8_t> &insertText)
|
||||
{
|
||||
// if pos is not contiguous to existing text, make it
|
||||
pos = etk_avg(0, pos, m_data.Size() );
|
||||
@ -210,7 +210,7 @@ int32_t EdnBuf::Insert(int32_t pos, etk::VectorType<int8_t> &insertText)
|
||||
int32_t sizeInsert=LocalInsert(pos, insertText);
|
||||
|
||||
// Call the redisplay ...
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
eventModification(pos, insertText.Size(), deletedText);
|
||||
return sizeInsert;
|
||||
}
|
||||
@ -222,7 +222,7 @@ int32_t EdnBuf::Insert(int32_t pos, etk::UString &insertText)
|
||||
int32_t sizeInsert=LocalInsert(pos, insertText);
|
||||
|
||||
// Call the redisplay ...
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
eventModification(pos, insertText.Size(), deletedText);
|
||||
return sizeInsert;
|
||||
}
|
||||
@ -237,12 +237,12 @@ int32_t EdnBuf::Insert(int32_t pos, etk::UString &insertText)
|
||||
* @return nb Octet inserted
|
||||
*
|
||||
*/
|
||||
int32_t EdnBuf::Replace(int32_t start, int32_t end, etk::VectorType<int8_t> &insertText)
|
||||
int32_t EdnBuf::Replace(int32_t start, int32_t end, etk::Vector<int8_t> &insertText)
|
||||
{
|
||||
if (end-start == 0) {
|
||||
return 0;
|
||||
}
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
GetRange(start, end, deletedText);
|
||||
m_data.Replace(start, end-start, insertText);
|
||||
// update internal elements
|
||||
@ -255,16 +255,16 @@ int32_t EdnBuf::Replace(int32_t start, int32_t end, etk::UString &insertText)
|
||||
if (end-start == 0) {
|
||||
return 0;
|
||||
}
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
GetRange(start, end, deletedText);
|
||||
etk::VectorType<int8_t> tmpInsertText;
|
||||
etk::Vector<int8_t> tmpInsertText;
|
||||
if (true == m_isUtf8) {
|
||||
char * tmpPointer = insertText.Utf8Data();
|
||||
char * tmpPointer = insertText.c_str();
|
||||
while (*tmpPointer != '\0') {
|
||||
tmpInsertText.PushBack(*tmpPointer++);
|
||||
}
|
||||
} else {
|
||||
etk::VectorType<unsigned int> tmppp = insertText.GetVector();
|
||||
etk::Vector<unsigned int> tmppp = insertText.GetVector();
|
||||
convertUnicodeToIso(m_charsetType, tmppp, tmpInsertText);
|
||||
}
|
||||
if (tmpInsertText.Size()>0) {
|
||||
@ -296,7 +296,7 @@ int32_t EdnBuf::Replace(int32_t start, int32_t end, etk::UString &insertText)
|
||||
void EdnBuf::Remove(int32_t start, int32_t end)
|
||||
{
|
||||
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
// Make sure the arguments make sense
|
||||
if (start > end) {
|
||||
int32_t temp = start;
|
||||
@ -327,7 +327,7 @@ int32_t EdnBuf::Indent(void)
|
||||
// Get Range :
|
||||
int32_t l_start = StartOfLine(SelectionStart);
|
||||
int32_t l_end = EndOfLine(SelectionEnd);
|
||||
etk::VectorType<int8_t> l_tmpData;
|
||||
etk::Vector<int8_t> l_tmpData;
|
||||
GetRange(l_start, l_end, l_tmpData);
|
||||
|
||||
l_tmpData.Insert(0, '\n');
|
||||
@ -366,7 +366,7 @@ int32_t EdnBuf::UnIndent(void)
|
||||
// Get Range :
|
||||
int32_t l_start = StartOfLine(SelectionStart);
|
||||
int32_t l_end = EndOfLine(SelectionEnd);
|
||||
etk::VectorType<int8_t> l_tmpData;
|
||||
etk::Vector<int8_t> l_tmpData;
|
||||
GetRange(l_start, l_end, l_tmpData);
|
||||
|
||||
l_tmpData.Insert(0, '\n');
|
||||
@ -408,7 +408,7 @@ int32_t EdnBuf::UnIndent(void)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
void EdnBuf::GetLineText(int32_t pos, etk::VectorType<int8_t> &text)
|
||||
void EdnBuf::GetLineText(int32_t pos, etk::Vector<int8_t> &text)
|
||||
{
|
||||
GetRange( StartOfLine(pos), EndOfLine(pos), text);
|
||||
}
|
||||
@ -841,9 +841,9 @@ int32_t EdnBuf::CountLines(int32_t startPos, int32_t endPos)
|
||||
* @return number of line found
|
||||
*
|
||||
*/
|
||||
int32_t EdnBuf::CountLines(etk::VectorType<int8_t> &data)
|
||||
int32_t EdnBuf::CountLines(etk::Vector<int8_t> &data)
|
||||
{
|
||||
etk::VectorType<int8_t>::Iterator myPosIt = data.Begin();
|
||||
etk::Vector<int8_t>::Iterator myPosIt = data.Begin();
|
||||
int32_t lineCount = 0;
|
||||
|
||||
while(myPosIt) {
|
||||
@ -987,14 +987,14 @@ bool EdnBuf::charMatch(char first, char second, bool caseSensitive)
|
||||
*/
|
||||
bool EdnBuf::SearchForward(int32_t startPos, etk::UString &search, int32_t *foundPos, int32_t *foundPosEnd, bool caseSensitive)
|
||||
{
|
||||
etk::VectorType<int8_t> searchVect;
|
||||
etk::Vector<int8_t> searchVect;
|
||||
if (true == m_isUtf8) {
|
||||
char * tmpPointer = search.Utf8Data();
|
||||
char * tmpPointer = search.c_str();
|
||||
while (*tmpPointer != '\0') {
|
||||
searchVect.PushBack(*tmpPointer++);
|
||||
}
|
||||
} else {
|
||||
etk::VectorType<unsigned int> tmppp = search.GetVector();
|
||||
etk::Vector<unsigned int> tmppp = search.GetVector();
|
||||
convertUnicodeToIso(m_charsetType, tmppp, searchVect);
|
||||
}
|
||||
// remove the '\0' at the end of the string ...
|
||||
@ -1042,14 +1042,14 @@ bool EdnBuf::SearchForward(int32_t startPos, etk::UString &search, int32_t *foun
|
||||
*/
|
||||
bool EdnBuf::SearchBackward(int32_t startPos, etk::UString &search, int32_t *foundPos, int32_t *foundPosEnd, bool caseSensitive)
|
||||
{
|
||||
etk::VectorType<int8_t> searchVect;
|
||||
etk::Vector<int8_t> searchVect;
|
||||
if (true == m_isUtf8) {
|
||||
char * tmpPointer = search.Utf8Data();
|
||||
char * tmpPointer = search.c_str();
|
||||
while (*tmpPointer != '\0') {
|
||||
searchVect.PushBack(*tmpPointer++);
|
||||
}
|
||||
} else {
|
||||
etk::VectorType<unsigned int> tmppp = search.GetVector();
|
||||
etk::Vector<unsigned int> tmppp = search.GetVector();
|
||||
convertUnicodeToIso(m_charsetType, tmppp, searchVect);
|
||||
}
|
||||
// remove the '\0' at the end of the string ...
|
||||
@ -1181,7 +1181,7 @@ bool EdnBuf::SelectAround(int32_t startPos, int32_t &beginPos, int32_t &endPos)
|
||||
* @return number of element inserted.
|
||||
*
|
||||
*/
|
||||
int32_t EdnBuf::LocalInsert(int32_t pos, etk::VectorType<int8_t> &insertText)
|
||||
int32_t EdnBuf::LocalInsert(int32_t pos, etk::Vector<int8_t> &insertText)
|
||||
{
|
||||
// Insert data in buffer
|
||||
m_data.Insert(pos, insertText);
|
||||
@ -1192,14 +1192,14 @@ int32_t EdnBuf::LocalInsert(int32_t pos, etk::VectorType<int8_t> &insertText)
|
||||
}
|
||||
int32_t EdnBuf::LocalInsert(int32_t pos, etk::UString &insertText)
|
||||
{
|
||||
etk::VectorType<int8_t> tmpInsertText;
|
||||
etk::Vector<int8_t> tmpInsertText;
|
||||
if (true == m_isUtf8) {
|
||||
char * tmpPointer = insertText.Utf8Data();
|
||||
char * tmpPointer = insertText.c_str();
|
||||
while (*tmpPointer != '\0') {
|
||||
tmpInsertText.PushBack(*tmpPointer++);
|
||||
}
|
||||
} else {
|
||||
etk::VectorType<unsigned int> tmppp = insertText.GetVector();
|
||||
etk::Vector<unsigned int> tmppp = insertText.GetVector();
|
||||
convertUnicodeToIso(m_charsetType, tmppp, tmpInsertText);
|
||||
}
|
||||
if (tmpInsertText.Size()>0) {
|
||||
@ -1221,7 +1221,7 @@ int32_t EdnBuf::LocalInsert(int32_t pos, etk::UString &insertText)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
void EdnBuf::eventModification(int32_t pos, int32_t nInserted, etk::VectorType<int8_t> &deletedText)
|
||||
void EdnBuf::eventModification(int32_t pos, int32_t nInserted, etk::Vector<int8_t> &deletedText)
|
||||
{
|
||||
if( 0 == deletedText.Size()
|
||||
&& 0 == nInserted)
|
||||
|
@ -59,7 +59,7 @@ typedef struct {
|
||||
} selection;
|
||||
|
||||
typedef struct {
|
||||
etk::VectorType<colorInformation_ts> HLData;
|
||||
etk::Vector<colorInformation_ts> HLData;
|
||||
int32_t posHLPass1;
|
||||
int32_t posHLPass2;
|
||||
}displayHLData_ts;
|
||||
@ -74,24 +74,24 @@ class EdnBuf {
|
||||
// destructer
|
||||
~EdnBuf(void);
|
||||
// public function :
|
||||
void GetAll( etk::VectorType<int8_t> &text);
|
||||
void SetAll( etk::VectorType<int8_t> &text);
|
||||
void GetRange( int32_t start, int32_t end, etk::VectorType<int8_t> &output);
|
||||
void GetAll( etk::Vector<int8_t> &text);
|
||||
void SetAll( etk::Vector<int8_t> &text);
|
||||
void GetRange( int32_t start, int32_t end, etk::Vector<int8_t> &output);
|
||||
void GetRange( int32_t start, int32_t end, etk::UString &output);
|
||||
bool DumpIn( FILE *myFile);
|
||||
bool DumpFrom( FILE *myFile);
|
||||
// replace with operator [] ...
|
||||
int8_t operator[] (int32_t);
|
||||
int32_t Insert( int32_t pos, etk::VectorType<int8_t> &insertText);
|
||||
int32_t Insert( int32_t pos, etk::Vector<int8_t> &insertText);
|
||||
int32_t Insert( int32_t pos, etk::UString &insertText);
|
||||
int32_t Replace( int32_t start, int32_t end, etk::VectorType<int8_t> &insertText);
|
||||
int32_t Replace( int32_t start, int32_t end, etk::Vector<int8_t> &insertText);
|
||||
int32_t Replace( int32_t start, int32_t end, etk::UString &insertText);
|
||||
void Remove( int32_t start, int32_t end);
|
||||
int32_t Indent( void);
|
||||
int32_t UnIndent( void);
|
||||
|
||||
|
||||
void GetLineText( int32_t pos, etk::VectorType<int8_t> &text);
|
||||
void GetLineText( int32_t pos, etk::Vector<int8_t> &text);
|
||||
int32_t StartOfLine( int32_t pos);
|
||||
int32_t EndOfLine( int32_t pos);
|
||||
|
||||
@ -103,7 +103,7 @@ class EdnBuf {
|
||||
int32_t CountForwardDispChars( int32_t lineStartPos, int32_t nChars);
|
||||
int32_t CountLines( int32_t startPos, int32_t endPos);
|
||||
int32_t CountLines( void);
|
||||
int32_t CountLines( etk::VectorType<int8_t> &data);
|
||||
int32_t CountLines( etk::Vector<int8_t> &data);
|
||||
int32_t CountForwardNLines( int32_t startPos, int32_t nLines);
|
||||
int32_t CountBackwardNLines( int32_t startPos, int32_t nLines);
|
||||
|
||||
@ -126,10 +126,10 @@ class EdnBuf {
|
||||
void Unselect( void);
|
||||
void RectSelect( int32_t start, int32_t end, int32_t rectStart, int32_t rectEnd);
|
||||
bool GetSelectionPos( int32_t &start, int32_t &end, bool &isRect, int32_t &rectStart, int32_t &rectEnd);
|
||||
void GetSelectionText( etk::VectorType<int8_t> &text);
|
||||
void GetSelectionText( etk::Vector<int8_t> &text);
|
||||
void GetSelectionText( etk::UString &text);
|
||||
void RemoveSelected( void);
|
||||
int32_t ReplaceSelected( etk::VectorType<int8_t> &text);
|
||||
int32_t ReplaceSelected( etk::Vector<int8_t> &text);
|
||||
int32_t ReplaceSelected( etk::UString &text);
|
||||
private:
|
||||
// current selection of the buffer
|
||||
@ -145,15 +145,15 @@ class EdnBuf {
|
||||
private:
|
||||
bool m_isUndoProcessing;
|
||||
bool m_isRedoProcessing;
|
||||
etk::VectorType<EdnBufHistory*> m_historyUndo;
|
||||
etk::VectorType<EdnBufHistory*> m_historyRedo;
|
||||
etk::Vector<EdnBufHistory*> m_historyUndo;
|
||||
etk::Vector<EdnBufHistory*> m_historyRedo;
|
||||
|
||||
// -----------------------------------------
|
||||
// hightlight section :
|
||||
// -----------------------------------------
|
||||
private:
|
||||
Highlight * m_Highlight; //!< internal link with the Highlight system
|
||||
etk::VectorType<colorInformation_ts> m_HLDataPass1; //!< colorisation position in the current buffer pass 1
|
||||
etk::Vector<colorInformation_ts> m_HLDataPass1; //!< colorisation position in the current buffer pass 1
|
||||
void RegenerateHighLightAt(int32_t pos, int32_t nbDeleted, int32_t nbAdded);
|
||||
void GenerateHighLightAt(int32_t pos, int32_t endPos, int32_t addinPos=0);
|
||||
void CleanHighLight(void);
|
||||
@ -197,10 +197,10 @@ class EdnBuf {
|
||||
void removeSelected( selection &sel);
|
||||
void replaceSelected( selection &sel, const char *text);
|
||||
|
||||
void eventModification( int32_t pos, int32_t nInserted, etk::VectorType<int8_t> &deletedText);
|
||||
void eventModification( int32_t pos, int32_t nInserted, etk::Vector<int8_t> &deletedText);
|
||||
|
||||
|
||||
int32_t LocalInsert( int32_t pos, etk::VectorType<int8_t> &insertText);
|
||||
int32_t LocalInsert( int32_t pos, etk::Vector<int8_t> &insertText);
|
||||
int32_t LocalInsert( int32_t pos, etk::UString &insertText);
|
||||
|
||||
bool charMatch( char first, char second, bool caseSensitive = true);
|
||||
|
@ -39,7 +39,7 @@ EdnBufHistory::EdnBufHistory(void)
|
||||
m_nInserted = 0;
|
||||
}
|
||||
|
||||
EdnBufHistory::EdnBufHistory(int32_t pos, int32_t nInserted, etk::VectorType<int8_t> &deletedText)
|
||||
EdnBufHistory::EdnBufHistory(int32_t pos, int32_t nInserted, etk::Vector<int8_t> &deletedText)
|
||||
{
|
||||
//APPL_INFO("EdnBufHistory new + data");
|
||||
m_pos = pos;
|
||||
@ -47,7 +47,7 @@ EdnBufHistory::EdnBufHistory(int32_t pos, int32_t nInserted, etk::VectorType<int
|
||||
m_deletedText = deletedText;
|
||||
}
|
||||
|
||||
void EdnBufHistory::Set(int32_t pos, int32_t nInserted, etk::VectorType<int8_t> &deletedText)
|
||||
void EdnBufHistory::Set(int32_t pos, int32_t nInserted, etk::Vector<int8_t> &deletedText)
|
||||
{
|
||||
//APPL_INFO("EdnBufHistory new + data");
|
||||
m_pos = pos;
|
||||
@ -75,7 +75,7 @@ int32_t EdnBufHistory::getnbInserted(void)
|
||||
return m_nInserted;
|
||||
}
|
||||
|
||||
void EdnBufHistory::getData(etk::VectorType<int8_t> &deletedText)
|
||||
void EdnBufHistory::getData(etk::Vector<int8_t> &deletedText)
|
||||
{
|
||||
deletedText = m_deletedText;
|
||||
}
|
||||
|
@ -27,22 +27,22 @@
|
||||
#define __EDN_BUFFER_HISTORY_H__
|
||||
|
||||
|
||||
#include <etk/VectorType.h>
|
||||
#include <etk/Vector.h>
|
||||
|
||||
class EdnBufHistory{
|
||||
public:
|
||||
EdnBufHistory(void);
|
||||
EdnBufHistory(int32_t pos, int32_t nInserted, etk::VectorType<int8_t> &deletedText);
|
||||
EdnBufHistory(int32_t pos, int32_t nInserted, etk::Vector<int8_t> &deletedText);
|
||||
~EdnBufHistory(void);
|
||||
void Set(int32_t pos, int32_t nInserted, etk::VectorType<int8_t> &deletedText);
|
||||
void Set(int32_t pos, int32_t nInserted, etk::Vector<int8_t> &deletedText);
|
||||
int32_t getPos(void);
|
||||
int32_t getnbDeleted(void);
|
||||
int32_t getnbInserted(void);
|
||||
void getData(etk::VectorType<int8_t> &deletedText);
|
||||
void getData(etk::Vector<int8_t> &deletedText);
|
||||
private:
|
||||
int32_t m_pos;
|
||||
int32_t m_nInserted;
|
||||
etk::VectorType<int8_t> m_deletedText;
|
||||
etk::Vector<int8_t> m_deletedText;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -53,7 +53,7 @@ int32_t EdnBuf::Undo(void)
|
||||
int32_t pos = m_historyUndo[nbElement]->getPos();
|
||||
int32_t nbDeleted = m_historyUndo[nbElement]->getnbDeleted();
|
||||
int32_t nbInserted = m_historyUndo[nbElement]->getnbInserted();
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
m_historyUndo[nbElement]->getData(deletedText);
|
||||
m_isUndoProcessing = true;
|
||||
if (0 == nbInserted) {
|
||||
@ -101,7 +101,7 @@ int32_t EdnBuf::Redo(void)
|
||||
int32_t pos = m_historyRedo[nbElement]->getPos();
|
||||
int32_t nbDeleted = m_historyRedo[nbElement]->getnbDeleted();
|
||||
int32_t nbInserted = m_historyRedo[nbElement]->getnbInserted();
|
||||
etk::VectorType<int8_t> deletedText;
|
||||
etk::Vector<int8_t> deletedText;
|
||||
m_historyRedo[nbElement]->getData(deletedText);
|
||||
m_isRedoProcessing = true;
|
||||
if (0 == nbInserted) {
|
||||
|
@ -136,7 +136,7 @@ bool EdnBuf::GetSelectionPos(int32_t &start, int32_t &end, bool &isRect, int32_t
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
void EdnBuf::GetSelectionText(etk::VectorType<int8_t> &text)
|
||||
void EdnBuf::GetSelectionText(etk::Vector<int8_t> &text)
|
||||
{
|
||||
int32_t start, end, rectStart, rectEnd;
|
||||
bool isRect;
|
||||
@ -220,7 +220,7 @@ void EdnBuf::RemoveSelected(void)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
int32_t EdnBuf::ReplaceSelected(etk::VectorType<int8_t> &text)
|
||||
int32_t EdnBuf::ReplaceSelected(etk::Vector<int8_t> &text)
|
||||
{
|
||||
int32_t start, end, rectStart, rectEnd;
|
||||
bool isRect;
|
||||
|
@ -225,7 +225,7 @@ int8_t& EdnVectorBuf::Get(int32_t pos)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
void EdnVectorBuf::Get(int32_t pos, int32_t nbElement, etk::VectorType<int8_t> &tmpBuffer)
|
||||
void EdnVectorBuf::Get(int32_t pos, int32_t nbElement, etk::Vector<int8_t> &tmpBuffer)
|
||||
{
|
||||
tmpBuffer.Clear();
|
||||
if (pos < m_gapStart) {
|
||||
@ -397,7 +397,7 @@ void EdnVectorBuf::Insert(int32_t pos, const int8_t& item)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
void EdnVectorBuf::Insert(int32_t pos, etk::VectorType<int8_t>& items)
|
||||
void EdnVectorBuf::Insert(int32_t pos, etk::Vector<int8_t>& items)
|
||||
{
|
||||
if( pos > Size()
|
||||
|| pos < 0 ) {
|
||||
@ -453,7 +453,7 @@ void EdnVectorBuf::Replace(int32_t pos, const int8_t& item)
|
||||
* @return ---
|
||||
*
|
||||
*/
|
||||
void EdnVectorBuf::Replace(int32_t pos, int32_t nbRemoveElement, etk::VectorType<int8_t>& items)
|
||||
void EdnVectorBuf::Replace(int32_t pos, int32_t nbRemoveElement, etk::Vector<int8_t>& items)
|
||||
{
|
||||
if( pos > Size()
|
||||
|| pos < 0 ) {
|
||||
@ -650,7 +650,7 @@ void TestEdnVectorBuf(void)
|
||||
myBufferTmp.Display();
|
||||
plop='m';
|
||||
|
||||
etk::VectorType<int8_t> items;
|
||||
etk::Vector<int8_t> items;
|
||||
items.PushBack('i');
|
||||
items.PushBack('j');
|
||||
items.PushBack('k');
|
||||
|
@ -26,7 +26,7 @@
|
||||
#ifndef __EDN_VECTOR_BUF_H__
|
||||
#define __EDN_VECTOR_BUF_H__
|
||||
|
||||
#include <etk/VectorType.h>
|
||||
#include <etk/Vector.h>
|
||||
|
||||
#undef __class__
|
||||
#define __class__ "EdnVectorBuf"
|
||||
@ -271,14 +271,14 @@ class EdnVectorBuf
|
||||
EdnVectorBuf & operator=( const EdnVectorBuf & Evb);
|
||||
int8_t operator[] (int32_t pos);
|
||||
int8_t & Get( int32_t pos);
|
||||
void Get( int32_t pos, int32_t nbElement, etk::VectorType<int8_t> &tmpBuffer);
|
||||
void Get( int32_t pos, int32_t nbElement, etk::Vector<int8_t> &tmpBuffer);
|
||||
// insert functions
|
||||
void PushBack( const int8_t& item);
|
||||
void Insert( int32_t pos, const int8_t& item);
|
||||
void Insert( int32_t pos, etk::VectorType<int8_t>& items);
|
||||
void Insert( int32_t pos, etk::Vector<int8_t>& items);
|
||||
// Remove and insert functions
|
||||
void Replace( int32_t pos, const int8_t& item);
|
||||
void Replace( int32_t pos, int32_t nbRemoveElement, etk::VectorType<int8_t>& items);
|
||||
void Replace( int32_t pos, int32_t nbRemoveElement, etk::Vector<int8_t>& items);
|
||||
// Revove fonctions
|
||||
void Remove( int32_t pos, int32_t nbRemoveElement = 1);
|
||||
void PopBack( void);
|
||||
|
@ -35,8 +35,8 @@
|
||||
Colorize::Colorize( etk::UString &newColorName)
|
||||
{
|
||||
|
||||
m_colorFG = etk::color::color_Black;
|
||||
m_colorBG = etk::color::color_Black;
|
||||
m_colorFG = etk::color::black;
|
||||
m_colorBG = etk::color::black;
|
||||
|
||||
italic = false;
|
||||
bold = false;
|
||||
@ -50,8 +50,8 @@ Colorize::Colorize(void)
|
||||
{
|
||||
ColorName = "no_name";
|
||||
|
||||
m_colorFG = etk::color::color_Black;
|
||||
m_colorBG = etk::color::color_Black;
|
||||
m_colorFG = etk::color::black;
|
||||
m_colorBG = etk::color::black;
|
||||
|
||||
italic = false;
|
||||
bold = false;
|
||||
@ -89,14 +89,14 @@ etk::UString Colorize::GetName(void)
|
||||
void Colorize::SetFgColor(const char *myColor)
|
||||
{
|
||||
haveFG = true;
|
||||
m_colorFG = etk::color::Parse(myColor);
|
||||
m_colorFG = myColor;
|
||||
APPL_VERBOSE(myColor << " ==> "<< m_colorFG );
|
||||
}
|
||||
|
||||
void Colorize::SetBgColor(const char *myColor)
|
||||
{
|
||||
haveBG = true;
|
||||
m_colorBG = etk::color::Parse(myColor);
|
||||
m_colorBG = myColor;
|
||||
APPL_VERBOSE(myColor << " ==> "<< m_colorBG );
|
||||
}
|
||||
|
||||
|
@ -40,8 +40,8 @@ class Colorize {
|
||||
void SetFgColor(const char *myColor);
|
||||
void SetBgColor(const char *myColor);
|
||||
|
||||
color_ts & GetFG(void) { return m_colorFG; };
|
||||
color_ts & GetBG(void) { return m_colorBG; };
|
||||
etk::Color & GetFG(void) { return m_colorFG; };
|
||||
etk::Color & GetBG(void) { return m_colorBG; };
|
||||
|
||||
bool HaveBg(void);
|
||||
|
||||
@ -54,8 +54,8 @@ class Colorize {
|
||||
|
||||
private:
|
||||
etk::UString ColorName; //!< curent color Name
|
||||
color_ts m_colorFG;
|
||||
color_ts m_colorBG;
|
||||
etk::Color m_colorFG;
|
||||
etk::Color m_colorBG;
|
||||
|
||||
bool italic;
|
||||
bool bold;
|
||||
|
@ -61,16 +61,16 @@ class classColorManager: public ewol::EObject
|
||||
void LoadFile(const char * xmlFilename);
|
||||
Colorize * Get(const char *colorName);
|
||||
Colorize * Get(etk::UString &colorName);
|
||||
color_ts & Get(basicColor_te myColor);
|
||||
etk::Color& Get(basicColor_te myColor);
|
||||
bool Exist(etk::UString &colorName);
|
||||
bool Exist(const char *colorName);
|
||||
void DisplayListOfColor(void);
|
||||
|
||||
private:
|
||||
etk::UString m_fileColor;
|
||||
etk::VectorType<Colorize*> listMyColor; //!< List of ALL Color
|
||||
etk::UString m_fileColor;
|
||||
etk::Vector<Colorize*> listMyColor; //!< List of ALL Color
|
||||
Colorize * errorColor;
|
||||
color_ts basicColors[COLOR_NUMBER_MAX];
|
||||
etk::Color basicColors[COLOR_NUMBER_MAX];
|
||||
};
|
||||
|
||||
|
||||
@ -116,7 +116,7 @@ void classColorManager::OnReceiveMessage(ewol::EObject * CallerObject, const cha
|
||||
void classColorManager::LoadFile(etk::UString &xmlFilename)
|
||||
{
|
||||
// TODO : Remove this
|
||||
LoadFile(xmlFilename.Utf8Data());
|
||||
LoadFile(xmlFilename.c_str());
|
||||
}
|
||||
|
||||
// TODO : Remove this ...
|
||||
@ -225,7 +225,7 @@ void classColorManager::LoadFile(const char * xmlFilename)
|
||||
}
|
||||
const char *color = pGuiNode->ToElement()->Attribute("val");
|
||||
if (NULL != color) {
|
||||
basicColors[id] = etk::color::Parse(color);
|
||||
basicColors[id] = color;
|
||||
}
|
||||
} else {
|
||||
APPL_ERROR("(l "<<pGuiNode->Row()<<") node not suported : \""<<pGuiNode->Value()<<"\" must be [color]");
|
||||
@ -313,10 +313,10 @@ Colorize *classColorManager::Get(const char *colorName)
|
||||
Colorize *classColorManager::Get(etk::UString &colorName)
|
||||
{
|
||||
// TODO : Remove this
|
||||
return Get(colorName.Utf8Data());
|
||||
return Get(colorName.c_str());
|
||||
}
|
||||
|
||||
color_ts & classColorManager::Get(basicColor_te myColor)
|
||||
etk::Color & classColorManager::Get(basicColor_te myColor)
|
||||
{
|
||||
if (myColor < COLOR_NUMBER_MAX) {
|
||||
return basicColors[myColor];
|
||||
@ -342,7 +342,7 @@ bool classColorManager::Exist(const char *colorName)
|
||||
bool classColorManager::Exist(etk::UString &colorName)
|
||||
{
|
||||
// TODO : Remove this
|
||||
return Exist(colorName.Utf8Data());
|
||||
return Exist(colorName.c_str());
|
||||
}
|
||||
|
||||
void classColorManager::DisplayListOfColor(void)
|
||||
@ -417,9 +417,9 @@ Colorize* ColorizeManager::Get(etk::UString &colorName)
|
||||
return localManager->Get(colorName);
|
||||
}
|
||||
|
||||
color_ts errorColor;
|
||||
etk::Color errorColor;
|
||||
|
||||
color_ts& ColorizeManager::Get(basicColor_te myColor)
|
||||
etk::Color& ColorizeManager::Get(basicColor_te myColor)
|
||||
{
|
||||
if (NULL == localManager) {
|
||||
return errorColor;
|
||||
|
@ -57,7 +57,7 @@ namespace ColorizeManager
|
||||
void LoadFile(const char * xmlFilename);
|
||||
Colorize * Get(const char *colorName);
|
||||
Colorize * Get(etk::UString &colorName);
|
||||
color_ts & Get(basicColor_te myColor);
|
||||
etk::Color& Get(basicColor_te myColor);
|
||||
bool Exist(etk::UString &colorName);
|
||||
bool Exist(const char *colorName);
|
||||
void DisplayListOfColor(void);
|
||||
|
@ -72,7 +72,7 @@ void BufferView::OnReceiveMessage(ewol::EObject * CallerObject, const char * eve
|
||||
}
|
||||
|
||||
|
||||
color_ts BufferView::GetBasicBG(void)
|
||||
etk::Color BufferView::GetBasicBG(void)
|
||||
{
|
||||
return ColorizeManager::Get(COLOR_LIST_BG_1);
|
||||
}
|
||||
@ -82,7 +82,7 @@ uint32_t BufferView::GetNuberOfColomn(void)
|
||||
return 1;
|
||||
}
|
||||
|
||||
bool BufferView::GetTitle(int32_t colomn, etk::UString &myTitle, color_ts &fg, color_ts &bg)
|
||||
bool BufferView::GetTitle(int32_t colomn, etk::UString &myTitle, etk::Color &fg, etk::Color &bg)
|
||||
{
|
||||
myTitle = "Buffers : ";
|
||||
return true;
|
||||
@ -93,7 +93,7 @@ uint32_t BufferView::GetNuberOfRaw(void)
|
||||
return BufferManager::SizeOpen();
|
||||
}
|
||||
|
||||
bool BufferView::GetElement(int32_t colomn, int32_t raw, etk::UString &myTextToWrite, color_ts &fg, color_ts &bg)
|
||||
bool BufferView::GetElement(int32_t colomn, int32_t raw, etk::UString &myTextToWrite, etk::Color &fg, etk::Color &bg)
|
||||
{
|
||||
etk::File name;
|
||||
bool isModify;
|
||||
|
@ -54,11 +54,11 @@ class BufferView : public ewol::List
|
||||
virtual void OnReceiveMessage(ewol::EObject * CallerObject, const char * eventId, etk::UString data);
|
||||
protected:
|
||||
// function call to display the list :
|
||||
virtual color_ts GetBasicBG(void);
|
||||
virtual etk::Color GetBasicBG(void);
|
||||
virtual uint32_t GetNuberOfColomn(void);
|
||||
virtual bool GetTitle(int32_t colomn, etk::UString &myTitle, color_ts &fg, color_ts &bg);
|
||||
virtual bool GetTitle(int32_t colomn, etk::UString &myTitle, etk::Color &fg, etk::Color &bg);
|
||||
virtual uint32_t GetNuberOfRaw(void);
|
||||
virtual bool GetElement(int32_t colomn, int32_t raw, etk::UString &myTextToWrite, color_ts &fg, color_ts &bg);
|
||||
virtual bool GetElement(int32_t colomn, int32_t raw, etk::UString &myTextToWrite, etk::Color &fg, etk::Color &bg);
|
||||
virtual bool OnItemEvent(int32_t IdInput, ewol::eventInputType_te typeEvent, int32_t colomn, int32_t raw, float x, float y);
|
||||
private:
|
||||
int32_t m_selectedIdRequested;
|
||||
|
@ -56,10 +56,10 @@ CodeView::CodeView(void)
|
||||
|
||||
m_lineNumberList.Clear();
|
||||
|
||||
m_textColorFg = etk::color::color_Black;
|
||||
m_textColorFg = etk::color::black;
|
||||
|
||||
m_textColorBg = etk::color::color_Black;
|
||||
m_textColorBg.alpha = 0.25;
|
||||
m_textColorBg = etk::color::black;
|
||||
m_textColorBg.alpha = 0x40;
|
||||
SetCanHaveFocus(true);
|
||||
RegisterMultiCast(ednMsgBufferId);
|
||||
RegisterMultiCast(ednMsgGuiCopy);
|
||||
@ -292,7 +292,7 @@ void CodeView::OnReceiveMessage(ewol::EObject * CallerObject, const char * event
|
||||
m_lineNumberList[m_bufferID] = m_originScrooled;
|
||||
}
|
||||
int32_t bufferID = 0;
|
||||
sscanf(data.Utf8Data(), "%d", &bufferID);
|
||||
sscanf(data.c_str(), "%d", &bufferID);
|
||||
APPL_INFO("Select a new Buffer ... " << bufferID);
|
||||
// set the new buffer ID
|
||||
m_bufferID = bufferID;
|
||||
|
@ -49,11 +49,11 @@ class CodeView :public ewol::WidgetScrooled
|
||||
virtual bool CalculateMinSize(void);
|
||||
private:
|
||||
etk::UString m_label;
|
||||
color_ts m_textColorFg; //!< Text color
|
||||
color_ts m_textColorBg; //!< Background color
|
||||
etk::Color m_textColorFg; //!< Text color
|
||||
etk::Color m_textColorBg; //!< Background color
|
||||
int32_t m_bufferID;
|
||||
bool m_buttunOneSelected;
|
||||
etk::VectorType<Vector2D<float> > m_lineNumberList;
|
||||
etk::Vector<Vector2D<float> > m_lineNumberList;
|
||||
void UpdateNumberOfLineReference(int32_t bufferID);
|
||||
// drawing elements :
|
||||
ewol::OObject2DTextColored m_OObjectTextNormal;
|
||||
|
@ -273,7 +273,7 @@ void MainWindows::OnReceiveMessage(ewol::EObject * CallerObject, const char * ev
|
||||
if (data == "current") {
|
||||
m_currentSavingAsIdBuffer = BufferManager::GetSelected();
|
||||
} else {
|
||||
sscanf(data.Utf8Data(), "%d", &m_currentSavingAsIdBuffer);
|
||||
sscanf(data.c_str(), "%d", &m_currentSavingAsIdBuffer);
|
||||
}
|
||||
|
||||
if (false == BufferManager::Exist(m_currentSavingAsIdBuffer)) {
|
||||
|
@ -33,7 +33,7 @@
|
||||
#define __class__ "Highlight"
|
||||
|
||||
|
||||
void Highlight::ParseRules(TiXmlNode *child, etk::VectorType<HighlightPattern*> &mListPatern, int32_t level)
|
||||
void Highlight::ParseRules(TiXmlNode *child, etk::Vector<HighlightPattern*> &mListPatern, int32_t level)
|
||||
{
|
||||
// Create the patern ...
|
||||
HighlightPattern *myPattern = new HighlightPattern();
|
||||
@ -236,7 +236,7 @@ void Highlight::Display(void)
|
||||
// TODO : Celui qui appelle suprime des element pour rien ... Enfin c'est pas trègrave... Il suffirait juste de suprimer celuis d'avant si il n'est pas terminer...
|
||||
void Highlight::Parse(int32_t start,
|
||||
int32_t stop,
|
||||
etk::VectorType<colorInformation_ts> &metaData,
|
||||
etk::Vector<colorInformation_ts> &metaData,
|
||||
int32_t addingPos,
|
||||
EdnVectorBuf &buffer)
|
||||
{
|
||||
@ -300,7 +300,7 @@ void Highlight::Parse(int32_t start,
|
||||
*/
|
||||
void Highlight::Parse2(int32_t start,
|
||||
int32_t stop,
|
||||
etk::VectorType<colorInformation_ts> &metaData,
|
||||
etk::Vector<colorInformation_ts> &metaData,
|
||||
EdnVectorBuf &buffer)
|
||||
{
|
||||
//APPL_DEBUG("Parse element 0 => " << m_listHighlightPass2.size() << " ==> position search: (" << start << "," << stop << ")" );
|
||||
|
@ -59,19 +59,19 @@ class Highlight {
|
||||
void ReloadColor(void);
|
||||
void Parse(int32_t start,
|
||||
int32_t stop,
|
||||
etk::VectorType<colorInformation_ts> &metaData,
|
||||
etk::Vector<colorInformation_ts> &metaData,
|
||||
int32_t addingPos,
|
||||
EdnVectorBuf &buffer);
|
||||
void Parse2(int32_t start,
|
||||
int32_t stop,
|
||||
etk::VectorType<colorInformation_ts> &metaData,
|
||||
etk::Vector<colorInformation_ts> &metaData,
|
||||
EdnVectorBuf &buffer);
|
||||
private:
|
||||
void ParseRules(TiXmlNode *child, etk::VectorType<HighlightPattern*> &mListPatern, int32_t level);
|
||||
void ParseRules(TiXmlNode *child, etk::Vector<HighlightPattern*> &mListPatern, int32_t level);
|
||||
etk::UString m_styleName; //!< curent style name (like "c++" or "c" or "script Bash")
|
||||
etk::VectorType<etk::UString*> m_listExtentions; //!< List of possible extention for this high-light, like : ".c", ".cpp", ".h"
|
||||
etk::VectorType<HighlightPattern*> m_listHighlightPass1; //!< List of ALL hightlight modules (pass 1 ==> when we load and wride data on the buffer)
|
||||
etk::VectorType<HighlightPattern*> m_listHighlightPass2; //!< List of ALL hightlight modules (pass 2 ==> When we display the buffer( only the display area (100 lines)) )
|
||||
etk::Vector<etk::UString*> m_listExtentions; //!< List of possible extention for this high-light, like : ".c", ".cpp", ".h"
|
||||
etk::Vector<HighlightPattern*> m_listHighlightPass1; //!< List of ALL hightlight modules (pass 1 ==> when we load and wride data on the buffer)
|
||||
etk::Vector<HighlightPattern*> m_listHighlightPass2; //!< List of ALL hightlight modules (pass 2 ==> When we display the buffer( only the display area (100 lines)) )
|
||||
};
|
||||
|
||||
|
||||
|
@ -35,7 +35,7 @@
|
||||
class localClassHighlightManager: public ewol::EObject
|
||||
{
|
||||
private:
|
||||
etk::VectorType<Highlight*> listHighlight; //!< List of ALL hightlight modules
|
||||
etk::Vector<Highlight*> listHighlight; //!< List of ALL hightlight modules
|
||||
public:
|
||||
// Constructeur
|
||||
localClassHighlightManager(void) {
|
||||
|
@ -33,7 +33,7 @@ class HighlightPattern;
|
||||
|
||||
#include <etk/RegExp.h>
|
||||
#include <Colorize.h>
|
||||
#include <etk/VectorType.h>
|
||||
#include <etk/Vector.h>
|
||||
#include <tinyXML/tinyxml.h>
|
||||
#include <EdnVectorBuf.h>
|
||||
|
||||
@ -81,8 +81,8 @@ class HighlightPattern {
|
||||
bool m_haveStopPatern; //!< Stop patern presence
|
||||
bool m_multiline; //!< The patern is multiline
|
||||
uniChar_t m_escapeChar; //!< Escape char to prevent exeit of patern ....
|
||||
etk::VectorType<HighlightPattern *> m_subPatern; //!< Under patern of this one
|
||||
// etk::VectorType<HighlightPattern *> m_subColor; //!< Under Color in the start RegExp ...
|
||||
etk::Vector<HighlightPattern *> m_subPatern; //!< Under patern of this one
|
||||
// etk::Vector<HighlightPattern *> m_subColor; //!< Under Color in the start RegExp ...
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@ -344,7 +344,7 @@ void CTagsManager::JumpTo(void)
|
||||
/*
|
||||
m_currentList.Clear();
|
||||
if (NULL != m_ctagFile) {
|
||||
etk::VectorType<int8_t> data;
|
||||
etk::Vector<int8_t> data;
|
||||
// get the middle button of the clipboard ==> represent the current selection ...
|
||||
ClipBoard::Get(COPY_MIDDLE_BUTTON, data);
|
||||
if (data.Size() == 0) {
|
||||
|
@ -64,8 +64,8 @@ class CTagsManager: public etk::Singleton<CTagsManager>, public ewol::Widget
|
||||
// history system
|
||||
void AddToHistory(int32_t bufferID);
|
||||
int32_t m_historyPos;
|
||||
etk::VectorType<etk::File*> m_historyList;
|
||||
etk::VectorType<TagListFind_ts> m_currentList;
|
||||
etk::Vector<etk::File*> m_historyList;
|
||||
etk::Vector<TagListFind_ts> m_currentList;
|
||||
void JumpAtID(int32_t selectID);
|
||||
};
|
||||
*/
|
||||
|
@ -85,7 +85,7 @@ void APP_Init(void)
|
||||
// set color and other trucs...
|
||||
ColorizeManager::Init();
|
||||
etk::UString corlorFile = "color_white.xml";
|
||||
ColorizeManager::LoadFile( corlorFile.Utf8Data() );
|
||||
ColorizeManager::LoadFile( corlorFile.c_str() );
|
||||
ColorizeManager::DisplayListOfColor();
|
||||
|
||||
HighlightManager::Init();
|
||||
|
Loading…
x
Reference in New Issue
Block a user