From 4c97cf1fed4f2fe40f78612e8deb4f27ae22eb04 Mon Sep 17 00:00:00 2001 From: cxl Date: Mon, 6 Oct 2008 20:41:14 +0000 Subject: [PATCH] TheIDE got new code-browser git-svn-id: svn://ultimatepp.org/upp/trunk@511 f0d560ea-af0d-0410-9eb7-867de7ffcac7 --- uppsrc/CppBase/Base.cpp | 6 +- uppsrc/CppBase/CppBase.h | 16 +- uppsrc/CppBase/Parser.cpp | 105 ++++--- uppsrc/CppBase/Qualify.cpp | 4 +- uppsrc/CtrlLib/ArrayCtrl.cpp | 4 +- uppsrc/CtrlLib/DocEdit.cpp | 3 +- uppsrc/CtrlLib/EditCtrl.h | 2 +- uppsrc/CtrlLib/EditField.cpp | 2 +- uppsrc/CtrlLib/LineEdit.cpp | 6 +- uppsrc/CtrlLib/Text.cpp | 1 + uppsrc/CtrlLib/TextEdit.h | 3 +- uppsrc/ide/Assist.cpp | 58 ++-- uppsrc/ide/Bottom.cpp | 5 - uppsrc/ide/Browser/Base.cpp | 2 +- uppsrc/ide/Browser/Browser.cpp | 10 +- uppsrc/ide/Browser/Browser.h | 78 ++++-- uppsrc/ide/Browser/Browser.upp | 1 + uppsrc/ide/Browser/CodeBrowser.cpp | 168 ++++++++++++ uppsrc/ide/Browser/IdeTopic.cpp | 2 +- uppsrc/ide/Browser/ItemList.cpp | 81 +++--- uppsrc/ide/Browser/init | 2 +- uppsrc/ide/Common/Common.cpp | 4 +- uppsrc/ide/Common/Common.h | 4 +- uppsrc/ide/{Index.cpp => Navigator.cpp} | 160 ++++++----- uppsrc/ide/icon.ico | Bin 2862 -> 2862 bytes uppsrc/ide/ide.h | 52 ++-- uppsrc/ide/ide.iml | 351 ++++++++++++------------ uppsrc/ide/ide.key | 3 - uppsrc/ide/ide.upp | 2 +- uppsrc/ide/idebar.cpp | 13 +- uppsrc/ide/idefile.cpp | 2 +- uppsrc/ide/idetool.cpp | 18 +- uppsrc/ide/idewin.cpp | 2 +- 33 files changed, 704 insertions(+), 466 deletions(-) create mode 100644 uppsrc/ide/Browser/CodeBrowser.cpp rename uppsrc/ide/{Index.cpp => Navigator.cpp} (58%) diff --git a/uppsrc/CppBase/Base.cpp b/uppsrc/CppBase/Base.cpp index 9c4d96217..0b5a9337e 100644 --- a/uppsrc/CppBase/Base.cpp +++ b/uppsrc/CppBase/Base.cpp @@ -7,9 +7,9 @@ NAMESPACE_UPP void CppItem::Serialize(Stream& s) { - s % kind % access; - s % item % name % natural % at % tparam % param % pname - % tname % ctname % type % ptype % virt % line; + s % kind % access + % item % name % natural % at % tparam % param % pname + % tname % ctname % type % ptype % virt % line % impl; } struct CmpItem { diff --git a/uppsrc/CppBase/CppBase.h b/uppsrc/CppBase/CppBase.h index f846e5bbe..42173adb9 100644 --- a/uppsrc/CppBase/CppBase.h +++ b/uppsrc/CppBase/CppBase.h @@ -249,7 +249,7 @@ struct CppItem { void Serialize(Stream& s); - CppItem() { decla = false; virt = false; at = 0; } + CppItem() { at = decla = virt = false; qualify_type = qualify_param = true; serial = -1; } }; int FindItem(const Array& x, const String& qitem); @@ -268,12 +268,11 @@ struct CppBase : ArrayMap > { class Parser { struct Context { - String scopeing; + String scope; String ctname; Vector tparam; Index typenames; int access; - bool noclass; void operator<<=(const Context& t); @@ -370,10 +369,11 @@ class Parser { void ScopeBody(); void Do(); - CppItem& Item(const String& scopeing, const String& item, const String& name, bool impl); - CppItem& Item(const String& scopeing, const String& item, const String& name); + CppItem& Item(const String& scope, const String& item, const String& name, bool impl); + CppItem& Item(const String& scope, const String& item, const String& name); - CppItem& Fn(const Decl& d, const String& templ, bool body, int kind, const String& tname, const String& tparam); + CppItem& Fn(const Decl& d, const String& templ, bool body, + const String& tname, const String& tparam); struct Error {}; @@ -389,11 +389,11 @@ class Parser { public: struct FunctionStat { - FunctionStat(const String & scopeing, + FunctionStat(const String & scope, const CppItem & cppItem, const LexSymbolStat &symbolStat, int maxScopeDepth); - String scopeing; + String scope; const CppItem & cppItem; const LexSymbolStat &symbolStat; int maxScopeDepth; diff --git a/uppsrc/CppBase/Parser.cpp b/uppsrc/CppBase/Parser.cpp index de8a46ca9..bf03aad97 100644 --- a/uppsrc/CppBase/Parser.cpp +++ b/uppsrc/CppBase/Parser.cpp @@ -174,14 +174,14 @@ void ScAdd(String& s, const String& a) String Parser::Context::Dump() const { - return "Scopeing: " + scopeing; + return "Scopeing: " + scope; } -Parser::FunctionStat::FunctionStat(const String & scopeing, +Parser::FunctionStat::FunctionStat(const String & scope, const CppItem & cppItem, const LexSymbolStat &symbolStat, int maxScopeDepth) : - scopeing(scopeing), cppItem(cppItem), + scope(scope), cppItem(cppItem), symbolStat(symbolStat), maxScopeDepth(maxScopeDepth) { } @@ -197,11 +197,10 @@ inline void ScopeCat(String& scope, const String& s) void Parser::Context::operator<<=(const Context& t) { - scopeing = t.scopeing; + scope = t.scope; typenames <<= t.typenames; tparam <<= t.tparam; access = t.access; - noclass = t.noclass; ctname = t.ctname; } @@ -954,12 +953,12 @@ String CleanTp(const String& tp) void Parser::SetScopeCurrent() { - current_scope = context.scopeing; + current_scope = context.scope; } -CppItem& Parser::Item(const String& scopeing, const String& item, const String& name, bool impl) +CppItem& Parser::Item(const String& scope, const String& item, const String& name, bool impl) { - current_scope = scopeing; + current_scope = scope; if(dobody) current = CppItem(); current_key = item; @@ -972,14 +971,14 @@ CppItem& Parser::Item(const String& scopeing, const String& item, const String& im.line = line + 1; im.impl = impl; im.filetype = filetype; - LOG("New item " << GetCppFile(filei) << ' ' << line + 1 << " " << scopeing << "::" << item); + LLOG("New item " << GetCppFile(filei) << ' ' << line + 1 << " " << scope << "::" << item); return im; } -CppItem& Parser::Item(const String& scopeing, const String& item, const String& name) +CppItem& Parser::Item(const String& scope, const String& item, const String& name) { String h = Purify(item); - CppItem& im = Item(scopeing, h, name, false); + CppItem& im = Item(scope, h, name, false); im.natural = h; return im; } @@ -1080,17 +1079,16 @@ bool Parser::Scope(const String& tp, const String& tn) { } } if(Key(t_dblcolon)) - context.scopeing = Null; + context.scope = Null; String name; do { Check(lex.IsId(), "Missing identifier"); context.typenames.FindAdd(lex); name = lex.GetId(); - ScopeCat(context.scopeing, name); + ScopeCat(context.scope, name); } while(Key(t_dblcolon)); context.access = t == tk_class ? PRIVATE : PUBLIC; - context.noclass = false; if(tn.GetCount()) { if(context.ctname.GetCount()) context.ctname << ';'; @@ -1101,7 +1099,7 @@ bool Parser::Scope(const String& tp, const String& tn) { nn = "template " + tp + " "; String key = (t == tk_class ? "class" : t == tk_union ? "union" : "struct"); nn << key << ' ' << name; - CppItem& im = Item(context.scopeing, key, name, lex != ';'); + CppItem& im = Item(context.scope, key, name, lex != ';'); if(Key(';')) { context = cc; SetScopeCurrent(); @@ -1163,7 +1161,7 @@ String DeTemp(const char *s) return r; } -CppItem& Parser::Fn(const Decl& d, const String& templ, bool body, int kind, +CppItem& Parser::Fn(const Decl& d, const String& templ, bool body, const String& tname, const String& tparam) { String param; @@ -1186,7 +1184,7 @@ CppItem& Parser::Fn(const Decl& d, const String& templ, bool body, int kind, nn0 = d.name.Mid(0, q - 1); } String item = FnItem(d.natural, pname, d.name, nm); - String scopeing = context.scopeing; + String scope = context.scope; String nn; const char *s = nn0; int l = 0; @@ -1204,29 +1202,34 @@ CppItem& Parser::Fn(const Decl& d, const String& templ, bool body, int kind, s = nn; while(*s == ':') s++; if(*s) - ScopeCat(scopeing, s); - CppItem& im = Item(scopeing, item, nm, body); - if(!body || IsNull(im.natural)) { - im.natural.Clear(); - if(!IsNull(templ)) { - im.natural = TrimRight(Gpurify(templ)) + ' '; - im.at = im.natural.GetLength(); - } - im.natural << Purify(d.natural, d.name, nm); - im.kind = kind; - im.param = param; - im.pname = pname; - im.ptype = ptype; - im.access = context.access; - im.virt = d.s_virtual; - im.type = d.type; - im.decla = true; - im.tname = tname; - im.tparam = tparam; - im.ctname = context.ctname; - LLOG("FnItem: " << scopeing << "::" << item << ", natural: " << im.natural - << ", ctname: " << im.ctname); + ScopeCat(scope, s); + CppItem& im = Item(scope, item, nm, body); + im.natural.Clear(); + if(!IsNull(templ)) { + im.natural = TrimRight(Gpurify(templ)) + ' '; + im.at = im.natural.GetLength(); } + im.natural << Purify(d.natural, d.name, nm); + im.kind = templ.GetCount() ? IsNull(scope) ? FUNCTIONTEMPLATE + : d.s_static ? CLASSFUNCTIONTEMPLATE + : INSTANCEFUNCTIONTEMPLATE + : d.istructor ? (d.isdestructor ? DESTRUCTOR : CONSTRUCTOR) + : d.isfriend ? INLINEFRIEND + : IsNull(scope) ? FUNCTION + : d.s_static ? CLASSFUNCTION + : INSTANCEFUNCTION; + im.param = param; + im.pname = pname; + im.ptype = ptype; + im.access = context.access; + im.virt = d.s_virtual; + im.type = d.type; + im.decla = true; + im.tname = tname; + im.tparam = tparam; + im.ctname = context.ctname; + LLOG("FnItem: " << scope << "::" << item << ", natural: " << im.natural + << ", ctname: " << im.ctname); return im; } @@ -1280,11 +1283,7 @@ void Parser::Do() for(int i = 0; i < r.GetCount(); i++) { Decl& d = r[i]; if(!d.isfriend && d.function) { - CppItem& m = Fn(d, "template " + tparam + ' ', body, - context.noclass ? FUNCTIONTEMPLATE : - d.s_static ? CLASSFUNCTIONTEMPLATE : - INSTANCEFUNCTIONTEMPLATE, - tnames, tparam); + CppItem& m = Fn(d, "template " + tparam + ' ', body, tnames, tparam); functionItem = &m; } } @@ -1315,7 +1314,7 @@ void Parser::Do() String val; Check(lex.IsId(), "Expected identifier"); String id = lex.GetId(); - CppItem& im = Item(context.scopeing, id, id); + CppItem& im = Item(context.scope, id, id); im.natural = "enum "; if(!IsNull(name)) im.natural << name << ' '; @@ -1339,7 +1338,7 @@ void Parser::Do() const char *s = n; while(*s && iscid(*s)) name.Cat(*s++); - CppItem& im = Item(context.scopeing, n, name); + CppItem& im = Item(context.scope, n, name); im.kind = MACRO; s = strchr(n, '('); if(s) { @@ -1383,12 +1382,7 @@ void Parser::Do() Decl& d = r[i]; if(!d.isfriend || body) { if(d.function) { - CppItem &im = - Fn(d, Null, body, d.istructor ? (d.isdestructor ? DESTRUCTOR : CONSTRUCTOR) : - d.isfriend ? INLINEFRIEND : - context.noclass ? FUNCTION : - d.s_static ? CLASSFUNCTION : INSTANCEFUNCTION, - String(), String()); + CppItem &im = Fn(d, Null, body, String(), String()); functionItem = &im; } else { @@ -1396,7 +1390,7 @@ void Parser::Do() int q = h.Find('='); if(q >= 0) h = TrimRight(h.Mid(0, q)); - String scope = context.scopeing; + String scope = context.scope; if(d.type_def) ScopeCat(scope, d.name); CppItem& im = Item(scope, d.type_def ? "typedef" : d.name, d.name); @@ -1404,7 +1398,7 @@ void Parser::Do() im.type = im.ptype = d.type; im.access = context.access; im.kind = d.type_def ? TYPEDEF : - context.noclass ? VARIABLE : + IsNull(scope) ? VARIABLE : d.s_static ? CLASSVARIABLE : INSTANCEVARIABLE; } } @@ -1458,10 +1452,9 @@ void Parser::Do(Stream& in, const Vector& ignore, CppBase& _base, const try { current_scope.Clear(); context.access = PUBLIC; - context.noclass = true; context.typenames.Clear(); context.tparam.Clear(); - context.scopeing.Clear(); + context.scope.Clear(); inbody = false; for(int i = 0; i < typenames.GetCount(); i++) context.typenames.Add(lex.Id(typenames[i])); diff --git a/uppsrc/CppBase/Qualify.cpp b/uppsrc/CppBase/Qualify.cpp index c3d0b2844..4de352cd4 100644 --- a/uppsrc/CppBase/Qualify.cpp +++ b/uppsrc/CppBase/Qualify.cpp @@ -196,7 +196,7 @@ struct CmpCppItem { { int q = SgnCompare(a.qitem, b.qitem); if(q) return q < 0; - q = SgnCompare(a.kind, b.kind); + q = SgnCompare(a.IsType(), b.IsType()); if(q) return q < 0; q = SgnCompare(a.impl, b.impl); if(q) return a.IsType() ? q > 0 : q < 0; @@ -216,6 +216,8 @@ void QualifyPass2(CppBase& base) bool sort = false; for(int i = 0; i < n.GetCount(); i++) { CppItem& m = n[i]; + LLOG(base.GetKey(ni) << "::" << m.item << " " << GetCppFile(m.file) + << " impl:" << m.impl << " kind:" << (int)m.kind << " IsType:" << m.IsType()); if(m.serial != base.serial && !m.IsType()) { sort = true; m.serial = base.serial; diff --git a/uppsrc/CtrlLib/ArrayCtrl.cpp b/uppsrc/CtrlLib/ArrayCtrl.cpp index ce09f60e9..0330ed786 100644 --- a/uppsrc/CtrlLib/ArrayCtrl.cpp +++ b/uppsrc/CtrlLib/ArrayCtrl.cpp @@ -1880,7 +1880,7 @@ void ArrayCtrl::GotFocus() { void ArrayCtrl::DoEdit() { if(IsReadOnly()) return; - if(!editmode) + if(!editmode && IsCursor()) StartEdit(); } @@ -2026,7 +2026,7 @@ bool ArrayCtrl::FindSetCursor(const Value& val, int ii, int i) { i = Find(val, ii, i); if(i < 0) return false; if(!SetCursor(i)) return false; - CenterCursor(); +// CenterCursor(); //cxl: 2008-10-06: not what is expected... return true; } diff --git a/uppsrc/CtrlLib/DocEdit.cpp b/uppsrc/CtrlLib/DocEdit.cpp index 28054e173..9ff91b5f3 100644 --- a/uppsrc/CtrlLib/DocEdit.cpp +++ b/uppsrc/CtrlLib/DocEdit.cpp @@ -228,6 +228,7 @@ void DocEdit::PlaceCaret(bool scroll) { else sb.ScrollInto(cr.y, fy + 2); SetCaret(cr.x + 1, cr.y - sb, 1, fy); + WhenSel(); } void DocEdit::PlaceCaret(int newpos, bool select) { @@ -247,9 +248,9 @@ void DocEdit::PlaceCaret(int newpos, bool select) { } cursor = newpos; PlaceCaret(true); + SelectionChanged(); if(IsSelection()) SetSelectionSource(ClipFmtsText()); - SelectionChanged(); } int DocEdit::GetMousePos(Point p) diff --git a/uppsrc/CtrlLib/EditCtrl.h b/uppsrc/CtrlLib/EditCtrl.h index bc5fc6f29..b459cd092 100644 --- a/uppsrc/CtrlLib/EditCtrl.h +++ b/uppsrc/CtrlLib/EditCtrl.h @@ -202,7 +202,7 @@ public: EditField& SetFont(Font _font); EditField& ClickSelect(bool b = true) { clickselect = b; return *this; } EditField& InitCaps(bool b = true) { initcaps = b; return *this; } - EditField& NullText(const char *text = t_("(default)"), Color ink = Brown); + EditField& NullText(const char *text = t_("(default)"), Color ink = SColorDisabled); EditField& NullText(const char *text, Font fnt, Color ink); EditField& MaxChars(int mc) { maxlen = mc; return *this; } EditField& AutoSize(int maxcx = INT_MAX) { autosize = maxcx; Finish(); return *this; } diff --git a/uppsrc/CtrlLib/EditField.cpp b/uppsrc/CtrlLib/EditField.cpp index 6225eb714..6db967c77 100644 --- a/uppsrc/CtrlLib/EditField.cpp +++ b/uppsrc/CtrlLib/EditField.cpp @@ -973,7 +973,7 @@ EditField& EditField::NullText(const char *text, Font fnt, Color ink) EditField& EditField::NullText(const char *text, Color ink) { - return NullText(text, GetFont(), ink); + return NullText(text, GetFont().Italic(), ink); } EditField::EditField() diff --git a/uppsrc/CtrlLib/LineEdit.cpp b/uppsrc/CtrlLib/LineEdit.cpp index 15d126631..f86ea0d50 100644 --- a/uppsrc/CtrlLib/LineEdit.cpp +++ b/uppsrc/CtrlLib/LineEdit.cpp @@ -352,6 +352,7 @@ int LineEdit::PlaceCaretNoG(int newcursor, bool sel) { ScrollIntoCursor(); PlaceCaret0(p); SelectionChanged(); + WhenSel(); if(IsSelection()) SetSelectionSource(ClipFmtsText()); return p.x; @@ -361,8 +362,9 @@ void LineEdit::PlaceCaret(int newcursor, bool sel) { gcolumn = PlaceCaretNoG(newcursor, sel); } -void LineEdit::TopCursor() { - sb.SetY(GetLine(cursor)); +void LineEdit::TopCursor(int lines) +{ + sb.SetY(max(0, GetLine(cursor) - lines)); } void LineEdit::CenterCursor() { diff --git a/uppsrc/CtrlLib/Text.cpp b/uppsrc/CtrlLib/Text.cpp index ee8d8087b..029764c78 100644 --- a/uppsrc/CtrlLib/Text.cpp +++ b/uppsrc/CtrlLib/Text.cpp @@ -529,6 +529,7 @@ void TextCtrl::Redo() { void TextCtrl::ClearSelection() { anchor = -1; Refresh(); + WhenSel(); } void TextCtrl::SetSelection(int l, int h) { diff --git a/uppsrc/CtrlLib/TextEdit.h b/uppsrc/CtrlLib/TextEdit.h index 8a75dacb5..6b9478f5e 100644 --- a/uppsrc/CtrlLib/TextEdit.h +++ b/uppsrc/CtrlLib/TextEdit.h @@ -97,6 +97,7 @@ public: Callback1 WhenBar; Callback WhenState; + Callback WhenSel; void CachePos(int pos); @@ -281,7 +282,7 @@ public: Rect GetLineScreenRect(int line) const; - void TopCursor(); + void TopCursor(int lines = 0); void CenterCursor(); void MoveUpDown(int n, bool sel = false); diff --git a/uppsrc/ide/Assist.cpp b/uppsrc/ide/Assist.cpp index f16fbbdc4..07d088b8c 100644 --- a/uppsrc/ide/Assist.cpp +++ b/uppsrc/ide/Assist.cpp @@ -1,7 +1,7 @@ #include "ide.h" #define LDUMP(x) //DDUMP(x) -#define LDUMPC(x) //DUMPC(x) +#define LDUMPC(x) //DDUMPC(x) #define LLOG(x) //DLOG(x) class IndexSeparatorFrameCls : public CtrlFrame { @@ -28,19 +28,35 @@ AssistEditor::AssistEditor() auto_assist = true; commentdp = false; - InsertFrame(1, indexframe); - indexframe.Left(indexpane, HorzLayoutZoom(140)); - int q = indexpane.GetStdSize().cy; - indexpane.Add(searchindex.HSizePos().TopPos(0, q)); - indexpane.Add(index.HSizePos().VSizePos(q, 0)); - index.AddColumn("").Margin(2); + InsertFrame(1, navigatorframe); + navigatorframe.Left(navigatorpane, HorzLayoutZoom(140)); + + int cy = searchindex.GetStdSize().cy; + + indexpane.Add(searchindex.HSizePos().TopPos(0, cy)); + indexpane.Add(index.HSizePos().VSizePos(cy + 2, 0)); + index.AddColumn(""); index.AddIndex(); index.NoHeader().AutoHideSb().NoGrid(); - index.SetFrame(Single()); index.WhenLeftClick = index.WhenLeftDouble = THISBACK(IndexClick); + searchindex.NullText(String("Search (") + GetKeyDesc(IdeKeys::AK_SEARCHINDEX().key[0]) + ") "); searchindex.SetFilter(CharFilterAlphaToUpper); searchindex <<= THISBACK(SearchIndex); - showindex = true; + navigatorpane.Add(indexpane.SizePos()); + + scopepane.Add(browser.search_scope.HSizePos().TopPos(0, cy)); + scopepane.Add(browser.scope.HSizePos().VSizePos(cy + 2, 0)); + itempane.Add(browser.search_item.HSizePos().TopPos(0, cy)); + itempane.Add(browser.item.HSizePos().VSizePos(cy + 2, 0)); + scope_item.Vert(scopepane, itempane); + scope_item.SetPos(3000); + navigatorpane.Add(scope_item); + browser.scope.NoWantFocus(); + browser.item.NoWantFocus(); + browser.item.WhenLeftClick = browser.item.WhenLeftDouble = THISBACK(BrowserGoto); + browser.NameStart(); + + navigator = NAV_BROWSER; WhenAnnotationMove = THISBACK(SyncAnnotationPopup); Annotations(12); @@ -161,8 +177,8 @@ void AssistEditor::TypeOf(const String& id, Vector& r, bool& code) } if(IsNull(id)) { r.Add(parser.current_scope); - if(parser.current_scope != "::") - r.Add("::"); + if(parser.current_scope.GetCount()) + r.Add(Null); return; } int q = parser.local.FindLast(id); @@ -194,7 +210,7 @@ void AssistEditor::TypeOf(const String& id, Vector& r, bool& code) String dummy; if(q >= 0 && ScopeId(BrowserBase()[q], id, r, code, dummy)) return; - q = BrowserBase().Find("::"); + q = BrowserBase().Find(""); if(q >= 0) ScopeId(BrowserBase()[q], id, r, code, dummy); } @@ -281,7 +297,7 @@ void AssistEditor::GatherItems(const String& type, bool nom, Index& in_t if(q < 0) return; if(tp) { - if(ntp != "::") + if(ntp != "") ntp << "::"; int typei = assist_type.FindAdd(""); for(int i = 0; i < BrowserBase().GetCount(); i++) { @@ -309,7 +325,7 @@ void AssistEditor::GatherItems(const String& type, bool nom, Index& in_t if(im.IsType()) base = im.qptype; LDUMP(im.name); - if((im.IsCode() || im.IsData() || im.IsMacro() && type == "::") + if((im.IsCode() || im.IsData() || im.IsMacro() && type == "") && (nom || im.access == PUBLIC)) { if(im.IsCode()) { int q = assist_item.Find(im.name); @@ -670,7 +686,8 @@ bool AssistEditor::InCode() bool AssistEditor::Key(dword key, int count) { if(searchindex.HasFocus()) - return IndexKey(key); + return NavigatorKey(key); + if(popup.IsOpen()) { int k = key & ~K_CTRL; ArrayCtrl& kt = key & K_CTRL ? type : assist; @@ -878,9 +895,7 @@ void AssistEditor::DCopy() Context(ctx, l); String txt = Get(l, h - l); StringStream ss(txt); - String cls = ctx.current_scope.Mid(ctx.current_namespacel); - if(cls[0] == ':' && cls[1] == ':') - cls = cls.Mid(2); + String cls = ctx.current_scope; CppBase cpp; Parser parser; parser.Do(ss, IgnoreList(), cpp, Null, CNULL, Split(cls, ':')); @@ -1070,11 +1085,12 @@ void Ide::JumpToDefinition(const Array& n, int q) GotoCpp(n[q]); } -void Ide::IdeGotoLink(String link) +void Ide::IdeGotoCodeRef(String coderef) { - LLOG("IdeGotoLink " << link); + LLOG("IdeGotoLink " << coderef); + if(IsNull(coderef)) return; String scope, item; - SplitCodeRef(link, scope, item); + SplitCodeRef(coderef, scope, item); int q = BrowserBase().Find(scope); if(q < 0) return; diff --git a/uppsrc/ide/Bottom.cpp b/uppsrc/ide/Bottom.cpp index 6d48d4888..8c81b68ab 100644 --- a/uppsrc/ide/Bottom.cpp +++ b/uppsrc/ide/Bottom.cpp @@ -167,17 +167,12 @@ void Ide::SyncBottom() if(editor_bottom.GetZoom() >= 0) editor_bottom.NoZoom(); console.Show(q == BCONSOLE); - browser.Show(q == BBROWSER); calc.Show(q == BCALC); if(bottomctrl) bottomctrl->Show(q == BDEBUG); calc.LoadHlStyles(editor.StoreHlStyles()); calc.SetFont(editorfont); SetBar(); - if(q == BBROWSER) { - if(!browser.scopeing.IsCursor()) - browser.scopeing.GoBegin(); - } if(q == BCALC) ActiveFocus(calc); } diff --git a/uppsrc/ide/Browser/Base.cpp b/uppsrc/ide/Browser/Base.cpp index 9c3713eb2..8babc073e 100644 --- a/uppsrc/ide/Browser/Base.cpp +++ b/uppsrc/ide/Browser/Base.cpp @@ -3,7 +3,7 @@ #define LTIMING(x) // RTIMING(x) #define LLOG(x) -static const char s_dbver[] = "Assist++ 2.123"; +static const char s_dbver[] = "Assist++ 2.32"; void GC_Cache() { diff --git a/uppsrc/ide/Browser/Browser.cpp b/uppsrc/ide/Browser/Browser.cpp index e6bdbf9c1..dc614e0d0 100644 --- a/uppsrc/ide/Browser/Browser.cpp +++ b/uppsrc/ide/Browser/Browser.cpp @@ -140,15 +140,7 @@ void Browser::Reload() } } -int ItemCompare(const Value& v1, const Value& v2) -{ - const CppItemInfo& a = ValueTo(v1); - const CppItemInfo& b = ValueTo(v2); - int q = a.inherited - b.inherited; - if(q) return q; - q = SgnCompare(GetCppFile(a.file), GetCppFile(b.file)); - return q ? q : a.line - b.line; -} +int ItemCompare(const Value& v1, const Value& v2); void Browser::LoadNest(const String& scope, ArrayMap& item, int inherited, Index& rl) { diff --git a/uppsrc/ide/Browser/Browser.h b/uppsrc/ide/Browser/Browser.h index 7647843db..1b796f7a5 100644 --- a/uppsrc/ide/Browser/Browser.h +++ b/uppsrc/ide/Browser/Browser.h @@ -94,6 +94,56 @@ ArrayMap& FileSet(); int GetItemHeight(const CppItem& m, int cx); +struct CppItemInfoDisplay : public Display +{ + String hkey; + int htopic; + bool namestart; + + int DoPaint(Draw& w, const Rect& r, const Value& q, + Color _ink, Color paper, dword style) const; + virtual void Paint(Draw& w, const Rect& r, const Value& q, + Color _ink, Color paper, dword style) const; + virtual Size GetStdSize(const Value& q) const; + + CppItemInfoDisplay() { namestart = false; } +}; + +class ItemList : public ColumnList { + CppItemInfoDisplay display; + + friend struct ItemDisplay; + + int GetTopic(Point p, String& key); + String Item(int i); + +public: + bool active_topics; + + void Clear(); + + ItemList(); +}; + +class CodeBrowser { + typedef CodeBrowser CLASSNAME; + CppItemInfoDisplay display; + +public: + ArrayCtrl scope; + ArrayCtrl item; + EditString search_scope; + EditString search_item; + + void Load(); + void LoadScope(); + String GetCodeRef(); + void Goto(const String& coderef); + void NameStart() { display.namestart = true; } + + CodeBrowser(); +}; + struct BrowserQuery { String name; String package; @@ -120,34 +170,6 @@ struct QueryDlg : public WithQueryLayout { QueryDlg(); }; -struct CppItemInfoDisplay : public Display -{ - String hkey; - int htopic; - - int DoPaint(Draw& w, const Rect& r, const Value& q, - Color _ink, Color paper, dword style) const; - virtual void Paint(Draw& w, const Rect& r, const Value& q, - Color _ink, Color paper, dword style) const; - virtual Size GetStdSize(const Value& q) const; -}; - -class ItemList : public ColumnList { - CppItemInfoDisplay display; - - friend struct ItemDisplay; - - int GetTopic(Point p, String& key); - String Item(int i); - -public: - bool active_topics; - - void Clear(); - - ItemList(); -}; - class Browser : public StaticRect { public: void Serialize(Stream& s); diff --git a/uppsrc/ide/Browser/Browser.upp b/uppsrc/ide/Browser/Browser.upp index e607637be..9092e1c08 100644 --- a/uppsrc/ide/Browser/Browser.upp +++ b/uppsrc/ide/Browser/Browser.upp @@ -14,6 +14,7 @@ file Util.cpp, Item.cpp, ItemList.cpp, + CodeBrowser.cpp, Query.cpp, Browser.cpp, Browser.lay, diff --git a/uppsrc/ide/Browser/CodeBrowser.cpp b/uppsrc/ide/Browser/CodeBrowser.cpp new file mode 100644 index 000000000..6c68362e9 --- /dev/null +++ b/uppsrc/ide/Browser/CodeBrowser.cpp @@ -0,0 +1,168 @@ +#include "Browser.h" + +void CodeBrowser::Load() +{ + String match = ToUpper((String)~search_scope); + Vector txt; + Vector ndx; + Index fi; + for(int i = 0; i < BrowserBase().GetCount(); i++) { + String s = BrowserBase().GetKey(i); + if(s.GetCount()) { + if(ToUpper(s).Find(match) >= 0) { + txt.Add(s); + ndx.Add(s); + } + } + else { + const Array& n = BrowserBase()[i]; + int i = 0; + while(i < n.GetCount()) { + fi.FindAdd(n[i].file); + i = FindNext(n, i); + } + } + } + for(int i = 0; i < fi.GetCount(); i++) { + String s = GetCppFile(fi[i]); + s = '<' + GetFileName(GetFileFolder(s)) + '/' + GetFileName(s) + '>'; + if(ToUpper(s).Find(match) >= 0) { + txt.Add(s); + ndx.Add(fi[i]); + } + } + IndexSort(txt, ndx); + Value key = scope.GetKey(); + int sc = scope.GetCursorSc(); + scope.Clear(); + for(int i = 0; i < txt.GetCount(); i++) + scope.Add(IsString(ndx[i]) ? ndx[i] : Null, txt[i], ndx[i]); + if(scope.FindSetCursor(key)) + scope.ScCursor(sc); +} + +int ItemCompare(const Value& v1, const Value& v2) +{ + const CppItemInfo& a = ValueTo(v1); + const CppItemInfo& b = ValueTo(v2); + int q = a.inherited - b.inherited; + if(q) return q; + q = SgnCompare(GetCppFile(a.file), GetCppFile(b.file)); + return q ? q : a.line - b.line; +} + +void GatherMethods(const String& type, VectorMap& inherited, bool g) +{ + int q = BrowserBase().Find(type); + if(q < 0) return; + const Array& n = BrowserBase()[q]; + for(int i = 0; i < n.GetCount(); i = FindNext(n, i)) { + const CppItem& m = n[i]; + if(m.IsType()) { + Vector base = Split(m.qptype, ';'); + for(int i = 0; i < base.GetCount(); i++) + GatherMethods(base[i], inherited, true); + } + if(m.IsCode() && g) { + bool& virt = inherited.GetAdd(m.qitem); + virt = virt || m.virt; + } + } +} + +void CodeBrowser::LoadScope() +{ + String match = ~search_item; + Value key = item.GetKey(); + int sc = item.GetCursorSc(); + item.Clear(); + if(!scope.IsCursor()) + return; + Value x = scope.Get(2); + int file = IsNumber(x) ? (int)x : -1; + String scope = file < 0 ? String(x) : String(); + int q = BrowserBase().Find(scope); + if(q >= 0) { + const Array& n = BrowserBase()[q]; + VectorMap inherited; + if(file < 0) + GatherMethods(scope, inherited, false); + for(int i = 0; i < n.GetCount(); i = FindNext(n, i)) { + CppItemInfo m; + (CppItem&) m = n[i]; + if((file < 0 || m.file == file) && ToUpper(m.name).Find(match) >= 0) { + int q = inherited.Find(m.qitem); + if(q >= 0) { + m.over = true; + m.virt = m.virt || inherited[q]; + } + item.Add(m.qitem, RawToValue(m)); + } + } + } + item.Sort(1, ItemCompare); + if(item.FindSetCursor(key)) + item.ScCursor(sc); +} + +String CodeBrowser::GetCodeRef() +{ + if(scope.IsCursor() && item.IsCursor()) + return MakeCodeRef(scope.GetKey(), item.GetKey()); + return Null; +} + +int SearchScopeFilter(int c) +{ + c = ToUpper(c); + return IsAlNum(c) || c == '/' || c == '.' || c == '<' || c == '>' ? c : 0; +} + +int SearchItemFilter(int c) +{ + c = ToUpper(c); + return IsAlNum(c) ? c : 0; +} + +void CodeBrowser::Goto(const String& coderef) +{ + if(IsNull(coderef)) + item.KillCursor(); + else + if(coderef != GetCodeRef()) { + if(!IsNull(search_item) || !IsNull(search_scope)) { + search_scope <<= Null; + search_item <<= Null; + Load(); + LoadScope(); + } + String sc, im; + SplitCodeRef(coderef, sc, im); + if(IsNull(sc)) { + const CppItem *m = GetCodeRefItem(coderef); + if(m) + scope.FindSetCursor(m->file, 2); + } + else + scope.FindSetCursor(sc); + item.FindSetCursor(im); + } +} + +CodeBrowser::CodeBrowser() +{ + scope.AddKey(); + scope.AddColumn("Scope"); + scope.WhenSel = THISBACK(LoadScope); + scope.NoHeader().NoGrid(); + search_scope <<= THISBACK(Load); + search_scope.SetFilter(SearchScopeFilter); + search_scope.NullText("Search type or header "); + item.AddKey(); + item.AddColumn("Item").SetDisplay(display); + item.NoHeader(); + item.SetLineCy(BrowserFont().Info().GetHeight() + 3); + search_item.SetFilter(SearchItemFilter); + search_item.NullText("Search id "); + search_item <<= THISBACK(LoadScope); +} diff --git a/uppsrc/ide/Browser/IdeTopic.cpp b/uppsrc/ide/Browser/IdeTopic.cpp index d2016809e..79fd42cd4 100644 --- a/uppsrc/ide/Browser/IdeTopic.cpp +++ b/uppsrc/ide/Browser/IdeTopic.cpp @@ -17,7 +17,7 @@ static const char styles[] = void TopicEditor::JumpToDefinition() { - PostCallback(callback1(IdeGotoLink, editor.GetFormatInfo().label)); + PostCallback(callback1(IdeGotoCodeRef, editor.GetFormatInfo().label)); } void TopicEditor::Label(String& label) diff --git a/uppsrc/ide/Browser/ItemList.cpp b/uppsrc/ide/Browser/ItemList.cpp index 778b8b9bd..2779263d2 100644 --- a/uppsrc/ide/Browser/ItemList.cpp +++ b/uppsrc/ide/Browser/ItemList.cpp @@ -1,5 +1,42 @@ #include "Browser.h" +void PaintText(Draw& w, int& x, int y, const CppItemInfo& m, const Vector& n, + int starti, int count, bool focuscursor, Color _ink) +{ + for(int i = starti; i < count; i++) { + const ItemTextPart& p = n[i]; + Font f = BrowserFont(); + Color ink = SColorText; + switch(p.type) { + case ITEM_PNAME: + f.Bold(); + case ITEM_NUMBER: + ink = Red; + break; + case ITEM_TNAME: + ink = Green; + case ITEM_NAME: + f.Bold(); + break; + case ITEM_UPP: + ink = Cyan; + break; + case ITEM_CPP_TYPE: + case ITEM_CPP: + ink = LtBlue; + break; + case ITEM_SIGN: + ink = Magenta; + break; + } + if(m.overed) + f.Italic(); + Size fsz = GetTextSize(~m.natural + p.pos, f, p.len); + w.DrawText(x, y, ~m.natural + p.pos, f, focuscursor ? _ink : ink, p.len); + x += fsz.cx; + } +} + int CppItemInfoDisplay::DoPaint(Draw& w, const Rect& r, const Value& q, Color _ink, Color paper, dword style) const { @@ -93,38 +130,20 @@ int CppItemInfoDisplay::DoPaint(Draw& w, const Rect& r, const Value& q, int y = ry - Draw::GetStdFontCy() / 2; int x0 = x; Vector n = ParseItemNatural(m); - for(int i = 0; i < n.GetCount(); i++) { - ItemTextPart& p = n[i]; - Font f = BrowserFont(); - Color ink = SColorText; - switch(p.type) { - case ITEM_PNAME: - f.Bold(); - case ITEM_NUMBER: - ink = Red; - break; - case ITEM_TNAME: - ink = Green; - case ITEM_NAME: - f.Bold(); - break; - case ITEM_UPP: - ink = Cyan; - break; - case ITEM_CPP_TYPE: - case ITEM_CPP: - ink = LtBlue; - break; - case ITEM_SIGN: - ink = Magenta; - break; - } - if(m.overed) - f.Italic(); - Size fsz = GetTextSize(~m.natural + p.pos, f, p.len); - w.DrawText(x, y, ~m.natural + p.pos, f, focuscursor ? _ink : ink, p.len); - x += fsz.cx; + int starti = 0; + if(namestart) + for(int i = 0; i < n.GetCount(); i++) + if(n[i].type == ITEM_NAME) { + starti = i; + break; + } + PaintText(w, x, y, m, n, starti, n.GetCount(), focuscursor, _ink); + if(starti) { + const char *h = " : "; + w.DrawText(x, y, h, BrowserFont(), SColorText); + x += GetTextSize(h, BrowserFont()).cx; } + PaintText(w, x, y, m, n, 0, starti, focuscursor, _ink); if(m.virt || m.over) w.DrawRect(x0, r.bottom - 2, x - x0, 1, m.over ? m.virt ? LtRed : LtBlue : SColorText); if(m.inherited && m.IsType()) diff --git a/uppsrc/ide/Browser/init b/uppsrc/ide/Browser/init index a2de4d8de..96e744490 100644 --- a/uppsrc/ide/Browser/init +++ b/uppsrc/ide/Browser/init @@ -4,7 +4,7 @@ #include "ide\Common/init" #include "PdfDraw/init" #include "RichEdit/init" -#define BLITZ_INDEX__ F547B71646DBD1F21ED27EEFCF1ED888E +#define BLITZ_INDEX__ FF71BA1ADF44C21BEC9A2B5F74F6F89B1 #include "TopicI.icpp" #undef BLITZ_INDEX__ #endif diff --git a/uppsrc/ide/Common/Common.cpp b/uppsrc/ide/Common/Common.cpp index 92cee06e6..2161c1e2d 100644 --- a/uppsrc/ide/Common/Common.cpp +++ b/uppsrc/ide/Common/Common.cpp @@ -167,9 +167,9 @@ bool IdeConsoleWait() return the_ide && the_ide->IdeConsoleWait(); } -void IdeGotoLink(String s) +void IdeGotoCodeRef(String s) { - if(the_ide) the_ide->IdeGotoLink(s); + if(the_ide) the_ide->IdeGotoCodeRef(s); } void IdeSetBottom(Ctrl& ctrl) diff --git a/uppsrc/ide/Common/Common.h b/uppsrc/ide/Common/Common.h index 4ec422520..ca7fe5091 100644 --- a/uppsrc/ide/Common/Common.h +++ b/uppsrc/ide/Common/Common.h @@ -65,7 +65,7 @@ public: virtual bool IdeDebugUnLock() = 0; virtual bool IdeIsDebugLock() const = 0; virtual void IdeSetBar() = 0; - virtual void IdeGotoLink(String link) = 0; + virtual void IdeGotoCodeRef(String link) = 0; virtual ~IdeContext() {} }; @@ -89,7 +89,7 @@ void IdeConsoleFlush(); void IdeConsoleBeginGroup(String group); void IdeConsoleEndGroup(); bool IdeConsoleWait(); -void IdeGotoLink(String s); +void IdeGotoCodeRef(String s); bool IdeIsDebug(); void IdeEndDebug(); diff --git a/uppsrc/ide/Index.cpp b/uppsrc/ide/Navigator.cpp similarity index 58% rename from uppsrc/ide/Index.cpp rename to uppsrc/ide/Navigator.cpp index 19be50f98..a57839e08 100644 --- a/uppsrc/ide/Index.cpp +++ b/uppsrc/ide/Navigator.cpp @@ -1,14 +1,10 @@ #include "ide.h" -void AssistEditor::CreateIndex() +void AssistEditor::MakeIndex() { searchindex.Clear(); Renumber2(); indexitem.Clear(); - if(!assist_active) { - indexframe.Show(false); - return; - } const Index& cppkeywords = CppKeywords(); String sop = "operator"; String klass; @@ -128,22 +124,28 @@ void AssistEditor::CreateIndex() } } SyncIndex(); - SyncIndexCursor(); + SyncCursor(); +} + +void AssistEditor::SyncNavigator() +{ + if(navigator == NAV_INDEX) + MakeIndex(); + if(navigator == NAV_BROWSER) + browser.Load(); + navigatorframe.Show(navigator); } void AssistEditor::SyncIndex() { - searchindex.NullText(String("Search (") + GetKeyDesc(IdeKeys::AK_SEARCHINDEX().key[0]) + ") ", - StdFont().Italic(), SColorDisabled()); - bool b = indexitem.GetCount() && showindex && assist_active; - indexframe.Show(b); index.Clear(); - if(!b) return; - String s = ~searchindex; - for(int i = 0; i < indexitem.GetCount(); i++) { - const IndexItem& m = indexitem[i]; - if(s.GetCount() == 0 || ToUpper(m.text).Find(s) >= 0) - index.Add(AttrText(m.text).Ink(m.ink), m.line); + if(indexitem.GetCount() && navigator == NAV_INDEX && assist_active) { + String s = ~searchindex; + for(int i = 0; i < indexitem.GetCount(); i++) { + const IndexItem& m = indexitem[i]; + if(s.GetCount() == 0 || ToUpper(m.text).Find(s) >= 0) + index.Add(AttrText(m.text).Ink(m.ink), m.line); + } } } @@ -164,28 +166,37 @@ void AssistEditor::IndexClick() { IndexSync(); SetFocus(); - SyncIndexCursor(); + SyncCursor(); } -void AssistEditor::SyncIndexCursor() +void AssistEditor::SyncCursor() { - CodeEditor::SelectionChanged(); - if(!index.IsCursor()) - index.SetCursor(0); - if(!index.GetCount() || searchindex.HasFocus()) - return; - int ln = GetLine2(GetCursorLine()); - int ii = index.GetCursor(); - while(ii > 0 && (int)index.Get(ii, 1) > ln) - ii--; - while(ii < index.GetCount() - 1 && (int)index.Get(ii + 1, 1) <= ln) - ii++; - index.SetCursor(ii); + if(navigator == NAV_INDEX) { + if(!index.IsCursor()) + index.SetCursor(0); + if(!index.GetCount() || searchindex.HasFocus()) + return; + int ln = GetLine2(GetCursorLine()); + int ii = index.GetCursor(); + while(ii > 0 && (int)index.Get(ii, 1) > ln) + ii--; + while(ii < index.GetCount() - 1 && (int)index.Get(ii + 1, 1) <= ln) + ii++; + index.SetCursor(ii); + } + if(navigator == NAV_BROWSER) { + int ii = GetCursorLine(); + String coderef; + while(ii >= 0 && IsNull(coderef)) + coderef = GetAnnotation(ii--); + browser.Goto(coderef); + } } void AssistEditor::SelectionChanged() { - SyncIndexCursor(); + CodeEditor::SelectionChanged(); + SyncCursor(); } void AssistEditor::SearchIndex() @@ -195,62 +206,75 @@ void AssistEditor::SearchIndex() IndexSync(); } -bool AssistEditor::IndexKey(dword key) +void AssistEditor::BrowserGoto() { - switch(key) { - case K_ENTER: - case K_ESCAPE: - searchindex.Clear(); - SetFocus(); - SyncIndex(); - SyncIndexCursor(); - return true; - case K_UP: - case K_DOWN: - index.Key(key, 1); - IndexSync(); - return true; - } + IdeGotoCodeRef(browser.GetCodeRef()); + SetFocus(); +} + +bool AssistEditor::NavigatorKey(dword key) +{ + if(navigator == NAV_INDEX) + switch(key) { + case K_ENTER: + case K_ESCAPE: + searchindex.Clear(); + SetFocus(); + SyncIndex(); + SyncCursor(); + return true; + case K_UP: + case K_DOWN: + index.Key(key, 1); + IndexSync(); + return true; + } return false; } -bool AssistEditor::IsIndex() +void AssistEditor::Navigator(int nav) { - return showindex; -} - -void AssistEditor::ShowIndex(bool b) -{ - showindex = b; - indexframe.Show(showindex); - if(showindex) { - SetFocus(); - CreateIndex(); - SyncIndex(); - SyncIndexCursor(); + navigator = nav; + navigatorframe.Show(navigator); + switch(navigator) { + case NAV_INDEX: + scope_item.Hide(); + indexpane.Show(); + break; + case NAV_BROWSER: + indexpane.Hide(); + scope_item.Show(); + break; } + if(navigator) + SetFocus(); + SyncNavigator(); + if(navigator == NAV_INDEX) + SyncIndex(); + SyncCursor(); } -void AssistEditor::SerializeIndex(Stream& s) +void AssistEditor::SerializeNavigator(Stream& s) { - int version = 0; + int version = 1; s / version; - s % indexframe; - s % showindex; + s % navigatorframe; + s % navigator; + if(version >= 1) + s % scope_item; if(searchindex.HasFocus()) SetFocus(); - SyncIndex(); - SyncIndexCursor(); + Navigator(navigator); } -void Ide::ToggleIndex() +void Ide::ToggleNavigator(int nav) { - editor.ShowIndex(!editor.IsIndex()); + editor.Navigator(editor.GetNavigator() == nav ? 0 : nav); } void Ide::SearchIndex() { - editor.ShowIndex(true); + editor.Navigator(AssistEditor::NAV_INDEX); if(editor.index.IsVisible()) editor.searchindex.SetFocus(); } diff --git a/uppsrc/ide/icon.ico b/uppsrc/ide/icon.ico index 0f59e156aeb7ab9220b90f25ade109d43a3f73f2..17ff585b210f4de078b58b51c3099367e6542595 100644 GIT binary patch literal 2862 zcmcguOKaOe5dLiWA$m%WJ=K^%a}p#j4b3SK7au|{HMt3bSGE*6ie+S}hMWvNw71f_ zdHB-b;zKXJ_vaMUnUy8kavrV|Ixw1@o$s5Son0>ma!|0b0V$^i;0=uuzX<%Gx!B*z z0i|ca7Gp>&q&fKo_6heNC8V{odf)O{Y)BK~bUKx~LN19LjYc6Wg&hX`W5<~ddCfVlZ;@HfRk&^6lVZUiLGG`oPODxt{?&K3n?t_2} z81`dwHkRa%n3O?c@8!?(#dSqC>R`gZ1v6Iy*O_!|mM7y={Eq%}p4<6+gq)Z6y8>S( znc<^8FgN0JEa}aB<KqtzRrziz*W9?l=ZUHhzP-L=n(xNDykaa*1R z%@wFts@T&9IHU71JQuF%qgg+MV+#a>4r)6ZY!ThzLHi6xwgGqG!ml)Os5=n41-rH* z@yWT>Jq#Z>?@i&rzgWC$hHF9>w!8!P|GorzRC`)K)uS6Q%?Ey0n*z3fv2@3>@4+2@ zNujr8CQ2@cQb_?BDQdBZa;b#k-1AZ{mlC)_+u`QZEo z(m22L3v<4zLMarWrX^CY75`H`?K>MSI!#JX2dliZDSCM{S(d9B&yAm78DC#aCO5~| z<|Wz5l>gOJEJfD0ha36K#dfYcJQAVVbYZ@fzg}U3X%dXRP;gw~l zd+82$j(vaq9?#Y4+lLJ!I6e(=`vkG?x3BTst-r5<=lDwE=grIA3#@FO;c4uq=kym6 C;*hie diff --git a/uppsrc/ide/ide.h b/uppsrc/ide/ide.h index 7f48500e7..5235f96ba 100644 --- a/uppsrc/ide/ide.h +++ b/uppsrc/ide/ide.h @@ -365,17 +365,24 @@ struct AssistEditor : CodeEditor { virtual void LeftDown(Point p, dword keyflags); virtual void SelectionChanged(); - SplitterFrame indexframe; - EditString searchindex; - ArrayCtrl index; - StaticRect indexpane; - bool showindex; struct IndexItem : Moveable { String text; Color ink; int line; }; + byte navigator; + SplitterFrame navigatorframe; + StaticRect navigatorpane; + + EditString searchindex; + ArrayCtrl index; Vector indexitem; + ParentCtrl indexpane; + + CodeBrowser browser; + ParentCtrl scopepane; + ParentCtrl itempane; + Splitter scope_item; Splitter popup; ArrayCtrl assist; @@ -390,7 +397,7 @@ struct AssistEditor : CodeEditor { bool commentdp; bool inbody; Ide *theide; - + void PopUpAssist(bool auto_insert = false); void CloseAssist(); void Assist(); @@ -421,22 +428,29 @@ struct AssistEditor : CodeEditor { String IdBack(int& qq); void SwapSContext(Parser& p); - - void CreateIndex(); - + + void MakeIndex(); void SyncIndex(); void IndexSync(); void SearchIndex(); void IndexClick(); - void SyncIndexCursor(); - bool IndexKey(dword key); - bool IsIndex(); - void ShowIndex(bool b); - + void SyncCursor(); + + bool NavigatorKey(dword key); + void SyncNavigator(); + void BrowserGoto(); + + enum { NAV_NONE = 0, NAV_INDEX = 1, NAV_BROWSER = 2 }; + + int GetNavigator() const { return navigator; } + bool IsIndex() const { return navigator == NAV_INDEX; } + bool IsBrowser() const { return navigator == NAV_BROWSER; } + void Navigator(int navigator); + void SyncAnnotationPopup(); void Annotate(const String& filename); - void SerializeIndex(Stream& s); + void SerializeNavigator(Stream& s); typedef AssistEditor CLASSNAME; @@ -498,7 +512,7 @@ public: virtual bool IdeIsDebugLock() const; virtual void IdeSetBar(); - virtual void IdeGotoLink(String link); + virtual void IdeGotoCodeRef(String coderef); enum { EDITING, BUILDING, RUNNING, DEBUGGING, @@ -531,7 +545,7 @@ public: Browser browser; Ptr bottomctrl; - enum Bottoms { BCLOSE, BCONSOLE, BBROWSER, BCALC, BDEBUG }; + enum Bottoms { BCLOSE, BCONSOLE, BCALC, BDEBUG }; FileOut stdout_fout; @@ -906,13 +920,11 @@ public: void AutoSetup(); void BrowseMenu(Bar& menu); - void Query(); - void QueryWord(); void RescanCode(); void QueryId(); void About(); void OpenATopic(); - void ToggleIndex(); + void ToggleNavigator(int nav); void SearchIndex(); void Goto(); void GotoGlobal(); diff --git a/uppsrc/ide/ide.iml b/uppsrc/ide/ide.iml index 6673c93b5..df5b2cf0a 100644 --- a/uppsrc/ide/ide.iml +++ b/uppsrc/ide/ide.iml @@ -3681,172 +3681,181 @@ IMAGE_DATA(210,72,162,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0) IMAGE_END_DATA(113376, 12) IMAGE_BEGIN_DATA -IMAGE_DATA(120,156,237,156,59,136,173,73,17,199,79,232,186,6,34,138,201,98,38,226,35,209,104,17,4,67,35,3,229,26,173,137) -IMAGE_DATA(102,43,34,147,10,202,68,155,232,128,137,92,88,80,131,197,192,27,108,34,8,6,226,53,185,6,190,48,16,22,65,89) -IMAGE_DATA(6,124,32,200,34,27,44,46,11,159,83,231,206,111,246,63,255,169,234,238,239,156,51,115,103,214,174,161,56,115,190,175) -IMAGE_DATA(187,171,31,245,234,234,234,179,121,122,243,212,102,89,54,10,203,224,231,90,232,213,219,165,221,101,5,238,210,246,62,239) -IMAGE_DATA(123,245,218,159,79,109,158,246,133,233,17,223,101,225,70,158,245,190,223,181,118,246,155,159,167,106,137,105,17,204,184,208) -IMAGE_DATA(159,247,190,103,245,90,220,189,230,253,117,245,111,147,188,223,92,122,254,158,179,191,6,167,223,16,28,47,143,241,208,101) -IMAGE_DATA(41,175,35,236,213,165,253,101,233,211,58,94,174,226,72,217,145,62,95,71,217,128,101,229,252,173,128,247,158,253,93,35) -IMAGE_DATA(51,237,99,99,150,227,227,227,38,118,218,216,150,169,224,166,234,239,219,255,135,15,31,110,145,255,245,115,210,191,25,250) -IMAGE_DATA(254,121,67,244,55,155,195,251,104,109,168,148,65,41,5,6,85,189,227,152,140,1,244,118,214,212,213,54,178,186,173,182) -IMAGE_DATA(178,178,250,236,146,224,23,125,206,202,143,150,235,209,207,202,143,244,169,53,199,35,101,14,93,127,159,254,103,229,171,54) -IMAGE_DATA(70,203,173,93,191,53,252,179,47,255,82,127,77,27,192,198,160,156,120,131,75,149,14,236,25,244,52,89,23,119,5,173) -IMAGE_DATA(143,246,214,255,21,123,245,15,69,191,215,15,237,203,77,140,191,234,219,161,233,107,59,61,218,124,58,253,181,125,233,209) -IMAGE_DATA(247,62,248,255,135,26,255,158,248,100,161,80,6,173,14,246,6,147,77,210,165,250,103,79,175,224,166,177,24,214,198,109) -IMAGE_DATA(174,191,239,248,91,243,191,36,239,70,153,105,203,244,157,50,45,216,167,254,37,129,220,161,141,125,234,167,10,120,69,27) -IMAGE_DATA(251,212,47,13,192,96,27,55,175,60,174,41,102,48,60,97,157,114,139,125,86,207,70,104,12,11,142,254,127,124,252,184) -IMAGE_DATA(124,124,234,255,69,159,174,208,164,158,227,104,95,6,233,151,227,117,122,5,253,178,173,59,72,255,82,31,6,233,123,221) -IMAGE_DATA(43,125,72,214,174,85,167,236,207,64,217,39,7,30,222,191,127,255,254,18,168,101,244,153,190,171,158,101,245,179,239,254) -IMAGE_DATA(188,87,126,244,123,143,78,107,124,173,113,181,198,119,241,172,56,47,169,180,197,246,255,196,92,248,179,43,102,165,48,51) -IMAGE_DATA(163,102,104,213,251,30,157,162,189,145,113,245,231,199,206,75,42,213,222,192,227,65,220,173,252,40,104,249,222,166,209,203) -IMAGE_DATA(223,182,246,3,52,20,154,125,223,183,252,104,127,86,225,254,204,180,14,119,233,236,109,172,115,147,101,215,46,246,193,152) -IMAGE_DATA(99,79,102,218,21,188,133,249,253,230,190,235,130,142,124,223,133,222,24,196,174,172,1,207,156,225,201,25,62,56,39,112) -IMAGE_DATA(122,254,255,209,249,187,22,68,153,229,232,232,222,242,224,193,241,242,232,209,247,183,159,129,39,39,207,51,184,163,162,238) -IMAGE_DATA(131,103,159,253,216,114,122,250,224,76,166,30,110,241,228,172,157,163,103,62,112,241,61,222,69,153,243,254,92,162,27,207) -IMAGE_DATA(41,71,217,179,65,44,143,206,48,232,235,187,243,54,232,71,140,233,18,221,192,24,195,233,102,43,115,203,209,189,207,94) -IMAGE_DATA(105,251,124,44,219,185,138,178,250,126,91,63,250,77,253,162,125,230,217,251,23,115,21,253,62,21,140,103,90,38,234,176) -IMAGE_DATA(70,222,246,189,51,218,167,194,80,241,255,61,153,71,27,195,169,247,253,222,189,207,159,209,59,185,168,31,255,199,51,47) -IMAGE_DATA(7,111,164,253,127,244,104,91,47,240,244,244,180,213,255,35,127,247,120,126,158,191,208,176,71,71,71,87,198,120,206,79) -IMAGE_DATA(71,205,245,59,163,251,184,254,115,173,245,171,249,231,172,239,49,142,14,255,212,252,123,114,116,62,142,46,255,30,66,126) -IMAGE_DATA(128,117,242,123,205,105,29,25,100,154,110,77,221,236,251,62,35,200,180,238,104,255,174,106,113,253,107,155,245,188,189,145) -IMAGE_DATA(191,155,172,63,238,166,228,227,63,30,192,172,254,250,186,111,215,223,92,121,63,82,119,211,44,219,175,251,118,253,241,249) -IMAGE_DATA(186,93,112,104,101,208,203,107,145,252,150,178,126,143,153,123,245,247,165,223,131,145,250,231,142,64,186,73,94,83,127,87) -IMAGE_DATA(250,151,35,38,111,247,101,180,190,130,247,101,211,96,234,140,190,71,111,140,254,146,213,87,186,78,123,164,190,142,155,250) -IMAGE_DATA(228,85,141,210,247,57,247,131,190,108,14,178,250,90,119,201,249,119,209,250,59,242,239,254,82,252,4,18,62,119,173,183) -IMAGE_DATA(166,157,182,245,107,215,191,238,246,223,233,245,71,219,31,169,191,175,117,189,78,11,125,155,218,56,12,92,151,50,152,30) -IMAGE_DATA(66,219,66,174,181,208,113,92,176,11,253,168,247,216,74,94,254,92,67,95,143,44,158,4,253,108,252,163,235,87,205,123) -IMAGE_DATA(97,161,75,250,74,183,97,225,155,245,7,60,132,75,245,247,225,223,157,224,173,205,39,46,254,79,71,63,97,194,132,9) -IMAGE_DATA(19,38,76,152,48,97,194,132,9,19,38,76,152,48,97,194,132,59,9,255,125,243,173,11,252,199,191,95,95,254,250,247) -IMAGE_DATA(215,46,225,107,175,191,177,197,120,63,97,194,132,187,11,33,199,33,227,129,149,188,243,62,112,202,253,132,9,119,11,176) -IMAGE_DATA(215,33,203,127,122,245,95,203,195,63,188,186,252,244,209,159,151,151,126,246,251,18,227,125,148,139,242,232,0,108,255,132) -IMAGE_DATA(9,19,110,31,32,231,191,125,229,111,91,25,62,122,225,39,203,167,190,249,203,20,63,253,221,223,149,248,229,23,255,184) -IMAGE_DATA(156,252,240,231,91,249,71,246,167,220,79,152,112,59,32,252,111,236,114,200,248,71,190,244,157,229,195,207,221,95,62,254) -IMAGE_DATA(181,151,83,217,30,149,251,120,31,178,175,118,127,194,132,9,79,14,216,159,135,61,255,224,231,94,88,158,254,204,183,151) -IMAGE_DATA(143,126,229,71,87,236,121,200,126,60,15,93,16,229,192,208,11,241,28,221,224,58,32,190,71,153,176,247,216,250,9,227) -IMAGE_DATA(160,177,210,64,124,48,141,145,130,19,38,180,128,61,122,200,250,187,62,249,245,173,252,134,220,42,134,44,135,188,34,231) -IMAGE_DATA(161,15,2,163,124,96,252,31,207,227,61,126,129,202,127,200,124,124,143,114,65,39,236,252,255,59,111,170,220,250,185,71) -IMAGE_DATA(236,165,192,127,254,229,215,151,240,149,95,253,184,196,120,31,115,59,245,233,132,12,240,225,51,89,15,249,68,206,193,144) -IMAGE_DATA(229,144,217,248,12,91,29,120,239,27,47,94,200,63,242,174,136,236,35,239,241,44,104,6,254,191,0,114,29,114,200,158) -IMAGE_DATA(134,57,8,12,185,142,119,33,179,255,185,255,133,229,173,95,60,211,197,55,95,124,223,5,70,157,223,188,244,189,109,253) -IMAGE_DATA(136,153,78,121,159,144,1,188,134,205,110,201,122,96,148,9,249,198,246,16,139,11,185,143,119,239,255,226,15,202,186,129) -IMAGE_DATA(248,255,193,147,81,255,157,10,122,46,169,246,154,243,141,152,175,136,105,196,92,234,92,196,124,134,236,190,241,173,119,119) -IMAGE_DATA(229,27,25,215,179,145,88,207,121,22,58,33,3,108,77,240,92,216,118,228,52,147,213,120,134,191,30,117,130,183,56,123) -IMAGE_DATA(3,227,93,200,187,239,5,20,227,125,180,19,252,25,60,254,78,228,75,124,166,152,31,228,58,208,227,32,236,129,98,238) -IMAGE_DATA(144,247,168,139,204,171,124,171,13,119,25,143,186,156,121,206,61,252,132,12,212,143,175,236,178,250,226,216,118,228,84,109) -IMAGE_DATA(9,231,118,193,187,209,206,135,190,250,114,137,241,158,118,130,175,71,109,209,93,138,71,133,30,141,57,65,255,101,231,24) -IMAGE_DATA(33,239,161,99,67,215,226,99,225,47,133,79,30,246,29,84,59,142,142,157,242,125,123,224,46,240,166,218,118,98,241,149) -IMAGE_DATA(172,99,219,227,51,248,204,253,70,221,255,163,59,52,118,175,200,254,29,159,192,207,227,53,254,12,79,35,63,160,231,241) -IMAGE_DATA(140,234,11,205,17,172,144,125,182,215,243,252,193,214,250,18,251,228,220,2,57,199,174,163,247,136,129,16,131,195,143,87) -IMAGE_DATA(25,143,231,200,57,182,92,115,153,188,159,138,1,254,172,135,85,91,189,58,107,231,56,235,247,104,126,166,198,54,111,58) -IMAGE_DATA(167,51,235,175,242,38,177,82,197,94,91,189,249,26,69,95,15,5,252,205,204,182,35,235,30,103,11,222,196,6,49,142) -IMAGE_DATA(232,51,227,100,95,218,202,191,139,247,232,139,104,199,199,206,94,215,115,249,224,119,208,115,249,152,183,10,144,17,218,118) -IMAGE_DATA(204,214,44,218,244,188,66,232,19,103,115,154,232,191,200,95,208,115,202,152,99,124,159,144,251,120,31,242,140,223,158,217) -IMAGE_DATA(114,207,91,212,254,225,19,208,7,237,39,227,241,120,96,11,41,195,122,250,25,65,11,153,123,205,195,164,15,62,199,89) -IMAGE_DATA(238,165,198,53,116,159,200,123,0,126,166,175,89,29,218,62,164,220,171,140,103,121,166,45,222,100,28,153,158,235,241,228) -IMAGE_DATA(40,58,95,100,54,20,158,212,125,123,101,219,177,215,238,199,3,202,27,163,125,212,24,50,252,18,207,90,185,124,85,126) -IMAGE_DATA(79,236,141,57,227,203,198,203,58,69,219,148,207,48,124,157,40,131,206,14,221,228,253,81,186,65,147,187,3,74,43,234) -IMAGE_DATA(226,55,177,199,9,187,30,109,69,155,45,57,103,207,143,94,168,250,75,156,47,32,250,17,223,241,31,98,253,152,15,250) -IMAGE_DATA(210,26,119,172,49,186,156,177,51,238,170,14,227,65,223,192,27,65,171,170,67,191,209,17,232,255,106,126,233,19,250,7) -IMAGE_DATA(191,169,87,7,62,56,132,204,171,13,202,248,97,132,55,61,199,84,249,164,55,207,163,24,109,48,118,183,65,186,191,204) -IMAGE_DATA(124,121,183,237,193,179,236,51,145,83,159,75,61,59,238,217,19,100,82,117,53,249,124,200,134,231,247,176,23,208,247,58) -IMAGE_DATA(175,240,159,218,28,215,71,212,207,114,0,117,63,29,243,6,77,149,59,197,120,158,197,29,217,239,112,62,153,217,242,202) -IMAGE_DATA(158,99,31,136,159,86,57,141,180,29,60,196,185,72,96,244,9,29,131,46,98,159,21,239,178,113,199,243,120,31,125,196) -IMAGE_DATA(62,198,39,251,175,86,29,100,87,117,68,171,223,172,33,114,195,122,103,115,204,56,163,28,62,71,175,78,96,188,163,95) -IMAGE_DATA(251,158,247,98,135,224,7,165,171,252,201,184,56,203,206,198,18,136,14,70,78,98,158,91,60,57,138,186,134,172,135,202) -IMAGE_DATA(39,124,160,190,124,37,235,234,203,227,59,84,251,164,42,247,171,218,239,33,235,232,29,143,109,49,151,228,5,68,57,254) -IMAGE_DATA(39,247,207,215,58,202,32,243,244,81,227,146,89,189,248,142,124,147,63,20,232,186,39,139,175,123,46,1,103,147,209,222) -IMAGE_DATA(136,156,179,255,81,191,27,223,32,104,120,222,50,116,209,75,196,76,88,67,228,16,123,194,190,66,199,173,159,122,62,138) -IMAGE_DATA(239,21,237,122,236,193,243,36,53,230,234,253,174,228,157,92,45,205,209,202,114,56,65,252,74,198,160,117,178,117,129,247) -IMAGE_DATA(53,174,188,171,141,199,174,7,109,183,51,172,3,243,128,61,68,238,179,28,116,239,23,49,110,252,235,94,78,122,43,87) -IMAGE_DATA(157,121,210,125,16,227,70,87,194,43,26,127,119,121,215,243,51,124,240,67,221,117,195,15,64,214,99,62,60,159,143,53) -IMAGE_DATA(198,246,208,111,230,216,115,248,176,209,170,231,144,119,214,77,245,152,34,186,4,89,130,55,91,243,131,14,194,150,196,220) -IMAGE_DATA(198,184,136,189,233,89,154,198,219,67,206,163,63,236,255,56,139,195,127,66,6,171,126,106,31,225,47,157,47,245,131,25) -IMAGE_DATA(71,214,150,230,83,232,94,139,185,114,189,175,254,158,198,92,225,13,246,46,21,45,250,23,117,209,13,241,127,86,222,121) -IMAGE_DATA(0,61,6,237,170,14,114,133,125,218,37,239,136,253,118,38,235,240,39,115,199,60,104,140,86,231,64,121,154,190,179,55) -IMAGE_DATA(193,143,203,242,84,148,183,91,168,254,183,198,214,144,119,223,95,182,124,121,250,216,243,229,215,130,238,167,209,111,89,158) -IMAGE_DATA(143,202,174,230,147,100,243,68,27,186,6,186,183,172,248,94,243,136,162,12,99,100,237,88,163,202,239,193,190,195,243,26) -IMAGE_DATA(99,119,57,143,119,216,126,100,44,234,160,63,163,29,244,25,60,237,235,162,247,22,208,79,232,63,124,31,124,121,213,29) -IMAGE_DATA(85,238,147,234,83,16,222,200,234,168,190,209,120,77,207,126,40,45,124,25,214,191,242,45,221,95,81,25,212,53,241,88) -IMAGE_DATA(147,202,251,218,216,29,188,169,249,99,89,94,57,243,170,177,59,149,43,226,179,138,204,1,124,172,190,164,163,242,93,165) -IMAGE_DATA(219,176,199,42,39,238,127,179,111,112,254,111,249,242,180,229,186,99,87,64,62,124,62,157,110,32,113,32,141,191,86,252) -IMAGE_DATA(136,174,211,28,22,234,247,100,72,121,4,122,217,93,32,143,39,196,220,196,121,154,203,121,230,187,179,231,80,90,248,5) -IMAGE_DATA(232,165,108,108,154,151,204,119,100,29,91,137,14,84,95,222,125,33,207,115,102,124,248,229,129,170,231,156,62,232,251,59) -IMAGE_DATA(250,237,178,171,125,86,221,8,61,228,221,199,167,58,130,56,5,235,143,94,201,202,107,29,104,172,149,119,98,61,204,79) -IMAGE_DATA(149,111,202,62,3,59,232,188,89,205,53,227,33,46,160,72,60,151,253,139,235,105,183,247,248,50,106,143,221,255,206,206) -IMAGE_DATA(225,42,219,142,220,121,174,230,62,224,182,61,155,207,248,212,92,20,246,135,110,179,50,255,70,229,221,247,0,149,207,132) -IMAGE_DATA(46,213,51,149,74,191,163,171,217,159,103,114,238,178,174,241,158,108,127,4,159,169,30,118,57,203,236,171,158,209,169,173) -IMAGE_DATA(101,127,81,241,30,237,101,126,57,242,164,119,159,188,142,239,247,53,190,87,245,27,221,200,184,145,41,149,247,172,14,126) -IMAGE_DATA(4,244,92,71,100,117,24,211,90,127,148,115,43,229,151,204,30,250,26,234,217,168,158,71,86,88,149,97,63,136,238,204) -IMAGE_DATA(108,141,242,33,122,23,185,200,236,113,182,119,207,236,187,238,221,153,111,215,149,126,71,115,4,163,63,202,31,153,172,243) -IMAGE_DATA(127,118,78,65,140,169,218,219,168,236,194,251,45,127,0,157,166,254,181,238,97,53,174,128,188,18,135,83,95,189,178,233) -IMAGE_DATA(196,83,84,183,160,199,130,142,250,242,196,20,93,110,180,207,244,149,53,246,243,95,229,31,189,219,212,147,39,245,229,91) -IMAGE_DATA(242,164,49,11,245,9,90,58,130,126,248,89,121,171,14,190,60,249,26,172,229,232,152,244,236,123,84,222,71,246,186,190) -IMAGE_DATA(134,232,20,61,107,82,31,49,67,207,65,80,63,84,99,210,202,163,153,77,35,206,171,190,76,118,198,175,251,166,150,47) -IMAGE_DATA(175,113,0,215,149,213,61,175,12,181,12,126,76,149,175,175,207,52,7,215,49,243,231,84,118,149,247,53,254,229,229,225) -IMAGE_DATA(17,252,83,149,21,108,59,125,136,118,137,183,143,216,116,213,63,78,75,247,90,238,243,168,156,232,30,206,237,138,230,206) -IMAGE_DATA(195,59,196,99,61,254,80,201,160,142,27,126,235,201,147,238,21,245,28,110,68,71,184,95,238,253,115,191,92,101,4,191) -IMAGE_DATA(180,170,163,58,66,207,146,70,65,253,71,61,243,200,230,64,105,120,60,60,251,109,71,255,157,71,205,77,213,189,151,239) -IMAGE_DATA(85,84,222,161,29,223,209,43,46,235,174,219,212,95,232,201,155,175,173,198,58,161,215,203,175,208,60,11,236,89,69,223) -IMAGE_DATA(99,185,186,231,97,46,52,70,165,177,42,141,97,233,90,84,190,188,251,48,154,19,165,113,86,181,233,149,156,171,172,19) -IMAGE_DATA(123,71,39,101,190,56,60,172,190,188,218,174,140,199,50,187,130,254,212,220,94,213,233,45,185,205,252,114,181,211,85,220) -IMAGE_DATA(64,237,244,90,155,11,207,232,126,191,231,151,107,29,221,187,123,29,141,221,232,252,246,108,187,190,199,151,31,153,131,234) -IMAGE_DATA(188,106,212,207,133,30,103,126,74,179,138,75,16,151,67,47,161,239,91,249,221,200,123,235,108,74,229,93,227,74,154,147) -IMAGE_DATA(173,60,213,59,35,164,175,240,39,115,86,201,58,122,198,115,20,179,220,197,12,177,35,238,203,103,122,13,187,159,237,97) -IMAGE_DATA(57,3,111,217,116,151,117,252,119,181,163,206,195,234,7,178,38,30,39,115,94,238,217,21,192,125,210,150,109,119,95,190) -IMAGE_DATA(231,95,100,118,58,62,51,249,112,191,124,173,142,240,115,131,222,152,220,151,87,90,61,212,156,228,209,248,128,250,188,107) -IMAGE_DATA(129,125,186,235,61,183,189,241,12,123,135,29,203,252,247,214,61,3,149,247,44,46,94,201,187,234,74,181,71,189,220,32) -IMAGE_DATA(61,19,135,23,253,124,217,229,15,29,237,177,121,252,160,222,125,1,181,89,204,89,207,135,113,190,162,207,186,79,119,57) -IMAGE_DATA(71,214,67,23,196,26,208,158,174,151,251,154,154,75,128,78,86,187,226,122,66,207,153,60,150,146,249,170,228,37,107,238) -IMAGE_DATA(71,38,239,122,134,227,251,253,172,142,238,149,214,218,92,143,177,143,236,247,93,71,232,190,108,141,142,232,217,6,104,100) -IMAGE_DATA(242,151,97,118,246,133,159,62,178,159,229,127,221,59,101,126,54,124,75,95,232,163,230,56,141,196,38,116,141,252,92,49) -IMAGE_DATA(147,119,206,28,224,79,100,10,219,222,203,7,208,245,206,206,198,50,154,232,104,206,52,137,241,169,157,207,238,147,232,94) -IMAGE_DATA(148,61,172,159,195,249,126,40,243,229,163,188,250,239,153,156,171,172,71,189,216,179,180,124,50,229,97,61,135,139,185,212) -IMAGE_DATA(56,89,182,239,168,98,68,217,90,187,79,218,218,27,235,184,117,111,156,217,118,206,76,212,191,208,92,136,140,78,165,35) -IMAGE_DATA(90,54,84,253,136,236,28,46,27,147,234,21,61,91,84,30,205,242,247,200,67,37,198,221,138,87,170,188,19,67,196,206) -IMAGE_DATA(16,123,109,249,159,208,136,53,211,28,232,76,206,85,214,153,59,126,23,65,207,100,70,238,9,48,239,156,53,105,206,144) -IMAGE_DATA(203,190,198,186,149,134,238,137,93,87,248,153,129,230,123,49,118,173,235,116,157,63,240,73,216,7,120,206,109,182,118,196) -IMAGE_DATA(176,170,60,49,237,31,227,83,125,178,70,214,209,55,89,12,212,245,182,230,155,48,159,30,35,202,226,52,228,17,245,124) -IMAGE_DATA(121,124,5,229,217,106,47,136,175,80,197,220,188,31,248,178,234,203,195,71,234,99,251,184,85,71,168,47,223,162,149,249) -IMAGE_DATA(92,153,142,112,125,168,107,137,191,50,146,207,15,13,215,187,30,223,213,124,153,64,189,47,167,242,228,136,63,174,124,226) -IMAGE_DATA(254,173,235,21,198,195,93,48,238,221,232,61,83,116,72,235,247,158,117,159,18,253,200,242,194,85,254,24,131,242,181,158) -IMAGE_DATA(75,43,79,186,252,177,110,248,152,216,53,98,97,25,77,221,35,170,76,232,25,98,181,103,192,38,100,185,164,74,3,154) -IMAGE_DATA(196,220,149,175,2,123,178,206,111,205,168,62,207,114,5,125,46,241,51,88,195,192,0,245,137,51,189,201,92,234,121,111) -IMAGE_DATA(230,203,87,231,73,174,235,212,175,209,185,117,221,232,235,162,231,136,106,115,221,87,243,156,83,181,211,190,223,247,58,170) -IMAGE_DATA(35,178,253,126,166,15,221,47,212,152,171,207,131,230,200,169,253,244,24,70,102,203,212,190,235,153,59,58,34,202,103,119) -IMAGE_DATA(6,208,243,234,163,168,156,187,63,7,109,191,111,227,182,141,245,232,249,245,244,147,57,172,238,131,32,27,74,151,51,50) -IMAGE_DATA(151,31,191,231,144,201,58,123,151,74,215,208,62,185,75,202,87,232,136,76,175,192,115,126,38,12,79,85,227,139,246,52) -IMAGE_DATA(167,46,250,167,178,238,191,25,167,223,185,187,202,190,79,243,135,122,115,137,126,138,245,10,80,126,201,230,20,63,68,115) -IMAGE_DATA(168,178,245,117,121,111,237,179,148,247,145,245,76,47,234,29,29,183,211,89,191,181,30,124,173,241,83,61,139,205,234,233) -IMAGE_DATA(221,15,223,107,144,231,228,117,60,103,222,253,255,42,230,173,190,135,222,169,103,95,147,205,153,231,102,101,241,54,245,57) -IMAGE_DATA(120,199,185,148,159,21,101,186,213,229,46,187,175,164,125,239,201,59,124,17,101,209,193,126,207,207,239,29,101,247,180,42) -IMAGE_DATA(89,141,54,201,5,80,89,215,223,198,64,215,84,123,43,189,195,21,237,121,158,27,180,52,159,208,99,236,172,89,165,87) -IMAGE_DATA(162,93,229,41,126,71,170,247,155,176,216,118,29,19,118,171,242,233,50,29,69,27,173,125,10,114,51,146,211,172,247,70) -IMAGE_DATA(163,253,106,77,153,63,206,55,161,95,233,27,228,73,101,80,227,174,85,61,247,203,53,231,175,165,35,220,231,98,255,216) -IMAGE_DATA(210,17,238,203,87,62,142,250,30,170,87,244,204,92,117,69,165,47,153,199,44,183,3,123,135,78,167,93,143,83,87,190) -IMAGE_DATA(96,165,159,85,143,232,222,106,36,110,71,94,15,246,22,223,183,250,253,57,149,51,255,61,58,205,49,213,223,192,201,206) -IMAGE_DATA(13,208,53,106,135,244,183,95,50,90,217,189,3,248,194,245,138,182,141,252,101,232,121,11,241,25,242,222,242,225,221,182) -IMAGE_DATA(227,83,43,159,176,159,205,230,17,218,200,24,247,114,176,175,85,95,53,86,221,203,33,97,252,248,184,222,15,198,142,158) -IMAGE_DATA(228,183,50,224,239,106,174,212,191,208,24,123,213,111,221,179,170,28,234,125,16,167,231,249,19,190,223,215,92,11,159,31) -IMAGE_DATA(213,17,216,104,165,227,200,26,248,217,168,230,191,32,87,74,47,228,185,197,147,26,207,64,22,98,189,208,33,154,63,82) -IMAGE_DATA(245,205,219,114,84,95,126,196,190,107,142,28,122,23,155,24,237,176,111,247,177,40,50,118,126,19,70,239,245,122,238,151) -IMAGE_DATA(159,17,42,93,98,2,232,199,138,30,254,18,247,190,105,95,245,10,241,19,98,117,220,35,137,255,21,121,174,125,38,78) -IMAGE_DATA(206,93,214,22,70,153,40,235,114,70,236,13,26,30,239,161,255,204,87,0,242,150,245,147,118,52,199,162,119,31,89,245) -IMAGE_DATA(169,206,43,168,244,57,195,84,58,244,69,251,228,115,197,26,123,89,175,163,253,214,61,64,171,142,231,203,251,90,86,168) -IMAGE_DATA(113,121,236,251,72,157,42,151,204,101,2,123,88,201,33,118,91,101,65,227,233,186,206,135,64,157,211,17,251,174,191,77) -IMAGE_DATA(161,251,94,237,167,199,2,65,215,217,126,206,9,239,183,242,126,144,47,165,89,157,185,185,31,73,57,167,167,247,204,122) -IMAGE_DATA(191,177,163,124,139,12,49,23,173,115,63,181,179,126,151,0,30,209,241,56,66,215,207,86,90,168,237,142,172,45,115,219) -IMAGE_DATA(234,135,206,233,200,92,105,236,96,180,14,101,181,141,17,58,244,91,99,98,163,107,169,103,133,107,198,164,54,201,215,50) -IMAGE_DATA(147,137,22,127,42,111,210,142,222,251,58,20,142,232,255,74,238,253,55,15,117,95,155,241,137,35,99,242,252,224,22,77) -IMAGE_DATA(205,51,106,181,157,209,98,189,50,255,193,127,247,82,251,238,124,79,172,219,235,183,114,160,179,241,233,60,246,198,163,253) -IMAGE_DATA(87,254,110,245,179,242,149,90,50,239,235,233,58,178,162,95,245,133,88,48,243,51,114,23,12,29,165,117,90,244,124,172) -IMAGE_DATA(213,90,102,72,255,70,233,104,157,106,45,91,115,56,34,11,58,6,157,47,45,219,66,149,67,47,191,134,31,42,249,243) -IMAGE_DATA(223,26,173,116,146,230,11,185,12,172,185,127,168,52,157,110,150,167,4,173,30,61,111,183,149,143,183,166,207,163,227,105) -IMAGE_DATA(233,12,239,255,232,111,56,239,51,183,45,250,187,206,149,255,46,115,175,222,46,235,114,83,117,178,92,134,150,76,168,92) -IMAGE_DATA(140,202,194,232,90,143,160,143,119,95,158,117,222,173,208,239,0,92,39,205,236,206,193,104,155,189,187,11,135,132,53,180) -IMAGE_DATA(175,179,159,163,109,238,210,135,93,251,125,157,117,118,25,207,200,188,30,138,63,111,3,79,140,194,77,209,153,48,97,194) -IMAGE_DATA(132,9,19,38,76,152,48,97,66,14,255,3,183,151,96,123,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0) -IMAGE_END_DATA(5280, 20) +IMAGE_DATA(120,156,237,156,73,136,165,87,21,199,223,46,67,135,40,106,140,38,149,201,17,99,92,216,65,82,142,96,140,109,58,193) +IMAGE_DATA(77,76,101,208,140,70,18,72,80,19,156,98,226,80,130,168,24,91,196,133,13,17,21,21,23,182,16,23,138,224,66,140) +IMAGE_DATA(155,184,80,19,92,8,34,40,18,112,64,144,32,46,196,16,248,172,243,194,175,243,175,127,159,59,124,239,189,170,174,142) +IMAGE_DATA(223,41,14,245,222,247,221,123,207,29,206,116,207,61,247,205,246,205,78,153,13,195,76,97,232,252,63,22,90,245,22,105) +IMAGE_DATA(119,24,129,139,180,189,204,251,86,189,250,255,83,102,251,124,97,90,196,23,89,184,158,103,173,239,39,90,59,203,205,207) +IMAGE_DATA(41,101,137,169,17,204,184,208,159,183,190,103,245,106,220,61,230,253,78,245,111,150,188,159,109,123,126,218,214,95,133,211) +IMAGE_DATA(119,9,54,135,167,113,213,101,41,175,35,108,213,165,253,97,104,211,218,28,142,197,158,178,61,125,222,137,178,1,195,200) +IMAGE_DATA(249,27,1,207,221,250,219,65,102,90,198,198,12,155,155,155,85,108,180,49,47,83,130,221,170,191,108,255,31,126,248,225) +IMAGE_DATA(57,242,89,255,79,244,119,135,190,255,223,37,250,179,217,234,125,180,58,148,148,65,81,10,12,74,245,54,99,50,58,208) +IMAGE_DATA(219,25,83,87,219,200,234,214,218,202,202,234,179,109,130,95,232,115,86,190,183,92,139,126,86,190,167,79,181,57,238,41) +IMAGE_DATA(179,234,250,203,244,63,43,95,106,163,183,220,216,245,27,195,63,203,242,47,245,199,180,1,204,12,138,19,111,176,173,210) +IMAGE_DATA(138,61,131,150,38,107,226,162,160,245,209,222,250,89,177,85,127,85,244,91,253,208,190,236,198,248,75,125,91,53,125,109) +IMAGE_DATA(167,69,155,255,78,127,108,95,90,244,189,15,254,121,85,227,95,18,143,47,20,148,65,173,131,173,193,100,147,180,173,254) +IMAGE_DATA(214,211,99,112,86,89,12,107,99,47,215,95,118,252,181,249,31,146,119,189,204,52,103,250,70,153,26,44,83,127,155,64) +IMAGE_DATA(46,208,198,50,245,83,5,60,162,141,101,234,23,13,64,103,27,187,175,60,118,40,102,208,61,97,141,114,131,253,47,61) +IMAGE_DATA(235,161,209,45,56,250,121,115,243,233,242,241,95,63,23,250,116,12,77,234,57,246,246,165,147,126,113,188,78,175,64,191) +IMAGE_DATA(216,214,9,72,127,91,31,58,233,123,221,99,250,144,172,93,173,78,177,63,29,101,143,31,120,120,255,240,225,195,67,160) +IMAGE_DATA(150,209,103,250,174,244,44,171,159,125,247,231,173,242,189,223,91,116,106,227,171,141,171,54,190,163,207,10,231,37,37,109) +IMAGE_DATA(49,255,156,152,11,127,118,140,89,41,152,153,94,51,52,234,125,139,78,161,189,158,113,181,231,199,206,75,74,170,189,130) +IMAGE_DATA(155,157,184,88,249,94,208,242,173,77,163,151,223,107,237,7,104,40,52,251,190,108,249,222,254,140,194,229,153,105,28,46) +IMAGE_DATA(210,217,189,88,103,55,203,142,93,236,149,49,199,146,204,180,40,120,11,211,247,221,251,174,11,218,243,125,17,122,125,16) +IMAGE_DATA(187,178,30,184,232,162,55,110,156,117,214,75,215,23,34,178,5,175,123,221,129,67,7,15,222,122,164,167,236,91,222,114) +IMAGE_DATA(213,61,231,156,243,202,109,180,182,234,62,126,197,21,183,61,174,207,78,59,237,185,107,175,121,205,155,54,188,254,218,218) +IMAGE_DATA(43,214,111,190,249,83,195,91,223,122,205,35,103,158,121,238,250,249,231,95,184,177,177,113,207,112,245,213,119,15,231,157) +IMAGE_DATA(119,225,198,73,39,157,186,182,127,255,165,71,162,140,211,1,14,28,184,241,145,15,124,224,171,195,101,151,189,123,120,199) +IMAGE_DATA(59,110,26,110,188,241,19,115,188,242,202,219,230,207,226,221,229,151,223,252,72,105,12,103,156,177,182,126,224,192,13,195) +IMAGE_DATA(103,62,243,131,121,157,219,111,255,194,28,227,115,60,123,251,219,111,24,94,248,194,115,138,243,121,193,5,175,222,216,234) +IMAGE_DATA(255,240,206,119,222,62,60,240,192,79,135,251,238,251,206,28,227,115,60,187,244,210,235,134,75,46,57,120,143,214,137,245) +IMAGE_DATA(217,191,255,109,135,174,191,254,163,195,181,215,126,120,184,245,214,205,225,174,187,190,60,175,247,245,175,63,58,199,248,28) +IMAGE_DATA(207,226,221,53,215,124,104,184,254,250,143,109,141,239,230,35,49,103,23,94,248,250,45,154,215,30,185,234,170,247,63,126) +IMAGE_DATA(221,117,31,25,110,185,229,211,195,157,119,30,26,238,191,255,123,91,117,31,155,99,124,142,103,241,46,202,68,217,173,190) +IMAGE_DATA(28,241,117,56,239,188,87,109,196,188,93,121,229,251,134,207,127,254,199,195,189,247,126,123,142,241,57,158,173,175,95,241) +IMAGE_DATA(248,233,167,63,191,56,254,23,189,232,252,245,45,62,24,62,251,217,31,110,141,247,142,225,142,59,190,56,199,248,28,207) +IMAGE_DATA(226,93,148,41,213,143,245,187,251,238,175,5,15,12,7,15,222,50,220,116,211,39,231,24,159,227,89,188,187,248,226,183) +IMAGE_DATA(165,252,184,182,246,242,245,88,235,104,227,140,51,206,89,191,224,130,139,54,174,190,250,131,67,96,124,142,103,241,46,202) +IMAGE_DATA(68,89,175,127,242,201,167,174,237,219,247,156,53,125,246,158,247,124,124,8,212,103,193,123,47,126,241,75,186,100,234,226) +IMAGE_DATA(139,47,59,20,216,83,54,131,179,207,126,217,250,190,125,167,175,85,11,237,112,90,71,6,153,166,27,83,55,251,190,204) +IMAGE_DATA(8,50,173,219,219,191,99,181,184,254,213,205,122,222,94,207,223,110,214,239,119,83,242,241,111,118,96,86,127,124,221,103) +IMAGE_DATA(234,207,142,121,223,83,119,86,45,219,174,251,76,253,254,249,218,91,176,106,101,208,202,107,145,252,150,98,253,22,51,183) +IMAGE_DATA(234,47,75,191,5,61,245,103,179,167,49,219,36,143,169,191,40,253,237,17,147,103,250,210,91,127,251,126,103,123,95,102) +IMAGE_DATA(21,166,206,232,123,244,198,232,15,89,125,165,235,180,123,234,235,184,169,79,94,85,47,125,159,115,63,232,203,230,32,171) +IMAGE_DATA(175,117,135,156,127,7,173,191,32,255,46,47,197,199,33,225,115,209,122,99,218,169,91,191,122,253,157,110,255,217,94,191) +IMAGE_DATA(183,253,158,250,203,90,215,157,180,208,123,169,141,213,192,78,41,131,201,67,168,91,200,177,22,58,142,11,22,161,31,245) +IMAGE_DATA(158,182,146,219,255,143,161,175,71,22,199,131,126,54,254,222,245,43,205,123,193,66,23,233,43,221,138,133,175,214,239,240) +IMAGE_DATA(16,182,213,95,134,127,23,130,167,102,23,29,253,156,142,126,130,9,38,152,96,130,9,38,152,96,130,9,38,152,96,130) +IMAGE_DATA(9,38,152,96,130,9,38,56,33,225,191,79,62,117,20,255,246,207,127,15,127,250,235,19,219,240,137,127,255,103,142,241) +IMAGE_DATA(126,130,9,38,56,113,33,228,56,100,60,176,36,239,188,15,156,228,126,130,9,78,44,192,94,135,44,255,238,207,255,24) +IMAGE_DATA(30,126,236,207,195,143,30,249,195,240,221,159,60,90,196,120,31,229,162,60,58,0,219,63,193,4,19,236,61,64,206,127) +IMAGE_DATA(253,251,191,204,101,248,158,207,125,127,216,127,223,207,83,124,195,151,126,83,196,27,31,252,237,112,232,155,63,157,203,63) +IMAGE_DATA(178,63,201,253,4,19,236,13,8,255,27,187,28,50,254,202,107,30,24,94,126,195,225,225,213,119,61,148,202,118,175,220) +IMAGE_DATA(199,251,144,125,181,251,19,76,48,193,241,3,246,231,97,207,207,188,252,115,195,190,55,127,106,120,213,123,191,117,140,61) +IMAGE_DATA(15,217,143,231,161,11,162,28,24,122,33,158,163,27,92,7,196,247,40,19,246,30,91,63,65,63,104,172,52,16,31,76) +IMAGE_DATA(99,164,224,4,19,212,128,61,122,200,250,201,175,125,255,92,126,67,110,21,67,150,67,94,145,243,208,7,129,81,62,48) +IMAGE_DATA(62,199,243,120,143,95,160,242,31,50,31,223,163,92,208,9,59,255,255,206,155,42,183,126,238,17,123,41,240,239,127,252) +IMAGE_DATA(229,54,252,253,47,190,87,196,120,31,115,59,233,211,9,50,192,135,207,100,61,228,19,57,7,67,150,67,102,227,127,216) +IMAGE_DATA(234,192,141,15,62,120,84,254,145,119,69,100,31,121,143,103,65,51,240,255,5,144,235,144,67,246,52,204,65,96,200,117) +IMAGE_DATA(188,11,153,253,215,225,171,134,167,126,182,214,196,39,31,124,222,81,140,58,191,250,238,87,230,245,35,102,58,201,251,4) +IMAGE_DATA(25,192,107,216,236,154,172,7,70,153,144,111,108,15,177,184,144,251,120,247,130,119,125,163,88,55,16,255,63,120,50,234) +IMAGE_DATA(63,91,65,207,37,213,94,115,190,17,243,21,49,141,152,75,157,139,152,207,144,221,255,124,242,212,166,124,35,227,122,54) +IMAGE_DATA(18,235,57,157,133,78,144,1,182,38,120,46,108,59,114,154,201,106,60,195,95,143,58,193,91,156,189,129,241,46,228,221) +IMAGE_DATA(247,2,138,241,62,218,9,254,12,30,127,54,242,37,62,83,204,15,114,29,232,113,16,246,64,49,119,200,123,212,69,230) +IMAGE_DATA(85,190,213,134,187,140,71,93,206,60,167,61,252,4,25,168,31,95,178,203,234,139,99,219,145,83,181,37,156,219,5,239) +IMAGE_DATA(70,59,231,222,246,80,17,227,61,237,4,95,247,218,162,19,41,30,21,122,52,230,4,253,151,157,99,132,188,135,142,13) +IMAGE_DATA(93,139,143,133,191,20,62,121,216,119,80,237,56,58,118,146,239,189,3,39,2,111,170,109,39,22,95,146,117,108,123,252) +IMAGE_DATA(15,62,115,191,81,247,255,232,14,141,221,43,178,127,199,39,240,243,120,141,63,195,211,200,15,232,121,60,189,250,66,115) +IMAGE_DATA(4,75,200,62,219,235,121,254,96,109,125,137,125,114,110,129,156,99,215,209,123,196,64,136,193,225,199,171,140,199,115,228) +IMAGE_DATA(28,91,174,185,76,222,79,197,0,127,214,194,82,91,173,58,99,231,56,235,119,111,126,166,198,54,119,59,167,51,235,175) +IMAGE_DATA(242,38,177,82,197,86,91,173,249,234,69,95,15,5,252,205,204,182,35,235,30,103,11,222,196,6,49,142,232,51,227,100) +IMAGE_DATA(95,90,203,191,139,247,232,139,104,199,199,206,94,215,115,249,224,119,208,115,249,152,183,18,32,35,180,237,152,173,89,180) +IMAGE_DATA(233,121,133,208,39,206,230,52,209,127,145,191,160,231,148,49,199,248,62,33,247,241,62,228,25,191,61,179,229,158,183,168) +IMAGE_DATA(253,195,39,160,15,218,79,198,227,241,192,26,82,134,245,244,51,130,26,50,247,154,135,73,31,124,142,179,220,75,141,107) +IMAGE_DATA(232,62,145,247,0,252,76,95,179,58,180,189,74,185,87,25,207,242,76,107,188,201,56,50,61,215,226,201,94,116,190,200) +IMAGE_DATA(108,40,60,169,251,246,146,109,199,94,187,31,15,40,111,244,246,81,99,200,240,75,60,171,229,242,149,242,123,98,111,204) +IMAGE_DATA(25,95,54,94,214,41,218,166,124,134,225,235,68,25,116,118,232,38,239,143,210,13,154,220,29,80,90,81,23,191,137,61) +IMAGE_DATA(78,216,245,104,43,218,172,201,57,123,126,244,66,169,191,196,249,2,162,31,241,29,255,33,214,143,249,160,47,181,113,199) +IMAGE_DATA(26,163,203,25,59,227,46,213,97,60,232,27,120,35,104,149,234,208,111,116,4,250,191,52,191,244,9,253,131,223,212,170) +IMAGE_DATA(3,31,172,66,230,213,6,101,252,208,195,155,158,99,170,124,210,154,231,94,140,54,24,187,219,32,221,95,102,190,188,219) +IMAGE_DATA(246,224,89,246,153,200,169,207,165,158,29,183,236,9,50,169,186,154,124,62,100,195,243,123,216,11,232,123,157,87,248,79) +IMAGE_DATA(109,142,235,35,234,103,57,128,186,159,142,121,131,166,202,157,98,60,207,226,142,236,119,56,159,204,108,121,201,158,99,31) +IMAGE_DATA(136,159,150,114,26,105,59,120,136,115,145,192,232,19,58,6,93,196,62,43,222,101,227,142,231,241,62,250,136,125,140,255) +IMAGE_DATA(236,191,106,117,144,93,213,17,181,126,179,134,200,13,235,157,205,49,227,140,114,248,28,173,58,129,241,142,126,45,123,222) +IMAGE_DATA(139,29,130,31,148,174,242,39,227,226,44,59,27,75,32,58,24,57,137,121,174,241,100,47,234,26,178,30,42,159,240,129) +IMAGE_DATA(250,242,37,89,87,95,30,223,161,180,79,42,229,126,149,246,123,200,58,122,199,99,91,204,37,121,1,81,142,207,228,254) +IMAGE_DATA(249,90,71,25,100,158,62,106,92,50,171,23,223,145,111,242,135,2,93,247,100,241,117,207,37,224,108,50,218,235,145,115) +IMAGE_DATA(246,63,234,119,227,27,4,13,207,91,134,46,122,137,152,9,107,136,28,98,79,216,87,232,184,245,191,158,143,226,123,69) +IMAGE_DATA(187,30,123,240,60,73,141,185,122,191,75,242,78,174,150,230,104,101,57,156,32,126,37,99,208,58,217,186,192,251,26,87) +IMAGE_DATA(94,212,198,99,215,131,182,219,25,214,129,121,192,30,34,247,89,14,186,247,139,24,55,254,117,43,39,189,150,171,206,60) +IMAGE_DATA(233,62,136,113,163,43,225,21,141,191,187,188,235,249,25,62,248,170,238,186,225,7,32,235,49,31,158,207,199,26,99,123) +IMAGE_DATA(232,55,115,236,57,124,216,104,213,115,200,59,235,166,122,76,17,93,130,44,193,155,181,249,65,7,97,75,98,110,99,92) +IMAGE_DATA(196,222,244,44,77,227,237,33,231,209,31,246,127,156,197,225,63,33,131,165,126,106,31,225,47,157,47,245,131,25,71,214) +IMAGE_DATA(150,230,83,232,94,139,185,114,189,175,254,158,198,92,225,13,246,46,37,90,244,47,234,162,27,226,115,86,222,121,0,61) +IMAGE_DATA(6,237,82,29,228,10,251,180,72,222,17,251,237,76,214,225,79,230,142,121,208,24,173,206,129,242,52,125,103,111,130,31) +IMAGE_DATA(151,229,169,40,111,215,80,253,111,141,173,33,239,190,191,172,249,242,244,177,229,203,143,5,221,79,163,223,178,60,31,149) +IMAGE_DATA(93,205,39,201,230,137,54,116,13,116,111,89,226,123,205,35,138,50,140,145,181,99,141,74,126,15,246,29,158,215,24,187) +IMAGE_DATA(203,121,188,195,246,35,99,81,7,253,25,237,160,207,224,105,95,23,189,183,128,126,66,255,225,251,224,203,171,238,40,229) +IMAGE_DATA(62,169,62,5,225,141,172,142,234,27,141,215,180,236,135,210,194,151,97,253,75,190,165,251,43,42,131,186,38,30,107,82) +IMAGE_DATA(121,31,27,187,131,55,53,127,44,203,43,103,94,53,118,167,114,69,124,86,145,57,128,143,213,151,116,84,190,43,233,54) +IMAGE_DATA(236,177,202,137,251,223,236,27,156,255,107,190,60,109,185,238,88,20,144,15,159,79,167,27,72,28,72,227,175,37,126,68) +IMAGE_DATA(215,105,14,11,245,91,50,164,60,2,189,236,46,144,199,19,98,110,226,60,205,229,60,243,221,217,115,40,45,252,2,244) +IMAGE_DATA(82,54,54,205,75,230,59,178,142,173,68,7,170,47,239,190,144,231,57,51,62,252,242,64,213,115,78,31,244,253,29,253) +IMAGE_DATA(118,217,213,62,171,110,132,30,242,238,227,83,29,65,156,130,245,71,175,100,229,181,14,52,198,202,59,177,30,230,167,148) +IMAGE_DATA(111,202,62,3,59,232,188,89,154,107,198,67,92,64,145,120,46,251,23,215,211,110,239,241,101,212,30,187,255,157,157,195) +IMAGE_DATA(149,108,59,114,231,185,154,203,128,219,246,108,62,227,191,230,162,176,63,116,155,149,249,55,42,239,190,7,40,249,76,232) +IMAGE_DATA(82,61,83,41,233,119,116,53,251,243,76,206,93,214,53,222,147,237,143,224,51,213,195,46,103,153,125,213,51,58,181,181) +IMAGE_DATA(236,47,74,188,71,123,153,95,142,60,233,221,39,175,227,251,125,141,239,149,250,141,110,100,220,200,148,202,123,86,7,63) +IMAGE_DATA(2,122,174,35,178,58,140,105,172,63,202,185,149,242,75,102,15,125,13,245,108,84,207,35,75,88,42,195,126,16,221,153) +IMAGE_DATA(217,26,229,67,244,46,114,145,217,227,108,239,158,217,119,221,187,51,223,174,43,253,142,102,15,70,127,148,63,50,89,231) +IMAGE_DATA(115,118,78,65,140,169,180,183,81,217,133,247,107,254,0,58,77,253,107,221,195,106,92,1,121,37,14,167,190,122,201,166) +IMAGE_DATA(19,79,81,221,130,30,11,58,234,203,19,83,116,185,209,62,211,87,214,216,207,127,149,127,244,110,83,75,158,212,151,175) +IMAGE_DATA(201,147,198,44,212,39,168,233,8,250,225,103,229,181,58,248,242,228,107,176,150,189,99,210,179,239,94,121,239,217,235,250) +IMAGE_DATA(26,162,83,244,172,73,125,196,12,61,7,65,253,80,141,73,43,143,102,54,141,56,175,250,50,217,25,191,238,155,106,190) +IMAGE_DATA(188,198,1,92,87,150,238,121,101,168,101,240,99,74,249,250,250,76,115,112,29,51,127,78,101,87,121,95,227,95,94,30) +IMAGE_DATA(30,193,63,85,89,193,182,211,135,104,151,120,123,143,77,87,253,227,180,116,175,229,62,143,202,137,238,225,220,174,104,238) +IMAGE_DATA(60,188,67,60,214,227,15,37,25,212,113,195,111,45,121,210,189,162,158,195,245,232,8,247,203,189,127,238,151,171,140,224) +IMAGE_DATA(151,150,234,168,142,208,179,164,94,80,255,81,207,60,178,57,80,26,30,15,207,126,219,209,127,231,81,115,83,117,239,229) +IMAGE_DATA(123,21,149,119,104,199,119,244,138,203,186,235,54,245,23,90,242,230,107,171,177,78,232,181,242,43,52,207,2,123,86,162) +IMAGE_DATA(239,177,92,221,243,48,23,26,163,210,88,149,198,176,116,45,74,190,188,251,48,154,19,165,113,86,181,233,37,57,87,89) +IMAGE_DATA(39,246,142,78,202,124,113,120,88,125,121,181,93,25,143,101,118,5,253,169,185,189,170,211,107,114,155,249,229,106,167,75) +IMAGE_DATA(113,3,181,211,99,109,46,60,163,251,253,150,95,174,117,116,239,238,117,52,118,163,243,219,178,237,250,30,95,190,103,14) +IMAGE_DATA(74,231,85,189,126,46,244,56,243,83,154,165,184,4,113,57,244,18,250,190,150,223,141,188,215,206,166,84,222,53,174,164) +IMAGE_DATA(57,217,202,83,173,51,66,250,10,127,50,103,37,89,71,207,120,142,98,150,187,152,33,118,196,125,249,76,175,97,247,179) +IMAGE_DATA(61,44,103,224,53,155,238,178,142,255,174,118,212,121,88,253,64,214,196,227,100,206,203,45,187,2,184,79,90,179,237,238) +IMAGE_DATA(203,183,252,139,204,78,199,255,76,62,220,47,31,171,35,252,220,160,53,38,247,229,149,86,11,53,39,185,55,62,160,62) +IMAGE_DATA(239,88,96,159,238,122,207,109,111,60,195,222,97,199,50,255,189,118,207,64,229,61,139,139,151,228,93,117,165,218,163,86) +IMAGE_DATA(110,144,158,137,195,139,126,190,236,242,135,142,246,216,60,126,80,235,190,128,218,44,230,172,229,195,56,95,209,103,221,167) +IMAGE_DATA(187,156,35,235,161,11,98,13,104,79,215,203,125,77,205,37,64,39,171,93,113,61,161,231,76,30,75,201,124,85,242,146) +IMAGE_DATA(53,247,35,147,119,61,195,241,253,126,86,71,247,74,99,109,174,199,216,123,246,251,174,35,116,95,54,70,71,180,108,3) +IMAGE_DATA(52,50,249,203,48,59,251,194,79,239,217,207,242,89,247,78,153,159,13,223,210,23,250,168,57,78,61,177,9,93,35,63) +IMAGE_DATA(87,204,228,157,51,7,248,19,153,194,182,183,242,1,116,189,179,179,177,140,38,58,154,51,77,98,124,106,231,179,251,36) +IMAGE_DATA(186,23,101,15,235,231,112,190,31,202,124,249,40,175,254,123,38,231,42,235,81,47,246,44,53,159,76,121,88,207,225,98) +IMAGE_DATA(46,53,78,150,237,59,74,49,162,108,173,221,39,173,237,141,117,220,186,55,206,108,59,103,38,234,95,104,46,68,70,167) +IMAGE_DATA(164,35,106,54,84,253,136,236,28,46,27,147,234,21,61,91,84,30,205,242,247,200,67,37,198,93,139,87,170,188,19,67) +IMAGE_DATA(196,206,16,123,173,249,159,208,136,53,211,28,232,76,206,85,214,153,59,126,23,65,207,100,122,238,9,48,239,156,53,105) +IMAGE_DATA(206,144,203,190,198,186,149,134,238,137,93,87,248,153,129,230,123,49,118,173,235,116,157,63,240,73,216,7,120,206,109,182) +IMAGE_DATA(118,196,176,74,121,98,218,63,198,167,250,100,140,172,163,111,178,24,168,235,109,205,55,97,62,61,70,148,197,105,200,35) +IMAGE_DATA(106,249,242,248,10,202,179,165,189,32,190,66,41,230,230,253,192,151,85,95,30,62,82,31,219,199,173,58,66,125,249,26) +IMAGE_DATA(173,204,231,202,116,132,235,67,93,75,252,149,158,124,126,104,184,222,245,248,174,230,203,4,234,125,57,149,39,71,252,113) +IMAGE_DATA(229,19,247,111,93,175,48,30,238,130,113,239,70,239,153,162,67,106,191,247,172,251,148,232,71,150,23,174,242,199,24,148) +IMAGE_DATA(175,245,92,90,121,210,229,143,117,195,199,196,174,17,11,203,104,234,30,81,101,66,207,16,75,123,6,108,66,150,75,170) +IMAGE_DATA(52,160,73,204,93,249,42,176,37,235,252,214,140,234,243,44,87,208,231,18,63,131,53,12,12,80,159,56,211,155,204,165) +IMAGE_DATA(158,247,102,190,124,233,60,201,117,157,250,53,58,183,174,27,125,93,244,28,81,109,174,251,106,158,115,170,118,218,247,251) +IMAGE_DATA(94,71,117,68,182,223,207,244,161,251,133,26,115,245,121,208,28,57,181,159,30,195,200,108,153,218,119,61,115,71,71,68) +IMAGE_DATA(249,236,206,0,122,94,125,20,149,115,247,231,160,237,247,109,220,182,177,30,45,191,158,126,50,135,165,251,32,200,134,210) +IMAGE_DATA(229,140,204,229,199,239,57,100,178,206,222,165,164,107,104,159,220,37,229,43,116,68,166,87,224,57,63,19,134,167,74,227) +IMAGE_DATA(139,246,52,167,46,250,167,178,238,191,25,167,223,185,187,202,190,79,243,135,90,115,137,126,138,245,10,80,126,201,230,20) +IMAGE_DATA(63,68,115,168,178,245,117,121,175,237,179,148,247,145,245,76,47,234,29,29,183,211,89,191,181,30,124,173,241,83,61,139) +IMAGE_DATA(205,234,233,221,15,223,107,144,231,228,117,60,103,222,253,255,82,204,91,125,15,189,83,207,190,38,155,51,207,205,202,226) +IMAGE_DATA(109,234,115,240,142,115,41,63,43,202,116,171,203,93,118,95,73,251,222,146,119,248,34,202,162,131,253,158,159,223,59,202) +IMAGE_DATA(238,105,149,100,53,218,36,23,64,101,93,127,27,3,93,83,218,91,233,29,174,104,207,243,220,160,165,249,132,30,99,103) +IMAGE_DATA(205,74,122,37,218,85,158,226,119,164,90,191,9,139,109,215,49,97,183,74,62,93,166,163,104,163,182,79,65,110,122,114) +IMAGE_DATA(154,245,222,104,180,95,90,83,230,143,243,77,232,151,244,13,242,164,50,168,113,215,82,61,247,203,53,231,175,166,35,220) +IMAGE_DATA(231,98,255,88,211,17,238,203,151,124,28,245,61,84,175,232,153,185,234,138,146,190,100,30,179,220,14,236,29,58,157,118) +IMAGE_DATA(61,78,93,242,5,75,250,89,245,136,238,173,122,226,118,228,245,96,111,241,125,75,191,63,167,114,230,191,71,167,57,166) +IMAGE_DATA(250,27,56,217,185,1,186,70,237,144,254,246,75,70,43,187,119,0,95,184,94,209,182,145,191,12,61,111,33,254,135,188) +IMAGE_DATA(215,124,120,183,237,248,212,202,39,236,103,179,121,132,54,50,198,189,28,236,107,169,175,26,171,110,229,144,48,126,124,92) +IMAGE_DATA(239,7,99,71,79,242,91,25,240,119,105,174,212,191,208,24,123,169,223,186,103,85,57,212,251,32,78,207,243,39,124,191) +IMAGE_DATA(175,185,22,62,63,170,35,176,209,74,199,145,53,240,179,81,205,127,65,174,148,94,200,115,141,39,53,158,129,44,196,122) +IMAGE_DATA(161,67,52,127,164,212,55,111,203,81,125,249,30,251,174,57,114,232,93,108,98,180,195,190,221,199,162,200,216,249,77,24) +IMAGE_DATA(189,215,235,185,95,126,70,168,116,137,9,160,31,75,244,240,151,184,247,77,251,170,87,136,159,16,171,227,30,73,124,86) +IMAGE_DATA(228,185,246,153,56,57,119,89,107,24,101,162,172,203,25,177,55,104,120,188,135,254,51,95,1,200,91,214,79,218,209,28) +IMAGE_DATA(139,214,125,100,213,167,58,175,160,210,231,12,83,233,208,23,237,147,207,21,107,236,101,189,142,246,91,247,0,181,58,158) +IMAGE_DATA(47,239,107,89,66,141,203,99,223,123,234,148,114,201,92,38,176,135,37,57,196,110,171,44,104,60,93,215,121,21,168,115) +IMAGE_DATA(218,99,223,245,183,41,116,223,171,253,244,88,32,232,58,219,207,57,225,253,90,222,15,242,165,52,75,103,110,238,71,82) +IMAGE_DATA(206,233,233,61,179,214,111,236,40,223,34,67,204,69,237,220,79,237,172,223,37,128,71,116,60,142,208,245,179,149,26,106) +IMAGE_DATA(187,61,107,203,220,214,250,161,115,218,51,87,26,59,232,173,67,89,109,163,135,14,253,214,152,88,239,90,234,89,225,152) +IMAGE_DATA(49,169,77,242,181,204,100,162,198,159,202,155,180,163,247,190,86,133,61,250,191,36,247,254,155,135,186,175,205,248,196,145) +IMAGE_DATA(49,121,126,112,141,166,230,25,213,218,206,104,177,94,153,255,224,191,123,169,125,119,190,39,214,237,245,107,57,208,217,248) +IMAGE_DATA(116,30,91,227,209,254,43,127,215,250,89,242,149,106,50,239,235,233,58,178,68,191,212,23,98,193,204,79,207,93,48,116) +IMAGE_DATA(148,214,169,209,243,177,150,214,50,67,250,215,75,71,235,148,214,178,54,135,61,178,160,99,208,249,210,178,53,84,57,244) +IMAGE_DATA(242,99,248,161,36,127,254,91,163,37,157,164,249,66,46,3,99,238,31,42,77,167,155,229,41,65,171,69,207,219,173,229) +IMAGE_DATA(227,141,233,115,239,120,106,58,195,251,223,251,27,206,203,204,109,141,254,162,115,229,191,203,220,170,183,200,186,236,86,157) +IMAGE_DATA(44,151,161,38,19,42,23,189,178,208,187,214,61,232,227,93,150,103,157,119,75,232,119,0,118,146,102,118,231,160,183,205) +IMAGE_DATA(214,221,133,85,194,24,218,59,217,207,222,54,23,233,195,162,253,222,201,58,139,140,167,103,94,87,197,159,123,129,39,122) +IMAGE_DATA(97,183,232,76,48,193,4,19,76,48,193,4,19,76,48,193,4,57,252,15,72,33,58,176,0,0,0,0,0,0,0,0) +IMAGE_END_DATA(5568, 20) IMAGE_BEGIN_DATA IMAGE_DATA(120,156,99,16,96,16,96,160,38,40,236,92,246,159,28,140,172,255,255,127,6,20,188,106,213,170,255,248,0,86,253,207) @@ -3856,9 +3865,9 @@ IMAGE_DATA(49,245,163,187,3,67,255,121,164,240,35,55,254,29,161,102,252,39,51,25 IMAGE_DATA(244,112,64,215,79,73,254,161,8,80,187,48,0,130,255,100,98,184,126,82,1,54,253,12,80,8,2,198,198,198,56,49) IMAGE_DATA(49,250,41,181,31,162,166,1,142,137,209,79,169,255,97,0,159,191,233,97,63,57,250,41,76,63,232,0,151,249,196,2) IMAGE_DATA(74,244,227,82,75,172,25,148,234,39,13,240,80,191,48,24,104,224,141,7,99,87,223,208,128,137,71,213,35,212,147,22) -IMAGE_DATA(158,76,56,196,7,63,24,134,153,129,212,210,243,191,94,109,237,233,148,25,51,78,219,183,182,158,22,200,203,59,205,156) -IMAGE_DATA(158,126,26,159,122,144,218,205,7,14,156,206,157,59,247,180,14,80,47,71,86,22,94,245,14,109,109,96,181,62,189,189) -IMAGE_DATA(167,213,43,43,79,115,18,80,47,8,116,131,62,208,92,205,234,234,211,146,69,69,167,217,50,51,241,170,103,205,200,56) -IMAGE_DATA(13,210,35,148,159,127,154,59,39,135,160,251,25,210,210,192,106,64,152,9,164,22,200,199,171,158,244,218,104,72,2,0) -IMAGE_DATA(118,95,95,234,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0) +IMAGE_DATA(158,76,56,196,7,63,24,134,153,97,21,3,246,146,115,21,14,245,255,245,106,107,79,167,204,152,113,218,190,181,245,180) +IMAGE_DATA(64,94,222,105,230,244,244,211,12,184,75,158,255,32,181,155,15,28,56,157,59,119,238,105,29,160,94,142,172,44,188,234) +IMAGE_DATA(29,218,218,192,106,125,122,123,79,171,87,86,158,230,36,160,94,16,232,6,125,160,185,154,213,213,167,37,139,138,78,179) +IMAGE_DATA(101,102,226,85,207,154,145,113,26,164,71,40,63,255,52,119,78,14,65,247,51,164,165,129,213,128,48,19,72,45,144,143) +IMAGE_DATA(71,61,169,225,57,100,1,0,113,157,94,150,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0) IMAGE_END_DATA(384, 4) diff --git a/uppsrc/ide/ide.key b/uppsrc/ide/ide.key index c588874a1..26e0c0f28 100644 --- a/uppsrc/ide/ide.key +++ b/uppsrc/ide/ide.key @@ -74,9 +74,6 @@ KEY(CLEARBREAKPOINTS, "Clear all breakpoints", K_CTRL_F9|K_SHIFT) KEY(OPENLOG, "View the logfile", K_ALT_L) KEY(TOGGLEBROWSER, "Show Browser++", K_CTRL_B) -KEY(QUERY, "Query..", K_CTRL_Q) -KEY(QUERYWORD, "Query word", K_CTRL_W) -KEY(HELPITEM, "Show documentation for current C++ item...", K_F1); KEY(SEARCHTOPICS, "Search word in Help & Topics", K_CTRL_F1) KEY(BROWSETOPICS, "Help & Topics", K_F1) KEY(CALC, "Calculator", K_CTRL_E) diff --git a/uppsrc/ide/ide.upp b/uppsrc/ide/ide.upp index f9028cf9d..72ef84933 100644 --- a/uppsrc/ide/ide.upp +++ b/uppsrc/ide/ide.upp @@ -37,7 +37,7 @@ file Bottom.cpp, t.cpp, Assist.cpp, - Index.cpp, + Navigator.cpp, Annotations.cpp, Virtuals.cpp, Thisbacks.cpp, diff --git a/uppsrc/ide/idebar.cpp b/uppsrc/ide/idebar.cpp index 67a3b6c8a..cb0f8e692 100644 --- a/uppsrc/ide/idebar.cpp +++ b/uppsrc/ide/idebar.cpp @@ -439,17 +439,14 @@ void Ide::DebugMenu(Bar& menu) } void Ide::BrowseMenu(Bar& menu) { - menu.AddMenu(AK_TOGGLEBROWSER, IdeImg::browser(), THISBACK1(ToggleBottom, BBROWSER)) - .Check(IsBottomShown() && btabs.GetCursor() == BBROWSER); - menu.AddMenu(AK_TOGGLEINDEX, IdeImg::index(), THISBACK(ToggleIndex)) + menu.AddMenu(AK_TOGGLEINDEX, IdeImg::index(), THISBACK1(ToggleNavigator, AssistEditor::NAV_INDEX)) .Check(editor.IsIndex()); - menu.Add(AK_SEARCHINDEX, THISBACK(SearchIndex)); + menu.AddMenu(AK_TOGGLEBROWSER, IdeImg::Navigator(), THISBACK1(ToggleNavigator, AssistEditor::NAV_BROWSER)) + .Check(editor.IsBrowser()); + if(editor.IsIndex()) + menu.Add(AK_SEARCHINDEX, THISBACK(SearchIndex)); menu.Add(!designer, AK_GOTO, THISBACK(Goto)); menu.Add(AK_GOTOGLOBAL, THISBACK(GotoGlobal)); - menu.Add(AK_QUERY, BrowserImg::Query(), THISBACK(Query)); - menu.Add(AK_QUERYWORD, THISBACK(QueryWord)); - menu.Add(btabs.GetCursor() == BBROWSER && browser.item.IsCursor(), AK_HELPITEM, - callback(&browser, &Browser::ShowHelp)); menu.Add(!designer, AK_JUMPS, THISBACK(JumpS)); menu.Add(!designer, AK_SWAPS, THISBACK(SwapS)); menu.Add(!designer, AK_ASSIST, callback(&editor, &AssistEditor::Assist)); diff --git a/uppsrc/ide/idefile.cpp b/uppsrc/ide/idefile.cpp index f4bf34cc2..6625389fe 100644 --- a/uppsrc/ide/idefile.cpp +++ b/uppsrc/ide/idefile.cpp @@ -434,7 +434,7 @@ void Ide::EditFile0(const String& path, byte charset, bool astext, const String& SetBar(); editor.assist_active = IsProjectFile(editfile) && (IsCSourceFile(editfile) || IsCHeaderFile(editfile)); editor.CheckEdited(true); - editor.CreateIndex(); + editor.SyncNavigator(); editor.Annotate(editfile); } diff --git a/uppsrc/ide/idetool.cpp b/uppsrc/ide/idetool.cpp index dd0c44ef8..a254c20f3 100644 --- a/uppsrc/ide/idetool.cpp +++ b/uppsrc/ide/idetool.cpp @@ -47,14 +47,13 @@ void Ide::GotoPos(String path, int line) editastext.FindAdd(path); EditFile(path); editor.SetCursor(editor.GetPos(editor.GetLineNo(line - 1))); - editor.CenterCursor(); + editor.TopCursor(4); editor.SetFocus(); AddHistory(); } void Ide::GotoCpp(const CppItem& pos) { - GotoPos(GetCppFile(pos.file), pos.line); } @@ -73,23 +72,10 @@ void Ide::RescanCode() console.Clear(); RescanBrowserBase(); SyncRefs(); - SetBottom(BBROWSER); + editor.SyncNavigator(); //*/ } -void Ide::Query() -{ - if(browser.DoQuery()) - SetBottom(BBROWSER); -} - -void Ide::QueryWord() -{ - browser.QueryWord(editor.GetWord()); - SetBottom(BBROWSER); - SetBar(); -} - void Ide::OpenATopic() { String t = doc.GetCurrent(); diff --git a/uppsrc/ide/idewin.cpp b/uppsrc/ide/idewin.cpp index 303ea9413..a8b3d7b24 100644 --- a/uppsrc/ide/idewin.cpp +++ b/uppsrc/ide/idewin.cpp @@ -178,7 +178,7 @@ void Ide::Serialize(Stream& s) { if(version >= 8) s % LinuxHostConsole; if(version >= 9) - editor.SerializeIndex(s); + editor.SerializeNavigator(s); if(version >= 10) s % showtime; if(version >= 11)