Remove unused variable
[geany-mirror.git] / scintilla / scintilla_changes.patch
blob48c9dadc3634f496525d89718f18823d9a8084e5
1 A patch to Scintilla 3.54 containing our changes to Scintilla
2 (removing unused lexers, exporting symbols).
3 diff --git scintilla/gtk/ScintillaGTK.cxx scintilla/gtk/ScintillaGTK.cxx
4 index 0871ca2..49dc278 100644
5 --- scintilla/gtk/ScintillaGTK.cxx
6 +++ scintilla/gtk/ScintillaGTK.cxx
7 @@ -3205,11 +3205,13 @@
10 /* legacy name for scintilla_object_send_message */
11 +GEANY_API_SYMBOL
12 sptr_t scintilla_send_message(ScintillaObject *sci, unsigned int iMessage, uptr_t wParam, sptr_t lParam) {
13 ScintillaGTK *psci = static_cast<ScintillaGTK *>(sci->pscin);
14 return psci->WndProc(static_cast<Message>(iMessage), wParam, lParam);
17 +GEANY_API_SYMBOL
18 gintptr scintilla_object_send_message(ScintillaObject *sci, unsigned int iMessage, uptr_t wParam, sptr_t lParam) {
19 return scintilla_send_message(sci, iMessage, wParam, lParam);
21 @@ -3218,6 +3220,7 @@
22 static void scintilla_init(ScintillaObject *sci);
24 /* legacy name for scintilla_object_get_type */
25 +GEANY_API_SYMBOL
26 GType scintilla_get_type() {
27 static GType scintilla_type = 0;
28 try {
29 @@ -3247,6 +3250,7 @@
30 return scintilla_type;
33 +GEANY_API_SYMBOL
34 GType scintilla_object_get_type() {
35 return scintilla_get_type();
37 @@ -3352,6 +3356,7 @@
40 /* legacy name for scintilla_object_new */
41 +GEANY_API_SYMBOL
42 GtkWidget *scintilla_new() {
43 GtkWidget *widget = GTK_WIDGET(g_object_new(scintilla_get_type(), nullptr));
44 gtk_widget_set_direction(widget, GTK_TEXT_DIR_LTR);
45 @@ -3359,6 +3364,7 @@
46 return widget;
49 +GEANY_API_SYMBOL
50 GtkWidget *scintilla_object_new() {
51 return scintilla_new();
53 @@ -3381,6 +3387,7 @@
54 static void *copy_(void *src) { return src; }
55 static void free_(void *) { }
57 +GEANY_API_SYMBOL
58 GType scnotification_get_type(void) {
59 static gsize type_id = 0;
60 if (g_once_init_enter(&type_id)) {
61 diff --git scintilla/lexilla/src/Lexilla.cxx scintilla/lexilla/src/Lexilla.cxx
62 index cd4b23617..af4a73db4 100644
63 --- scintilla/lexilla/src/Lexilla.cxx
64 +++ scintilla/lexilla/src/Lexilla.cxx
65 @@ -167,8 +167,67 @@
67 CatalogueModules catalogueLexilla;
69 +static void AddGeanyLexers()
71 + catalogueLexilla.AddLexerModules({
72 + &lmAbaqus,
73 + &lmAda,
74 + &lmAsm,
75 + &lmAU3,
76 + &lmBash,
77 + &lmBatch,
78 + &lmCaml,
79 + &lmCmake,
80 + &lmCOBOL,
81 + &lmCoffeeScript,
82 + &lmCPP,
83 + &lmCss,
84 + &lmD,
85 + &lmDiff,
86 + &lmErlang,
87 + &lmF77,
88 + &lmForth,
89 + &lmFortran,
90 + &lmFreeBasic,
91 + &lmGDScript,
92 + &lmHaskell,
93 + &lmHTML,
94 + &lmJulia,
95 + &lmLatex,
96 + &lmLISP,
97 + &lmLua,
98 + &lmMake,
99 + &lmMarkdown,
100 + &lmNsis,
101 + &lmNull,
102 + &lmOctave,
103 + &lmPascal,
104 + &lmPerl,
105 + &lmPHPSCRIPT,
106 + &lmPO,
107 + &lmPowerShell,
108 + &lmProps,
109 + &lmPython,
110 + &lmR,
111 + &lmRuby,
112 + &lmRust,
113 + &lmSmalltalk,
114 + &lmSQL,
115 + &lmTCL,
116 + &lmTxt2tags,
117 + &lmVerilog,
118 + &lmVHDL,
119 + &lmXML,
120 + &lmYAML,
121 + });
125 void AddEachLexer() {
127 + AddGeanyLexers();
128 + return;
130 if (catalogueLexilla.Count() > 0) {
131 return;