OSDN Git Service

Fixed CRT linkage options.
[tortoisegit/TortoiseGitJp.git] / ext / scintilla / backgroundcolors.patch
1 Index: include/Scintilla.h\r
2 ===================================================================\r
3 --- include/Scintilla.h (revision 14337)\r
4 +++ include/Scintilla.h (working copy)\r
5 @@ -753,6 +753,7 @@\r
6  #define SCN_AUTOCSELECTION 2022
7  #define SCN_INDICATORCLICK 2023
8  #define SCN_INDICATORRELEASE 2024
9 +#define SCN_GETBKCOLOR 2025
10  #define SCN_AUTOCCANCELLED 2025
11  //--Autogenerated -- end of section automatically generated from Scintilla.iface
12  
13 Index: src/Editor.cxx\r
14 ===================================================================\r
15 --- src/Editor.cxx      (revision 14337)\r
16 +++ src/Editor.cxx      (working copy)\r
17 @@ -2270,6 +2270,17 @@\r
18                 }
19         }
20  
21 +       SCNotification scn = {0};
22 +       scn.nmhdr.code = SCN_GETBKCOLOR;
23 +       scn.line = line;
24 +       scn.lParam = -1;
25 +       NotifyParent(&scn);
26 +       if (scn.lParam != -1)
27 +       {
28 +               background = scn.lParam;
29 +               overrideBackground = true;
30 +       }
31 +
32         bool drawWhitespaceBackground = (vsDraw.viewWhitespace != wsInvisible) &&
33                 (!overrideBackground) && (vsDraw.whitespaceBackgroundSet);
34  
35 Index: src/Editor.h\r
36 ===================================================================\r
37 --- src/Editor.h        (revision 14337)\r
38 +++ src/Editor.h        (working copy)\r
39 @@ -360,6 +360,7 @@\r
40         virtual void NotifyFocus(bool focus);
41         virtual int GetCtrlID() { return ctrlID; }
42         virtual void NotifyParent(SCNotification scn) = 0;
43 +       virtual void NotifyParent(SCNotification * scn) = 0;
44         virtual void NotifyStyleToNeeded(int endStyleNeeded);
45         void NotifyChar(int ch);
46         void NotifyMove(int position);
47 Index: win32/ScintillaWin.cxx\r
48 ===================================================================\r
49 --- win32/ScintillaWin.cxx      (revision 14337)\r
50 +++ win32/ScintillaWin.cxx      (working copy)\r
51 @@ -208,6 +208,7 @@\r
52         virtual void NotifyFocus(bool focus);
53         virtual int GetCtrlID();
54         virtual void NotifyParent(SCNotification scn);
55 +       virtual void NotifyParent(SCNotification * scn);
56         virtual void NotifyDoubleClick(Point pt, bool shift, bool ctrl, bool alt);
57         virtual void Copy();
58         virtual void CopyAllowLine();
59 @@ -1240,6 +1241,13 @@\r
60                       GetCtrlID(), reinterpret_cast<LPARAM>(&scn));
61  }
62  
63 +void ScintillaWin::NotifyParent(SCNotification * scn) {
64 +       scn->nmhdr.hwndFrom = MainHWND();
65 +       scn->nmhdr.idFrom = GetCtrlID();
66 +       ::SendMessage(::GetParent(MainHWND()), WM_NOTIFY,
67 +               GetCtrlID(), reinterpret_cast<LPARAM>(scn));
68 +}
69 +
70  void ScintillaWin::NotifyDoubleClick(Point pt, bool shift, bool ctrl, bool alt) {
71         //Platform::DebugPrintf("ScintillaWin Double click 0\n");
72         ScintillaBase::NotifyDoubleClick(pt, shift, ctrl, alt);