More GTK3 Waf build system adjustments
[geany-mirror.git] / doc / geany.html
blobda90e8107d59773c308c48bc654270b2b7289709
1 <?xml version="1.0" encoding="utf-8" ?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4 <head>
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6 <meta name="generator" content="Docutils 0.8.1: http://docutils.sourceforge.net/" />
7 <title>Geany</title>
8 <meta name="authors" content="Enrico Tröger Nick Treleaven Frank Lanitz Colomban Wendling Matthew Brush" />
9 <meta name="date" content="2013-03-10" />
10 <style type="text/css">
13 :Author: Enrico Troeger
14 :Contact: enrico(dot)troeger(at)uvena(dot)de
15 :Copyright: This stylesheet has been placed in the public domain.
17 Stylesheet for Geany's documentation based on a version of John Gabriele.
20 @media screen {
22 body {
23 background-color: #f2f2f2;
24 color: #404040;
25 margin-left: 0.4em;
26 max-width: 60em;
27 font-size: 90%;
30 a {
31 color: #990000;
34 a:visited {
35 color: #7E558E;
38 a:hover {
39 text-decoration: none;
42 h1 {
43 border-top: 1px dotted;
44 margin-top: 2em;
47 h1, h2, h3 {
48 font-family: sans-serif;
49 color: #5D0606;
52 h1.title {
53 text-align: left }
55 h2 {
56 margin-top: 30px;
59 h2.subtitle {
60 text-align: left }
62 h3 {
63 padding-left: 3px;
66 blockquote, pre {
67 border: 1px solid;
68 padding: 0.4em;
71 blockquote {
72 font-family: sans-serif;
73 background-color: #DBEDD5;
74 border: 1px dotted;
75 border-left: 4px solid;
76 border-color: #9FD98C;
79 pre {
80 background-color: #ECDFCE;
81 border: 1px dotted;
82 border-left: 4px solid;
83 border-color: #D9BE9A;
86 tt, pre, code {
87 color: #6D4212;
90 table {
91 border: 1px solid #D9BE9A;
94 th {
95 background-color: #ECDFCE;
96 border: 1px dotted #D9BE9A;
99 td {
100 border: 1px dotted #D9BE9A;
103 .docinfo-name {
104 color: #5D0606;
107 p.admonition-title {
108 color: #990000;
109 font-weight: bold;
112 div.note {
113 margin: 1em 3em;
114 padding: 0em;
117 dt {
118 font-style: italic;
123 @media print {
127 </style>
128 </head>
129 <body>
130 <div class="document" id="geany">
131 <h1 class="title">Geany</h1>
132 <h2 class="subtitle" id="a-fast-light-gtk-ide">A fast, light, GTK+ IDE</h2>
133 <table class="docinfo" frame="void" rules="none">
134 <col class="docinfo-name" />
135 <col class="docinfo-content" />
136 <tbody valign="top">
137 <tr><th class="docinfo-name">Authors:</th>
138 <td>Enrico Tröger
139 <br />Nick Treleaven
140 <br />Frank Lanitz
141 <br />Colomban Wendling
142 <br />Matthew Brush</td></tr>
143 <tr><th class="docinfo-name">Date:</th>
144 <td>2013-03-10</td></tr>
145 <tr><th class="docinfo-name">Version:</th>
146 <td>1.23</td></tr>
147 </tbody>
148 </table>
149 <p>Copyright © 2005-2012</p>
150 <p>This document is distributed under the terms of the GNU General Public
151 License as published by the Free Software Foundation; either version 2
152 of the License, or (at your option) any later version. A copy of this
153 license can be found in the file COPYING included with the source code
154 of this program, and also in the chapter <a class="reference internal" href="#gnu-general-public-license">GNU General Public License</a>.</p>
155 <div class="contents topic" id="contents">
156 <p class="topic-title first">Contents</p>
157 <ul class="simple">
158 <li><a class="reference internal" href="#introduction" id="id7">Introduction</a><ul>
159 <li><a class="reference internal" href="#about-geany" id="id8">About Geany</a></li>
160 <li><a class="reference internal" href="#where-to-get-it" id="id9">Where to get it</a></li>
161 <li><a class="reference internal" href="#license" id="id10">License</a></li>
162 <li><a class="reference internal" href="#about-this-document" id="id11">About this document</a></li>
163 </ul>
164 </li>
165 <li><a class="reference internal" href="#installation" id="id12">Installation</a><ul>
166 <li><a class="reference internal" href="#requirements" id="id13">Requirements</a></li>
167 <li><a class="reference internal" href="#binary-packages" id="id14">Binary packages</a></li>
168 <li><a class="reference internal" href="#source-compilation" id="id15">Source compilation</a><ul>
169 <li><a class="reference internal" href="#autotools-based-build-system" id="id16">Autotools based build system</a></li>
170 <li><a class="reference internal" href="#waf-based-build-system" id="id17">Waf based build system</a><ul>
171 <li><a class="reference internal" href="#waf-cache" id="id18">Waf cache</a><ul>
172 <li><a class="reference internal" href="#cleaning-the-cache" id="id19">Cleaning the cache</a></li>
173 </ul>
174 </li>
175 </ul>
176 </li>
177 <li><a class="reference internal" href="#custom-installation" id="id20">Custom installation</a></li>
178 <li><a class="reference internal" href="#dynamic-linking-loader-support-and-vte" id="id21">Dynamic linking loader support and VTE</a></li>
179 <li><a class="reference internal" href="#build-problems" id="id22">Build problems</a></li>
180 </ul>
181 </li>
182 <li><a class="reference internal" href="#installation-prefix" id="id23">Installation prefix</a></li>
183 </ul>
184 </li>
185 <li><a class="reference internal" href="#usage" id="id24">Usage</a><ul>
186 <li><a class="reference internal" href="#getting-started" id="id25">Getting started</a></li>
187 <li><a class="reference internal" href="#the-geany-workspace" id="id26">The Geany workspace</a></li>
188 <li><a class="reference internal" href="#command-line-options" id="id27">Command line options</a></li>
189 <li><a class="reference internal" href="#general" id="id28">General</a><ul>
190 <li><a class="reference internal" href="#startup" id="id29">Startup</a></li>
191 <li><a class="reference internal" href="#opening-files-from-the-command-line-in-a-running-instance" id="id30">Opening files from the command-line in a running instance</a></li>
192 <li><a class="reference internal" href="#virtual-terminal-emulator-widget-vte" id="id31">Virtual terminal emulator widget (VTE)</a></li>
193 <li><a class="reference internal" href="#defining-own-widget-styles-using-gtkrc-2-0" id="id32">Defining own widget styles using .gtkrc-2.0</a></li>
194 </ul>
195 </li>
196 <li><a class="reference internal" href="#documents" id="id33">Documents</a><ul>
197 <li><a class="reference internal" href="#switching-between-documents" id="id34">Switching between documents</a></li>
198 <li><a class="reference internal" href="#cloning-documents" id="id35">Cloning documents</a></li>
199 </ul>
200 </li>
201 <li><a class="reference internal" href="#character-sets-and-unicode-byte-order-mark-bom" id="id36">Character sets and Unicode Byte-Order-Mark (BOM)</a><ul>
202 <li><a class="reference internal" href="#using-character-sets" id="id37">Using character sets</a></li>
203 <li><a class="reference internal" href="#in-file-encoding-specification" id="id38">In-file encoding specification</a></li>
204 <li><a class="reference internal" href="#special-encoding-none" id="id39">Special encoding &quot;None&quot;</a></li>
205 <li><a class="reference internal" href="#unicode-byte-order-mark-bom" id="id40">Unicode Byte-Order-Mark (BOM)</a></li>
206 </ul>
207 </li>
208 <li><a class="reference internal" href="#editing" id="id41">Editing</a><ul>
209 <li><a class="reference internal" href="#folding" id="id42">Folding</a></li>
210 <li><a class="reference internal" href="#column-mode-editing-rectangular-selections" id="id43">Column mode editing (rectangular selections)</a></li>
211 <li><a class="reference internal" href="#drag-and-drop-of-text" id="id44">Drag and drop of text</a></li>
212 <li><a class="reference internal" href="#indentation" id="id45">Indentation</a><ul>
213 <li><a class="reference internal" href="#applying-new-indentation-settings" id="id46">Applying new indentation settings</a></li>
214 <li><a class="reference internal" href="#detecting-indent-type" id="id47">Detecting indent type</a></li>
215 </ul>
216 </li>
217 <li><a class="reference internal" href="#auto-indentation" id="id48">Auto-indentation</a></li>
218 <li><a class="reference internal" href="#bookmarks" id="id49">Bookmarks</a></li>
219 <li><a class="reference internal" href="#code-navigation-history" id="id50">Code navigation history</a></li>
220 <li><a class="reference internal" href="#sending-text-through-custom-commands" id="id51">Sending text through custom commands</a></li>
221 <li><a class="reference internal" href="#context-actions" id="id52">Context actions</a></li>
222 <li><a class="reference internal" href="#autocompletion" id="id53">Autocompletion</a><ul>
223 <li><a class="reference internal" href="#word-part-completion" id="id54">Word part completion</a></li>
224 <li><a class="reference internal" href="#scope-autocompletion" id="id55">Scope autocompletion</a></li>
225 </ul>
226 </li>
227 <li><a class="reference internal" href="#user-definable-snippets" id="id56">User-definable snippets</a><ul>
228 <li><a class="reference internal" href="#snippet-keybindings" id="id57">Snippet keybindings</a></li>
229 </ul>
230 </li>
231 <li><a class="reference internal" href="#inserting-unicode-characters" id="id58">Inserting Unicode characters</a></li>
232 </ul>
233 </li>
234 <li><a class="reference internal" href="#search-replace-and-go-to" id="id59">Search, replace and go to</a><ul>
235 <li><a class="reference internal" href="#toolbar-entries" id="id60">Toolbar entries</a><ul>
236 <li><a class="reference internal" href="#search-bar" id="id61">Search bar</a></li>
237 </ul>
238 </li>
239 <li><a class="reference internal" href="#find" id="id62">Find</a><ul>
240 <li><a class="reference internal" href="#matching-options" id="id63">Matching options</a></li>
241 <li><a class="reference internal" href="#find-all" id="id64">Find all</a></li>
242 <li><a class="reference internal" href="#change-font-in-search-dialog-text-fields" id="id65">Change font in search dialog text fields</a></li>
243 </ul>
244 </li>
245 <li><a class="reference internal" href="#find-selection" id="id66">Find selection</a></li>
246 <li><a class="reference internal" href="#find-usage" id="id67">Find usage</a></li>
247 <li><a class="reference internal" href="#find-in-files" id="id68">Find in files</a><ul>
248 <li><a class="reference internal" href="#filtering-out-version-control-files" id="id69">Filtering out version control files</a></li>
249 </ul>
250 </li>
251 <li><a class="reference internal" href="#replace" id="id70">Replace</a><ul>
252 <li><a class="reference internal" href="#replace-all" id="id71">Replace all</a></li>
253 </ul>
254 </li>
255 <li><a class="reference internal" href="#go-to-tag-definition" id="id72">Go to tag definition</a></li>
256 <li><a class="reference internal" href="#go-to-tag-declaration" id="id73">Go to tag declaration</a></li>
257 <li><a class="reference internal" href="#go-to-line" id="id74">Go to line</a></li>
258 <li><a class="reference internal" href="#regular-expressions" id="id75">Regular expressions</a></li>
259 </ul>
260 </li>
261 <li><a class="reference internal" href="#view-menu" id="id76">View menu</a><ul>
262 <li><a class="reference internal" href="#color-schemes-menu" id="id77">Color schemes menu</a></li>
263 </ul>
264 </li>
265 <li><a class="reference internal" href="#tags" id="id78">Tags</a><ul>
266 <li><a class="reference internal" href="#workspace-tags" id="id79">Workspace tags</a></li>
267 <li><a class="reference internal" href="#global-tags" id="id80">Global tags</a><ul>
268 <li><a class="reference internal" href="#default-global-tags-files" id="id81">Default global tags files</a></li>
269 <li><a class="reference internal" href="#global-tags-file-format" id="id82">Global tags file format</a><ul>
270 <li><a class="reference internal" href="#pipe-separated-format" id="id83">Pipe-separated format</a></li>
271 </ul>
272 </li>
273 <li><a class="reference internal" href="#generating-a-global-tags-file" id="id84">Generating a global tags file</a><ul>
274 <li><a class="reference internal" href="#generating-c-c-tag-files" id="id85">Generating C/C++ tag files</a></li>
275 <li><a class="reference internal" href="#generating-tag-files-on-windows" id="id86">Generating tag files on Windows</a></li>
276 </ul>
277 </li>
278 </ul>
279 </li>
280 <li><a class="reference internal" href="#c-ignore-tags" id="id87">C ignore.tags</a></li>
281 </ul>
282 </li>
283 <li><a class="reference internal" href="#preferences" id="id88">Preferences</a><ul>
284 <li><a class="reference internal" href="#general-startup-preferences" id="id89">General Startup preferences</a><ul>
285 <li><a class="reference internal" href="#id1" id="id90">Startup</a></li>
286 <li><a class="reference internal" href="#shutdown" id="id91">Shutdown</a></li>
287 <li><a class="reference internal" href="#paths" id="id92">Paths</a></li>
288 </ul>
289 </li>
290 <li><a class="reference internal" href="#general-miscellaneous-preferences" id="id93">General Miscellaneous preferences</a><ul>
291 <li><a class="reference internal" href="#miscellaneous" id="id94">Miscellaneous</a></li>
292 <li><a class="reference internal" href="#search" id="id95">Search</a></li>
293 <li><a class="reference internal" href="#projects" id="id96">Projects</a></li>
294 </ul>
295 </li>
296 <li><a class="reference internal" href="#interface-preferences" id="id97">Interface preferences</a><ul>
297 <li><a class="reference internal" href="#sidebar" id="id98">Sidebar</a></li>
298 <li><a class="reference internal" href="#fonts" id="id99">Fonts</a></li>
299 <li><a class="reference internal" href="#id2" id="id100">Miscellaneous</a></li>
300 </ul>
301 </li>
302 <li><a class="reference internal" href="#interface-notebook-tab-preferences" id="id101">Interface Notebook tab preferences</a><ul>
303 <li><a class="reference internal" href="#editor-tabs" id="id102">Editor tabs</a></li>
304 <li><a class="reference internal" href="#tab-positions" id="id103">Tab positions</a></li>
305 </ul>
306 </li>
307 <li><a class="reference internal" href="#interface-toolbar-preferences" id="id104">Interface Toolbar preferences</a><ul>
308 <li><a class="reference internal" href="#toolbar" id="id105">Toolbar</a></li>
309 <li><a class="reference internal" href="#appearance" id="id106">Appearance</a></li>
310 </ul>
311 </li>
312 <li><a class="reference internal" href="#editor-features-preferences" id="id107">Editor Features preferences</a><ul>
313 <li><a class="reference internal" href="#features" id="id108">Features</a></li>
314 </ul>
315 </li>
316 <li><a class="reference internal" href="#editor-indentation-preferences" id="id109">Editor Indentation preferences</a><ul>
317 <li><a class="reference internal" href="#indentation-group" id="id110">Indentation group</a></li>
318 </ul>
319 </li>
320 <li><a class="reference internal" href="#editor-completions-preferences" id="id111">Editor Completions preferences</a><ul>
321 <li><a class="reference internal" href="#completions" id="id112">Completions</a></li>
322 <li><a class="reference internal" href="#auto-close-quotes-and-brackets" id="id113">Auto-close quotes and brackets</a></li>
323 </ul>
324 </li>
325 <li><a class="reference internal" href="#editor-display-preferences" id="id114">Editor Display preferences</a><ul>
326 <li><a class="reference internal" href="#display" id="id115">Display</a></li>
327 <li><a class="reference internal" href="#long-line-marker" id="id116">Long line marker</a></li>
328 <li><a class="reference internal" href="#virtual-spaces" id="id117">Virtual spaces</a></li>
329 </ul>
330 </li>
331 <li><a class="reference internal" href="#files-preferences" id="id118">Files preferences</a><ul>
332 <li><a class="reference internal" href="#new-files" id="id119">New files</a></li>
333 <li><a class="reference internal" href="#saving-files" id="id120">Saving files</a></li>
334 <li><a class="reference internal" href="#id3" id="id121">Miscellaneous</a></li>
335 </ul>
336 </li>
337 <li><a class="reference internal" href="#tools-preferences" id="id122">Tools preferences</a><ul>
338 <li><a class="reference internal" href="#tool-paths" id="id123">Tool paths</a></li>
339 <li><a class="reference internal" href="#commands" id="id124">Commands</a></li>
340 </ul>
341 </li>
342 <li><a class="reference internal" href="#template-preferences" id="id125">Template preferences</a><ul>
343 <li><a class="reference internal" href="#template-data" id="id126">Template data</a></li>
344 </ul>
345 </li>
346 <li><a class="reference internal" href="#keybinding-preferences" id="id127">Keybinding preferences</a></li>
347 <li><a class="reference internal" href="#printing-preferences" id="id128">Printing preferences</a></li>
348 <li><a class="reference internal" href="#various-preferences" id="id129">Various preferences</a></li>
349 <li><a class="reference internal" href="#terminal-vte-preferences" id="id130">Terminal (VTE) preferences</a><ul>
350 <li><a class="reference internal" href="#terminal-widget" id="id131">Terminal widget</a></li>
351 </ul>
352 </li>
353 </ul>
354 </li>
355 <li><a class="reference internal" href="#project-management" id="id132">Project management</a><ul>
356 <li><a class="reference internal" href="#new-project" id="id133">New project</a></li>
357 <li><a class="reference internal" href="#project-properties" id="id134">Project properties</a></li>
358 <li><a class="reference internal" href="#open-project" id="id135">Open project</a></li>
359 <li><a class="reference internal" href="#close-project" id="id136">Close project</a></li>
360 </ul>
361 </li>
362 <li><a class="reference internal" href="#build-menu" id="id137">Build menu</a><ul>
363 <li><a class="reference internal" href="#indicators" id="id138">Indicators</a></li>
364 <li><a class="reference internal" href="#default-build-menu-items" id="id139">Default build menu items</a><ul>
365 <li><a class="reference internal" href="#compile" id="id140">Compile</a></li>
366 <li><a class="reference internal" href="#build" id="id141">Build</a></li>
367 <li><a class="reference internal" href="#make" id="id142">Make</a></li>
368 <li><a class="reference internal" href="#make-custom-target" id="id143">Make custom target</a></li>
369 <li><a class="reference internal" href="#make-object" id="id144">Make object</a></li>
370 <li><a class="reference internal" href="#next-error" id="id145">Next error</a></li>
371 <li><a class="reference internal" href="#previous-error" id="id146">Previous error</a></li>
372 <li><a class="reference internal" href="#execute" id="id147">Execute</a></li>
373 <li><a class="reference internal" href="#stopping-running-processes" id="id148">Stopping running processes</a><ul>
374 <li><a class="reference internal" href="#terminal-emulators" id="id149">Terminal emulators</a></li>
375 </ul>
376 </li>
377 <li><a class="reference internal" href="#set-build-commands" id="id150">Set build commands</a></li>
378 </ul>
379 </li>
380 <li><a class="reference internal" href="#build-menu-configuration" id="id151">Build menu configuration</a></li>
381 <li><a class="reference internal" href="#build-menu-commands-dialog" id="id152">Build menu commands dialog</a><ul>
382 <li><a class="reference internal" href="#substitutions-in-commands-and-working-directories" id="id153">Substitutions in commands and working directories</a></li>
383 <li><a class="reference internal" href="#build-menu-keyboard-shortcuts" id="id154">Build menu keyboard shortcuts</a></li>
384 <li><a class="reference internal" href="#old-settings" id="id155">Old settings</a></li>
385 </ul>
386 </li>
387 </ul>
388 </li>
389 <li><a class="reference internal" href="#printing-support" id="id156">Printing support</a></li>
390 <li><a class="reference internal" href="#plugins" id="id157">Plugins</a><ul>
391 <li><a class="reference internal" href="#plugin-manager" id="id158">Plugin manager</a></li>
392 </ul>
393 </li>
394 <li><a class="reference internal" href="#keybindings" id="id159">Keybindings</a><ul>
395 <li><a class="reference internal" href="#switching-documents" id="id160">Switching documents</a></li>
396 <li><a class="reference internal" href="#configurable-keybindings" id="id161">Configurable keybindings</a><ul>
397 <li><a class="reference internal" href="#file-keybindings" id="id162">File keybindings</a></li>
398 <li><a class="reference internal" href="#editor-keybindings" id="id163">Editor keybindings</a></li>
399 <li><a class="reference internal" href="#clipboard-keybindings" id="id164">Clipboard keybindings</a></li>
400 <li><a class="reference internal" href="#select-keybindings" id="id165">Select keybindings</a></li>
401 <li><a class="reference internal" href="#insert-keybindings" id="id166">Insert keybindings</a></li>
402 <li><a class="reference internal" href="#format-keybindings" id="id167">Format keybindings</a></li>
403 <li><a class="reference internal" href="#settings-keybindings" id="id168">Settings keybindings</a></li>
404 <li><a class="reference internal" href="#search-keybindings" id="id169">Search keybindings</a></li>
405 <li><a class="reference internal" href="#go-to-keybindings" id="id170">Go to keybindings</a></li>
406 <li><a class="reference internal" href="#view-keybindings" id="id171">View keybindings</a></li>
407 <li><a class="reference internal" href="#focus-keybindings" id="id172">Focus keybindings</a></li>
408 <li><a class="reference internal" href="#notebook-tab-keybindings" id="id173">Notebook tab keybindings</a></li>
409 <li><a class="reference internal" href="#document-keybindings" id="id174">Document keybindings</a></li>
410 <li><a class="reference internal" href="#project-keybindings" id="id175">Project keybindings</a></li>
411 <li><a class="reference internal" href="#build-keybindings" id="id176">Build keybindings</a></li>
412 <li><a class="reference internal" href="#tools-keybindings" id="id177">Tools keybindings</a></li>
413 <li><a class="reference internal" href="#help-keybindings" id="id178">Help keybindings</a></li>
414 </ul>
415 </li>
416 </ul>
417 </li>
418 </ul>
419 </li>
420 <li><a class="reference internal" href="#configuration-files" id="id179">Configuration files</a><ul>
421 <li><a class="reference internal" href="#configuration-file-paths" id="id180">Configuration file paths</a><ul>
422 <li><a class="reference internal" href="#paths-on-unix-like-systems" id="id181">Paths on Unix-like systems</a></li>
423 <li><a class="reference internal" href="#paths-on-windows" id="id182">Paths on Windows</a></li>
424 </ul>
425 </li>
426 <li><a class="reference internal" href="#tools-menu-items" id="id183">Tools menu items</a></li>
427 <li><a class="reference internal" href="#global-configuration-file" id="id184">Global configuration file</a></li>
428 <li><a class="reference internal" href="#filetype-definition-files" id="id185">Filetype definition files</a><ul>
429 <li><a class="reference internal" href="#filenames" id="id186">Filenames</a></li>
430 <li><a class="reference internal" href="#system-files" id="id187">System files</a></li>
431 <li><a class="reference internal" href="#user-files" id="id188">User files</a></li>
432 <li><a class="reference internal" href="#custom-filetypes" id="id189">Custom filetypes</a><ul>
433 <li><a class="reference internal" href="#creating-a-custom-filetype-from-an-existing-filetype" id="id190">Creating a custom filetype from an existing filetype</a></li>
434 </ul>
435 </li>
436 <li><a class="reference internal" href="#filetype-configuration" id="id191">Filetype configuration</a><ul>
437 <li><a class="reference internal" href="#styling-section" id="id192">[styling] section</a><ul>
438 <li><a class="reference internal" href="#using-a-named-style" id="id193">Using a named style</a></li>
439 <li><a class="reference internal" href="#reading-styles-from-another-filetype" id="id194">Reading styles from another filetype</a></li>
440 </ul>
441 </li>
442 <li><a class="reference internal" href="#keywords-section" id="id195">[keywords] section</a></li>
443 <li><a class="reference internal" href="#lexer-properties-section" id="id196">[lexer_properties] section</a></li>
444 <li><a class="reference internal" href="#settings-section" id="id197">[settings] section</a></li>
445 <li><a class="reference internal" href="#indentation-section" id="id198">[indentation] section</a></li>
446 <li><a class="reference internal" href="#build-settings-section" id="id199">[build_settings] section</a></li>
447 </ul>
448 </li>
449 <li><a class="reference internal" href="#special-file-filetypes-common" id="id200">Special file filetypes.common</a><ul>
450 <li><a class="reference internal" href="#named-styles-section" id="id201">[named_styles] section</a></li>
451 <li><a class="reference internal" href="#named-colors-section" id="id202">[named_colors] section</a></li>
452 <li><a class="reference internal" href="#id4" id="id203">[styling] section</a></li>
453 <li><a class="reference internal" href="#id5" id="id204">[settings] section</a></li>
454 </ul>
455 </li>
456 </ul>
457 </li>
458 <li><a class="reference internal" href="#filetype-extensions" id="id205">Filetype extensions</a></li>
459 <li><a class="reference internal" href="#filetype-group-membership" id="id206">Filetype group membership</a></li>
460 <li><a class="reference internal" href="#preferences-file-format" id="id207">Preferences file format</a><ul>
461 <li><a class="reference internal" href="#build-menu-section" id="id208">[build-menu] section</a></li>
462 </ul>
463 </li>
464 <li><a class="reference internal" href="#project-file-format" id="id209">Project file format</a><ul>
465 <li><a class="reference internal" href="#build-menu-additions" id="id210">[build-menu] additions</a></li>
466 </ul>
467 </li>
468 <li><a class="reference internal" href="#templates" id="id211">Templates</a><ul>
469 <li><a class="reference internal" href="#template-meta-data" id="id212">Template meta data</a></li>
470 <li><a class="reference internal" href="#file-templates" id="id213">File templates</a><ul>
471 <li><a class="reference internal" href="#adding-file-templates" id="id214">Adding file templates</a></li>
472 </ul>
473 </li>
474 <li><a class="reference internal" href="#customizing-templates" id="id215">Customizing templates</a><ul>
475 <li><a class="reference internal" href="#template-wildcards" id="id216">Template wildcards</a><ul>
476 <li><a class="reference internal" href="#special-command-wildcard" id="id217">Special {command:} wildcard</a></li>
477 </ul>
478 </li>
479 </ul>
480 </li>
481 </ul>
482 </li>
483 <li><a class="reference internal" href="#customizing-the-toolbar" id="id218">Customizing the toolbar</a><ul>
484 <li><a class="reference internal" href="#manually-editing-the-toolbar-layout" id="id219">Manually editing the toolbar layout</a></li>
485 <li><a class="reference internal" href="#available-toolbar-elements" id="id220">Available toolbar elements</a></li>
486 </ul>
487 </li>
488 </ul>
489 </li>
490 <li><a class="reference internal" href="#plugin-documentation" id="id221">Plugin documentation</a><ul>
491 <li><a class="reference internal" href="#html-characters" id="id222">HTML Characters</a><ul>
492 <li><a class="reference internal" href="#insert-entity-dialog" id="id223">Insert entity dialog</a></li>
493 <li><a class="reference internal" href="#replace-special-chars-by-its-entity" id="id224">Replace special chars by its entity</a><ul>
494 <li><a class="reference internal" href="#at-typing-time" id="id225">At typing time</a></li>
495 <li><a class="reference internal" href="#bulk-replacement" id="id226">Bulk replacement</a></li>
496 </ul>
497 </li>
498 </ul>
499 </li>
500 <li><a class="reference internal" href="#save-actions" id="id227">Save Actions</a><ul>
501 <li><a class="reference internal" href="#instant-save" id="id228">Instant Save</a></li>
502 <li><a class="reference internal" href="#backup-copy" id="id229">Backup Copy</a></li>
503 </ul>
504 </li>
505 </ul>
506 </li>
507 <li><a class="reference internal" href="#contributing-to-this-document" id="id230">Contributing to this document</a></li>
508 <li><a class="reference internal" href="#scintilla-keyboard-commands" id="id231">Scintilla keyboard commands</a><ul>
509 <li><a class="reference internal" href="#keyboard-commands" id="id232">Keyboard commands</a></li>
510 </ul>
511 </li>
512 <li><a class="reference internal" href="#tips-and-tricks" id="id233">Tips and tricks</a><ul>
513 <li><a class="reference internal" href="#document-notebook" id="id234">Document notebook</a></li>
514 <li><a class="reference internal" href="#editor" id="id235">Editor</a></li>
515 <li><a class="reference internal" href="#interface" id="id236">Interface</a></li>
516 <li><a class="reference internal" href="#gtk-related" id="id237">GTK-related</a></li>
517 </ul>
518 </li>
519 <li><a class="reference internal" href="#compile-time-options" id="id238">Compile-time options</a><ul>
520 <li><a class="reference internal" href="#src-geany-h" id="id239">src/geany.h</a></li>
521 <li><a class="reference internal" href="#project-h" id="id240">project.h</a></li>
522 <li><a class="reference internal" href="#filetypes-c" id="id241">filetypes.c</a></li>
523 <li><a class="reference internal" href="#editor-h" id="id242">editor.h</a></li>
524 <li><a class="reference internal" href="#keyfile-c" id="id243">keyfile.c</a></li>
525 <li><a class="reference internal" href="#build-c" id="id244">build.c</a></li>
526 </ul>
527 </li>
528 <li><a class="reference internal" href="#gnu-general-public-license" id="id245">GNU General Public License</a></li>
529 <li><a class="reference internal" href="#license-for-scintilla-and-scite" id="id246">License for Scintilla and SciTE</a></li>
530 </ul>
531 </div>
532 <div class="section" id="introduction">
533 <h1><a class="toc-backref" href="#id7">Introduction</a></h1>
534 <div class="section" id="about-geany">
535 <h2><a class="toc-backref" href="#id8">About Geany</a></h2>
536 <p>Geany is a small and lightweight Integrated Development Environment. It
537 was developed to provide a small and fast IDE, which has only a few
538 dependencies on other packages. Another goal was to be as independent
539 as possible from a particular Desktop Environment like KDE or GNOME -
540 Geany only requires the GTK2 runtime libraries.</p>
541 <p>Some basic features of Geany:</p>
542 <ul class="simple">
543 <li>Syntax highlighting</li>
544 <li>Code folding</li>
545 <li>Autocompletion of symbols/words</li>
546 <li>Construct completion/snippets</li>
547 <li>Auto-closing of XML and HTML tags</li>
548 <li>Calltips</li>
549 <li>Many supported filetypes including C, Java, PHP, HTML, Python, Perl,
550 Pascal, and others</li>
551 <li>Symbol lists</li>
552 <li>Code navigation</li>
553 <li>Build system to compile and execute your code</li>
554 <li>Simple project management</li>
555 <li>Plugin interface</li>
556 </ul>
557 </div>
558 <div class="section" id="where-to-get-it">
559 <h2><a class="toc-backref" href="#id9">Where to get it</a></h2>
560 <p>You can obtain Geany from <a class="reference external" href="http://www.geany.org/">http://www.geany.org/</a> or perhaps also from
561 your distribution. For a list of available packages, please see
562 <a class="reference external" href="http://www.geany.org/Download/ThirdPartyPackages">http://www.geany.org/Download/ThirdPartyPackages</a>.</p>
563 </div>
564 <div class="section" id="license">
565 <h2><a class="toc-backref" href="#id10">License</a></h2>
566 <p>Geany is distributed under the terms of the GNU General Public License
567 as published by the Free Software Foundation; either version 2 of
568 the License, or (at your option) any later version. A copy of this
569 license can be found in the file COPYING included with the source
570 code of this program and in the chapter, <a class="reference internal" href="#gnu-general-public-license">GNU General Public License</a>.</p>
571 <p>The included Scintilla library (found in the subdirectory
572 <tt class="docutils literal">scintilla/</tt>) has its own license, which can be found in the chapter,
573 <a class="reference internal" href="#license-for-scintilla-and-scite">License for Scintilla and SciTE</a>.</p>
574 </div>
575 <div class="section" id="about-this-document">
576 <h2><a class="toc-backref" href="#id11">About this document</a></h2>
577 <p>This documentation is available in HTML and text formats.
578 The latest version can always be found at <a class="reference external" href="http://www.geany.org/">http://www.geany.org/</a>.</p>
579 <p>If you want to contribute to it, see <a class="reference internal" href="#contributing-to-this-document">Contributing to this document</a>.</p>
580 </div>
581 </div>
582 <div class="section" id="installation">
583 <h1><a class="toc-backref" href="#id12">Installation</a></h1>
584 <div class="section" id="requirements">
585 <h2><a class="toc-backref" href="#id13">Requirements</a></h2>
586 <p>You will need the GTK (&gt;= 2.16.0) libraries and their dependencies
587 (Pango, GLib and ATK). Your distro should provide packages for these,
588 usually installed by default. For Windows, you can download an installer
589 from the website which bundles these libraries.</p>
590 </div>
591 <div class="section" id="binary-packages">
592 <h2><a class="toc-backref" href="#id14">Binary packages</a></h2>
593 <p>There are many binary packages available. For an up-to-date but maybe
594 incomplete list see <a class="reference external" href="http://www.geany.org/Download/ThirdPartyPackages">http://www.geany.org/Download/ThirdPartyPackages</a>.</p>
595 </div>
596 <div class="section" id="source-compilation">
597 <h2><a class="toc-backref" href="#id15">Source compilation</a></h2>
598 <p>Compiling Geany is quite easy.
599 To do so, you need the GTK (&gt;= 2.16.0) libraries and header files.
600 You also need the Pango, GLib and ATK libraries and header files.
601 All these files are available at <a class="reference external" href="http://www.gtk.org">http://www.gtk.org</a>, but very often
602 your distro will provide development packages to save the trouble of
603 building these yourself.</p>
604 <p>Furthermore you need, of course, a C and C++ compiler. The GNU versions
605 of these tools are recommended.</p>
606 <div class="section" id="autotools-based-build-system">
607 <h3><a class="toc-backref" href="#id16">Autotools based build system</a></h3>
608 <p>The Autotools based build system is very mature and has been well tested.
609 To use it, you just need the Make tool, preferably GNU Make.</p>
610 <p>Then run the following commands:</p>
611 <pre class="literal-block">
612 $ ./configure
613 $ make
614 </pre>
615 <p>Then as root:</p>
616 <pre class="literal-block">
617 % make install
618 </pre>
619 </div>
620 <div class="section" id="waf-based-build-system">
621 <h3><a class="toc-backref" href="#id17">Waf based build system</a></h3>
622 <p>The Waf build system is still quite young and under heavy development but already in a
623 usable state. In contrast to the Autotools system, Waf needs Python. So before using Waf, you need
624 to install Python on your system.
625 The advantage of the Waf build system over the Autotools based build system is that the whole
626 build process might be a bit faster. Especially when you use the Waf
627 cache feature for repetitive builds (e.g. when changing only a few source files
628 to test something) will become much faster since Waf will cache and re-use the
629 unchanged built files and only compile the changed code again. See <a class="reference internal" href="#waf-cache">Waf Cache</a> for details.
630 To build Geany with Waf as run:</p>
631 <pre class="literal-block">
632 $ ./waf configure
633 $ ./waf build
634 </pre>
635 <p>Then as root:</p>
636 <pre class="literal-block">
637 % ./waf install
638 </pre>
639 <div class="section" id="waf-cache">
640 <h4><a class="toc-backref" href="#id18">Waf cache</a></h4>
641 <p>The Waf build system has a nice and interesting feature which can help to avoid
642 a lot of unnecessary rebuilding of unchanged code. This often happens when developing new features
643 or trying to debug something in Geany.
644 Waf is able to store and retrieve the object files from a cache. This cache is declared
645 using the environment variable <tt class="docutils literal">WAFCACHE</tt>.
646 A possible location of the cache directory could be <tt class="docutils literal"><span class="pre">~/.cache/waf</span></tt>. In order to make use of
647 this, you first need to create this directory:</p>
648 <pre class="literal-block">
649 $ mkdir -p ~/.cache/waf
650 </pre>
651 <p>then add the environment variable to your shell configuration (the following example is for
652 Bash and should be adjusted to your used shell):</p>
653 <pre class="literal-block">
654 export WAFCACHE=/home/username/.cache/waf
655 </pre>
656 <p>Remember to replace <tt class="docutils literal">username</tt> with your actual username.</p>
657 <p>More information about the Waf cache feature are available at
658 <a class="reference external" href="http://code.google.com/p/waf/wiki/CacheObjectFiles">http://code.google.com/p/waf/wiki/CacheObjectFiles</a>.</p>
659 <div class="section" id="cleaning-the-cache">
660 <h5><a class="toc-backref" href="#id19">Cleaning the cache</a></h5>
661 <p>You should be careful about the size of the cache directory as it may
662 grow rapidly over time.
663 Waf doesn't do any cleaning or other house-keeping of the cache yet, so you need to keep it
664 clean by yourself.
665 An easy way to keep it clean is to run the following command regularly to remove old
666 cached files:</p>
667 <pre class="literal-block">
668 $ find /home/username/.cache/waf -mtime +14 -exec rm {} \;
669 </pre>
670 <p>This will delete all files in the cache directory which are older than 14 days.</p>
671 <p>For details about the <tt class="docutils literal">find</tt> command and its options, check its manual page.</p>
672 </div>
673 </div>
674 </div>
675 <div class="section" id="custom-installation">
676 <h3><a class="toc-backref" href="#id20">Custom installation</a></h3>
677 <p>The configure script supports several common options, for a detailed
678 list, type:</p>
679 <pre class="literal-block">
680 $ ./configure --help
681 </pre>
682 <dl class="docutils">
683 <dt>or::</dt>
684 <dd>$ ./waf --help</dd>
685 </dl>
686 <p>(depending on which build system you use).</p>
687 <p>You may also want to read the INSTALL file for advanced installation
688 options.</p>
689 <ul class="simple">
690 <li>See also <a class="reference internal" href="#compile-time-options">Compile-time options</a>.</li>
691 </ul>
692 </div>
693 <div class="section" id="dynamic-linking-loader-support-and-vte">
694 <h3><a class="toc-backref" href="#id21">Dynamic linking loader support and VTE</a></h3>
695 <p>In the case that your system lacks dynamic linking loader support, you
696 probably want to pass the option <tt class="docutils literal"><span class="pre">--disable-vte</span></tt> to the <tt class="docutils literal">configure</tt>
697 script. This prevents compiling Geany with dynamic linking loader
698 support for automatically loading <tt class="docutils literal">libvte.so.4</tt> if available.</p>
699 </div>
700 <div class="section" id="build-problems">
701 <h3><a class="toc-backref" href="#id22">Build problems</a></h3>
702 <p>If there are any errors during compilation, check your build
703 environment and try to find the error, otherwise contact the mailing
704 list or one the authors. Sometimes you might need to ask for specific
705 help from your distribution.</p>
706 </div>
707 </div>
708 <div class="section" id="installation-prefix">
709 <h2><a class="toc-backref" href="#id23">Installation prefix</a></h2>
710 <p>If you want to find Geany's system files after installation you may
711 want to know the installation prefix.</p>
712 <p>Pass the <tt class="docutils literal"><span class="pre">--print-prefix</span></tt> option to Geany to check this - see
713 <a class="reference internal" href="#command-line-options">Command line options</a>. The first path is the prefix.</p>
714 <p>On Unix-like systems this is commonly <tt class="docutils literal">/usr</tt> if you installed from
715 a binary package, or <tt class="docutils literal">/usr/local</tt> if you build from source.</p>
716 <div class="note">
717 <p class="first admonition-title">Note</p>
718 <p class="last">Editing system files is not necessary as you should use the
719 per-user configuration files instead, which don't need root
720 permissions. See <a class="reference internal" href="#configuration-files">Configuration files</a>.</p>
721 </div>
722 </div>
723 </div>
724 <div class="section" id="usage">
725 <h1><a class="toc-backref" href="#id24">Usage</a></h1>
726 <div class="section" id="getting-started">
727 <h2><a class="toc-backref" href="#id25">Getting started</a></h2>
728 <p>You can start Geany in the following ways:</p>
729 <ul>
730 <li><p class="first">From the Desktop Environment menu:</p>
731 <p>Choose in your application menu of your used Desktop Environment:
732 Development --&gt; Geany.</p>
733 </li>
734 <li><p class="first">From the command line:</p>
735 <p>To start Geany from a command line, type the following and press
736 Return:</p>
737 <pre class="literal-block">
738 % geany
739 </pre>
740 </li>
741 </ul>
742 </div>
743 <div class="section" id="the-geany-workspace">
744 <h2><a class="toc-backref" href="#id26">The Geany workspace</a></h2>
745 <p>The Geany window is shown in the following figure:</p>
746 <img alt="./images/main_window.png" src="./images/main_window.png" />
747 <p>The workspace has the following parts:</p>
748 <ul class="simple">
749 <li>The menu.</li>
750 <li>An optional toolbar.</li>
751 <li>An optional sidebar that can show the following tabs:<ul>
752 <li>Documents - A document list, and</li>
753 <li>Symbols - A list of symbols in your code.</li>
754 </ul>
755 </li>
756 <li>The main editor window.</li>
757 <li>An optional message window which can show the following tabs:<ul>
758 <li>Status - A list of status messages.</li>
759 <li>Compiler - The output of compiling or building programs.</li>
760 <li>Messages - Results of 'Find Usage', 'Find in Files' and other actions</li>
761 <li>Scribble - A text scratchpad for any use.</li>
762 <li>Terminal - An optional terminal window.</li>
763 </ul>
764 </li>
765 <li>A status bar</li>
766 </ul>
767 <p>Most of these can be configured in the <a class="reference internal" href="#interface-preferences">Interface preferences</a>, the
768 <a class="reference internal" href="#view-menu">View menu</a>, or the popup menu for the relevant area.</p>
769 <p>Additional tabs may be added to the sidebar and message window by plugins.</p>
770 <p>The position of the tabs can be selected in the interface preferences.</p>
771 <p>The sizes of the sidebar and message window can be adjusted by
772 dragging the dividers.</p>
773 </div>
774 <div class="section" id="command-line-options">
775 <h2><a class="toc-backref" href="#id27">Command line options</a></h2>
776 <table border="1" class="docutils">
777 <colgroup>
778 <col width="9%" />
779 <col width="18%" />
780 <col width="72%" />
781 </colgroup>
782 <thead valign="bottom">
783 <tr><th class="head">Short option</th>
784 <th class="head">Long option</th>
785 <th class="head">Function</th>
786 </tr>
787 </thead>
788 <tbody valign="top">
789 <tr><td><em>none</em></td>
790 <td>+number</td>
791 <td>Set initial line number for the first opened file
792 (same as --line, do not put a space between the + sign
793 and the number). E.g. &quot;geany +7 foo.bar&quot; will open the
794 file foo.bar and place the cursor in line 7.</td>
795 </tr>
796 <tr><td><em>none</em></td>
797 <td>--column</td>
798 <td>Set initial column number for the first opened file.</td>
799 </tr>
800 <tr><td>-c dir_name</td>
801 <td>--config=directory_name</td>
802 <td>Use an alternate configuration directory. The default
803 configuration directory is <tt class="docutils literal"><span class="pre">~/.config/geany/</span></tt> and that
804 is where <tt class="docutils literal">geany.conf</tt> and other configuration files
805 reside.</td>
806 </tr>
807 <tr><td><em>none</em></td>
808 <td>--ft-names</td>
809 <td>Print a list of Geany's internal filetype names (useful
810 for snippets configuration).</td>
811 </tr>
812 <tr><td>-g</td>
813 <td>--generate-tags</td>
814 <td>Generate a global tags file (see
815 <a class="reference internal" href="#generating-a-global-tags-file">Generating a global tags file</a>).</td>
816 </tr>
817 <tr><td>-P</td>
818 <td>--no-preprocessing</td>
819 <td>Don't preprocess C/C++ files when generating tags.</td>
820 </tr>
821 <tr><td>-i</td>
822 <td>--new-instance</td>
823 <td>Do not open files in a running instance, force opening
824 a new instance. Only available if Geany was compiled
825 with support for Sockets.</td>
826 </tr>
827 <tr><td>-l</td>
828 <td>--line</td>
829 <td>Set initial line number for the first opened file.</td>
830 </tr>
831 <tr><td><em>none</em></td>
832 <td>--list-documents</td>
833 <td>Return a list of open documents in a running Geany
834 instance.
835 This can be used to read the currently opened documents in
836 Geany from an external script or tool. The returned list
837 is separated by newlines (LF) and consists of the full,
838 UTF-8 encoded filenames of the documents.
839 Only available if Geany was compiled with support for
840 Sockets.</td>
841 </tr>
842 <tr><td>-m</td>
843 <td>--no-msgwin</td>
844 <td>Do not show the message window. Use this option if you
845 do not need compiler messages or VTE support.</td>
846 </tr>
847 <tr><td>-n</td>
848 <td>--no-ctags</td>
849 <td>Do not load symbol completion and call tip data. Use this
850 option if you do not want to use them.</td>
851 </tr>
852 <tr><td>-p</td>
853 <td>--no-plugins</td>
854 <td>Do not load plugins or plugin support.</td>
855 </tr>
856 <tr><td><em>none</em></td>
857 <td>--print-prefix</td>
858 <td>Print installation prefix, the data directory, the lib
859 directory and the locale directory (in that order) to
860 stdout, one line each. This is mainly intended for plugin
861 authors to detect installation paths.</td>
862 </tr>
863 <tr><td>-r</td>
864 <td>--read-only</td>
865 <td>Open all files given on the command line in read-only mode.
866 This only applies to files opened explicitly from the command
867 line, so files from previous sessions or project files are
868 unaffected.</td>
869 </tr>
870 <tr><td>-s</td>
871 <td>--no-session</td>
872 <td>Do not load the previous session's files.</td>
873 </tr>
874 <tr><td>-t</td>
875 <td>--no-terminal</td>
876 <td>Do not load terminal support. Use this option if you do
877 not want to load the virtual terminal emulator widget
878 at startup. If you do not have <tt class="docutils literal">libvte.so.4</tt> installed,
879 then terminal-support is automatically disabled. Only
880 available if Geany was compiled with support for VTE.</td>
881 </tr>
882 <tr><td><em>none</em></td>
883 <td>--socket-file</td>
884 <td><p class="first">Use this socket filename for communication with a
885 running Geany instance. This can be used with the following
886 command to execute Geany on the current workspace:</p>
887 <pre class="last literal-block">
888 geany --socket-file=/tmp/geany-sock-$(xprop -root _NET_CURRENT_DESKTOP | awk '{print $3}')
889 </pre>
890 </td>
891 </tr>
892 <tr><td><em>none</em></td>
893 <td>--vte-lib</td>
894 <td>Specify explicitly the path including filename or only
895 the filename to the VTE library, e.g.
896 <tt class="docutils literal">/usr/lib/libvte.so</tt> or <tt class="docutils literal">libvte.so</tt>. This option is
897 only needed when the auto-detection does not work. Only
898 available if Geany was compiled with support for VTE.</td>
899 </tr>
900 <tr><td>-v</td>
901 <td>--verbose</td>
902 <td>Be verbose (print useful status messages).</td>
903 </tr>
904 <tr><td>-V</td>
905 <td>--version</td>
906 <td>Show version information and exit.</td>
907 </tr>
908 <tr><td>-?</td>
909 <td>--help</td>
910 <td>Show help information and exit.</td>
911 </tr>
912 <tr><td><em>none</em></td>
913 <td>[files ...]</td>
914 <td><p class="first">Open all given files at startup. This option causes
915 Geany to ignore loading stored files from the last
916 session (if enabled).
917 Geany also recognizes line and column information when
918 appended to the filename with colons, e.g.
919 &quot;geany foo.bar:10:5&quot; will open the file foo.bar and
920 place the cursor in line 10 at column 5.</p>
921 <p class="last">Projects can also be opened but a project file (*.geany)
922 must be the first non-option argument. All additionally
923 given files are ignored.</p>
924 </td>
925 </tr>
926 </tbody>
927 </table>
928 <p>You can also pass line number and column number information, e.g.:</p>
929 <pre class="literal-block">
930 geany some_file.foo:55:4
931 </pre>
932 <p>Geany supports all generic GTK options, a list is available on the
933 help screen.</p>
934 </div>
935 <div class="section" id="general">
936 <h2><a class="toc-backref" href="#id28">General</a></h2>
937 <div class="section" id="startup">
938 <h3><a class="toc-backref" href="#id29">Startup</a></h3>
939 <p>At startup, Geany loads all files from the last time Geany was
940 launched. You can disable this feature in the preferences dialog
941 (see <a class="reference internal" href="#general-startup-preferences">General Startup preferences</a>).</p>
942 <p>You can start several instances of Geany, but only the first will
943 load files from the last session. In the subsequent instances, you
944 can find these files in the file menu under the &quot;Recent files&quot; item.
945 By default this contains the last 10 recently opened files. You can
946 change the number of recently opened files in the preferences dialog.</p>
947 <p>To run a second instance of Geany, do not specify any filenames on
948 the command-line, or disable opening files in a running instance
949 using the appropriate command line option.</p>
950 </div>
951 <div class="section" id="opening-files-from-the-command-line-in-a-running-instance">
952 <h3><a class="toc-backref" href="#id30">Opening files from the command-line in a running instance</a></h3>
953 <p>Geany detects if there is an an instance of itself already running and opens files
954 from the command-line in that instance. So, Geany can
955 be used to view and edit files by opening them from other programs
956 such as a file manager.</p>
957 <p>You can also pass line number and column number information, e.g.:</p>
958 <pre class="literal-block">
959 geany some_file.foo:55:4
960 </pre>
961 <p>This would open the file <tt class="docutils literal">some_file.foo</tt> with the cursor on line 55,
962 column 4.</p>
963 <p>If you do not like this for some reason, you can disable using the first
964 instance by using the appropriate command line option -- see the section
965 called <a class="reference internal" href="#command-line-options">Command line options</a>.</p>
966 </div>
967 <div class="section" id="virtual-terminal-emulator-widget-vte">
968 <h3><a class="toc-backref" href="#id31">Virtual terminal emulator widget (VTE)</a></h3>
969 <p>If you have installed <tt class="docutils literal">libvte.so</tt> on your system, it is loaded
970 automatically by Geany, and you will have a terminal widget in the
971 notebook at the bottom.</p>
972 <p>If Geany cannot find any <tt class="docutils literal">libvte.so</tt> at startup, the terminal widget
973 will not be loaded. So there is no need to install the package containing
974 this file in order to run Geany. Additionally, you can disable the use
975 of the terminal widget by command line option, for more information
976 see the section called <a class="reference internal" href="#command-line-options">Command line options</a>.</p>
977 <p>You can use this terminal (from now on called VTE) much as you would
978 a terminal program like xterm. There is basic clipboard support. You
979 can paste the contents of the clipboard by pressing the right mouse
980 button to open the popup menu, and choosing Paste. To copy text from
981 the VTE, just select the desired text and then press the right mouse
982 button and choose Copy from the popup menu. On systems running the
983 X Window System you can paste the last selected text by pressing the
984 middle mouse button in the VTE (on 2-button mice, the middle button
985 can often be simulated by pressing both mouse buttons together).</p>
986 <p>In the preferences dialog you can specify a shell which should be
987 started in the VTE. To make the specified shell a login shell just
988 use the appropriate command line options for the shell. These options
989 should be found in the manual page of the shell. For zsh and bash
990 you can use the argument <tt class="docutils literal"><span class="pre">--login</span></tt>.</p>
991 <div class="note">
992 <p class="first admonition-title">Note</p>
993 <p class="last">Geany tries to load <tt class="docutils literal">libvte.so</tt>. If this fails, it tries to load
994 some other filenames. If this fails too, you should check whether you
995 installed libvte correctly. Again note, Geany will run without this
996 library.</p>
997 </div>
998 <p>It could be, that the library is called something else than
999 <tt class="docutils literal">libvte.so</tt> (e.g. on FreeBSD 6.0 it is called <tt class="docutils literal">libvte.so.8</tt>). If so
1000 please set a link to the correct file (as root):</p>
1001 <pre class="literal-block">
1002 # ln -s /usr/lib/libvte.so.X /usr/lib/libvte.so
1003 </pre>
1004 <p>Obviously, you have to adjust the paths and set X to the number of your
1005 <tt class="docutils literal">libvte.so</tt>.</p>
1006 <p>You can also specify the filename of the VTE library to use on the command
1007 line (see the section called <a class="reference internal" href="#command-line-options">Command line options</a>) or at compile time
1008 by specifying the command line option <tt class="docutils literal"><span class="pre">--with-vte-module-path</span></tt> to
1009 ./configure.</p>
1010 </div>
1011 <div class="section" id="defining-own-widget-styles-using-gtkrc-2-0">
1012 <h3><a class="toc-backref" href="#id32">Defining own widget styles using .gtkrc-2.0</a></h3>
1013 <p>You can define your widget style for many of Geany's GUI parts. To
1014 do this, just edit your <tt class="docutils literal"><span class="pre">.gtkrc-2.0</span></tt> (usually found in your home
1015 directory on UNIX-like systems and in the etc subdirectory of your
1016 Geany installation on Windows).</p>
1017 <p>To have a defined style used by Geany you must assign it to
1018 at least one of Geany's widgets. For example use the following line:</p>
1019 <pre class="literal-block">
1020 widget &quot;Geany*&quot; style &quot;geanyStyle&quot;
1021 </pre>
1022 <p>This would assign your style &quot;geany_style&quot; to all Geany
1023 widgets. You can also assign styles only to specific widgets. At the
1024 moment you can use the following widgets:</p>
1025 <ul class="simple">
1026 <li>GeanyMainWindow</li>
1027 <li>GeanyEditMenu</li>
1028 <li>GeanyToolbarMenu</li>
1029 <li>GeanyDialog</li>
1030 <li>GeanyDialogPrefs</li>
1031 <li>GeanyDialogProject</li>
1032 <li>GeanyDialogSearch</li>
1033 <li>GeanyMenubar</li>
1034 <li>GeanyToolbar</li>
1035 </ul>
1036 <p>An example of a simple <tt class="docutils literal"><span class="pre">.gtkrc-2.0</span></tt>:</p>
1037 <pre class="literal-block">
1038 style &quot;geanyStyle&quot;
1040 font_name=&quot;Sans 12&quot;
1042 widget &quot;GeanyMainWindow&quot; style &quot;geanyStyle&quot;
1044 style &quot;geanyStyle&quot;
1046 font_name=&quot;Sans 10&quot;
1048 widget &quot;GeanyPrefsDialog&quot; style &quot;geanyStyle&quot;
1049 </pre>
1050 </div>
1051 </div>
1052 <div class="section" id="documents">
1053 <h2><a class="toc-backref" href="#id33">Documents</a></h2>
1054 <div class="section" id="switching-between-documents">
1055 <h3><a class="toc-backref" href="#id34">Switching between documents</a></h3>
1056 <p>The documents list and the editor tabs are two different ways
1057 to switch between documents using the mouse. When you hit the key
1058 combination to move between tabs, the order is determined by the tab
1059 order. It is not alphabetical as shown in the documents list
1060 (regardless of whether or not editor tabs are visible).</p>
1061 <p>See the <a class="reference internal" href="#notebook-tab-keybindings">Notebook tab keybindings</a> section for useful
1062 shortcuts including for Most-Recently-Used document switching.</p>
1063 </div>
1064 <div class="section" id="cloning-documents">
1065 <h3><a class="toc-backref" href="#id35">Cloning documents</a></h3>
1066 <p>The <cite>Document-&gt;Clone</cite> menu item copies the current document's text,
1067 cursor position and properties into a new untitled document. If
1068 there is a selection, only the selected text is copied. This can be
1069 useful when making temporary copies of text or for creating
1070 documents with similar or identical contents.</p>
1071 </div>
1072 </div>
1073 <div class="section" id="character-sets-and-unicode-byte-order-mark-bom">
1074 <h2><a class="toc-backref" href="#id36">Character sets and Unicode Byte-Order-Mark (BOM)</a></h2>
1075 <div class="section" id="using-character-sets">
1076 <h3><a class="toc-backref" href="#id37">Using character sets</a></h3>
1077 <p>Geany provides support for detecting and converting character sets. So
1078 you can open and save files in different character sets, and even
1079 convert a file from one character set to another. To do this,
1080 Geany uses the character conversion capabilities of the GLib library.</p>
1081 <p>Only text files are supported, i.e. opening files which contain
1082 NULL-bytes may fail. Geany will try to open the file anyway but it is
1083 likely that the file will be truncated because it can only be read up
1084 to the first occurrence of a NULL-byte. All characters after this
1085 position are lost and are not written when you save the file.</p>
1086 <p>Geany tries to detect the encoding of a file while opening it, but
1087 auto-detecting the encoding of a file is not easy and sometimes an
1088 encoding might not be detected correctly. In this case you have to
1089 set the encoding of the file manually in order to display it
1090 correctly. You can this in the file open dialog by selecting an
1091 encoding in the drop down box or by reloading the file with the
1092 file menu item &quot;Reload as&quot;. The auto-detection works well for most
1093 encodings but there are also some encodings where it is known that
1094 auto-detection has problems.</p>
1095 <p>There are different ways to set different encodings in Geany:</p>
1096 <ul>
1097 <li><p class="first">Using the file open dialog</p>
1098 <p>This opens the file with the encoding specified in the encoding drop
1099 down box. If the encoding is set to &quot;Detect from file&quot; auto-detection
1100 will be used. If the encoding is set to &quot;Without encoding (None)&quot; the
1101 file will be opened without any character conversion and Geany will
1102 not try to auto-detect the encoding (see below for more information).</p>
1103 </li>
1104 <li><p class="first">Using the &quot;Reload as&quot; menu item</p>
1105 <p>This item reloads the current file with the specified encoding. It can
1106 help if you opened a file and found out that the wrong encoding was used.</p>
1107 </li>
1108 <li><p class="first">Using the &quot;Set encoding&quot; menu item</p>
1109 <p>Contrary to the above two options, this will not change or reload
1110 the current file unless you save it. It is useful when you want to
1111 change the encoding of the file.</p>
1112 </li>
1113 <li><p class="first">Specifying the encoding in the file itself</p>
1114 <p>As mentioned above, auto-detecting the encoding of a file may fail on
1115 some encodings. If you know that Geany doesn't open a certain file,
1116 you can add the specification line, described in the next section,
1117 to the beginning of the file to force Geany to use a specific
1118 encoding when opening the file.</p>
1119 </li>
1120 </ul>
1121 </div>
1122 <div class="section" id="in-file-encoding-specification">
1123 <h3><a class="toc-backref" href="#id38">In-file encoding specification</a></h3>
1124 <p>Geany detects meta tags of HTML files which contain charset information
1125 like:</p>
1126 <pre class="literal-block">
1127 &lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=ISO-8859-15&quot; /&gt;
1128 </pre>
1129 <p>and the specified charset is used when opening the file. This is useful if the
1130 encoding of the file cannot be detected properly.
1131 For non-HTML files you can also define a line like:</p>
1132 <pre class="literal-block">
1133 /* geany_encoding=ISO-8859-15 */
1134 </pre>
1135 <p>or:</p>
1136 <pre class="literal-block">
1137 # geany_encoding=ISO-8859-15 #
1138 </pre>
1139 <p>to force an encoding to be used. The #, /* and */ are examples
1140 of filetype-specific comment characters. It doesn't matter which
1141 characters are around the string &quot; geany_encoding=ISO-8859-15 &quot; as long
1142 as there is at least one whitespace character before and after this
1143 string. Whitespace characters are in this case a space or tab character.
1144 An example to use this could be you have a file with ISO-8859-15
1145 encoding but Geany constantly detects the file encoding as ISO-8859-1.
1146 Then you simply add such a line to the file and Geany will open it
1147 correctly the next time.</p>
1148 <p>Since Geany 0.15 you can also use lines which match the
1149 regular expression used to find the encoding string:
1150 <tt class="docutils literal"><span class="pre">coding[\t</span> <span class="pre">]*[:=][\t</span> <span class="pre">]*([a-z0-9-]+)[\t</span> ]*</tt></p>
1151 <div class="note">
1152 <p class="first admonition-title">Note</p>
1153 <p class="last">These specifications must be in the first 512 bytes of the file.
1154 Anything after the first 512 bytes will not be recognized.</p>
1155 </div>
1156 <p>Some examples are:</p>
1157 <pre class="literal-block">
1158 # encoding = ISO-8859-15
1159 </pre>
1160 <p>or:</p>
1161 <pre class="literal-block">
1162 # coding: ISO-8859-15
1163 </pre>
1164 </div>
1165 <div class="section" id="special-encoding-none">
1166 <h3><a class="toc-backref" href="#id39">Special encoding &quot;None&quot;</a></h3>
1167 <p>There is a special encoding &quot;None&quot; which uses no
1168 encoding. It is useful when you know that Geany cannot auto-detect
1169 the encoding of a file and it is not displayed correctly. Especially
1170 when the file contains NULL-bytes this can be useful to skip auto
1171 detection and open the file properly at least until the occurrence
1172 of the first NULL-byte. Using this encoding opens the file as it is
1173 without any character conversion.</p>
1174 </div>
1175 <div class="section" id="unicode-byte-order-mark-bom">
1176 <h3><a class="toc-backref" href="#id40">Unicode Byte-Order-Mark (BOM)</a></h3>
1177 <p>Furthermore, Geany detects a Unicode Byte Order Mark (see
1178 <a class="reference external" href="http://en.wikipedia.org/wiki/Byte_Order_Mark">http://en.wikipedia.org/wiki/Byte_Order_Mark</a> for details). Of course,
1179 this feature is only available if the opened file is in a Unicode
1180 encoding. The Byte Order Mark helps to detect the encoding of a file,
1181 e.g. whether it is UTF-16LE or UTF-16BE and so on. On Unix-like systems
1182 using a Byte Order Mark could cause some problems for programs not
1183 expecting it, e.g. the compiler gcc stops
1184 with stray errors, PHP does not parse a script containing a BOM and
1185 script files starting with a she-bang maybe cannot be started. In the
1186 status bar you can easily see whether the file starts with a BOM or
1187 not.</p>
1188 <p>If you want to set a BOM for a file or if you want to remove it
1189 from a file, just use the document menu and toggle the checkbox.</p>
1190 <div class="note">
1191 <p class="first admonition-title">Note</p>
1192 <p class="last">If you are unsure what a BOM is or if you do not understand where
1193 to use it, then it is probably not important for you and you can
1194 safely ignore it.</p>
1195 </div>
1196 </div>
1197 </div>
1198 <div class="section" id="editing">
1199 <h2><a class="toc-backref" href="#id41">Editing</a></h2>
1200 <div class="section" id="folding">
1201 <h3><a class="toc-backref" href="#id42">Folding</a></h3>
1202 <p>Geany provides basic code folding support. Folding means the ability to
1203 show and hide parts of the text in the current file. You can hide
1204 unimportant code sections and concentrate on the parts you are working on
1205 and later you can show hidden sections again. In the editor window there is
1206 a small grey margin on the left side with [+] and [-] symbols which
1207 show hidden parts and hide parts of the file respectively. By
1208 clicking on these icons you can simply show and hide sections which are
1209 marked by vertical lines within this margin. For many filetypes nested
1210 folding is supported, so there may be several fold points within other
1211 fold points.</p>
1212 <div class="note">
1213 <p class="first admonition-title">Note</p>
1214 <p class="last">You can customize the folding icon and line styles - see the
1215 filetypes.common <a class="reference internal" href="#folding-settings">Folding Settings</a>.</p>
1216 </div>
1217 <p>If you don't like it or don't need it at all, you can simply disable
1218 folding support completely in the preferences dialog.</p>
1219 <p>The folding behaviour can be changed with the &quot;Fold/Unfold all children of
1220 a fold point&quot; option in the preference dialog. If activated, Geany will
1221 unfold all nested fold points below the current one if they are already
1222 folded (when clicking on a [+] symbol).
1223 When clicking on a [-] symbol, Geany will fold all nested fold points
1224 below the current one if they are unfolded.</p>
1225 <p>This option can be inverted by pressing the Shift
1226 key while clicking on a fold symbol. That means, if the &quot;Fold/Unfold all
1227 children of a fold point&quot; option is enabled, pressing Shift will disable
1228 it for this click and vice versa.</p>
1229 </div>
1230 <div class="section" id="column-mode-editing-rectangular-selections">
1231 <h3><a class="toc-backref" href="#id43">Column mode editing (rectangular selections)</a></h3>
1232 <p>There is basic support for column mode editing. To use it, create a
1233 rectangular selection by holding down the Control and Shift keys
1234 (or Alt and Shift on Windows) while selecting some text.
1235 Once a rectangular selection exists you can start editing the text within
1236 this selection and the modifications will be done for every line in the
1237 selection.</p>
1238 <p>It is also possible to create a zero-column selection - this is
1239 useful to insert text on multiple lines.</p>
1240 </div>
1241 <div class="section" id="drag-and-drop-of-text">
1242 <h3><a class="toc-backref" href="#id44">Drag and drop of text</a></h3>
1243 <p>If you drag selected text in the editor widget of Geany the text is
1244 moved to the position where the mouse pointer is when releasing the
1245 mouse button. Holding Control when releasing the mouse button will
1246 copy the text instead. This behaviour was changed in Geany 0.11 -
1247 before the selected text was copied to the new position.</p>
1248 </div>
1249 <div class="section" id="indentation">
1250 <h3><a class="toc-backref" href="#id45">Indentation</a></h3>
1251 <p>Geany allows each document to indent either with a tab character,
1252 multiple spaces or a combination of both. The default indent
1253 settings are set in <a class="reference internal" href="#editor-indentation-preferences">Editor Indentation preferences</a> (see the link
1254 for more information).</p>
1255 <p>The default settings can be overridden per-document using the
1256 Document menu. They can also be overridden by projects - see
1257 <a class="reference internal" href="#project-management">Project management</a>.</p>
1258 <p>The indent mode for the current document is shown on the status bar
1259 as follows:</p>
1260 <dl class="docutils">
1261 <dt>TAB</dt>
1262 <dd>Indent with Tab characters.</dd>
1263 <dt>SP</dt>
1264 <dd>Indent with spaces.</dd>
1265 <dt>T/S</dt>
1266 <dd>Indent with tabs and spaces, depending on how much indentation is
1267 on a line.</dd>
1268 </dl>
1269 <div class="section" id="applying-new-indentation-settings">
1270 <h4><a class="toc-backref" href="#id46">Applying new indentation settings</a></h4>
1271 <p>After changing the default settings you may wish to apply the new
1272 settings to every document in the current session. To do this use the
1273 <em>Project-&gt;Apply Default Indentation</em> menu item.</p>
1274 </div>
1275 <div class="section" id="detecting-indent-type">
1276 <h4><a class="toc-backref" href="#id47">Detecting indent type</a></h4>
1277 <p>The <em>Detect from file</em> indentation preference can be used to
1278 scan each file as it's opened and set the indent type based on
1279 how many lines start with a tab vs. 2 or more spaces.</p>
1280 </div>
1281 </div>
1282 <div class="section" id="auto-indentation">
1283 <h3><a class="toc-backref" href="#id48">Auto-indentation</a></h3>
1284 <p>When enabled, auto-indentation happens when pressing <em>Enter</em> in the
1285 Editor. It adds a certain amount of indentation to the new line so the
1286 user doesn't always have to indent each line manually.</p>
1287 <p>Geany has four types of auto-indentation:</p>
1288 <dl class="docutils">
1289 <dt>None</dt>
1290 <dd>Disables auto-indentation completely.</dd>
1291 <dt>Basic</dt>
1292 <dd>Adds the same amount of whitespace on a new line as on the last line.</dd>
1293 <dt>Current chars</dt>
1294 <dd>Does the same as <em>Basic</em> but also indents a new line after an opening
1295 brace '{', and de-indents when typing a closing brace '}'. For Python,
1296 a new line will be indented after typing ':' at the end of the
1297 previous line.</dd>
1298 <dt>Match braces</dt>
1299 <dd>Similar to <em>Current chars</em> but the closing brace will be aligned to
1300 match the indentation of the line with the opening brace.</dd>
1301 </dl>
1302 <p>There is also XML-tag auto-indentation. This is enabled when the
1303 mode is more than just Basic, and is also controlled by a filetype
1304 setting - see <a class="reference internal" href="#xml-indent-tags">xml_indent_tags</a>.</p>
1305 </div>
1306 <div class="section" id="bookmarks">
1307 <h3><a class="toc-backref" href="#id49">Bookmarks</a></h3>
1308 <p>Geany provides a handy bookmarking feature that lets you mark one
1309 or more lines in a document, and return the cursor to them using a
1310 key combination.</p>
1311 <p>To place a mark on a line, either left-mouse-click in the left margin
1312 of the editor window, or else use Ctrl-m. This will
1313 produce a small green plus symbol in the margin. You can have as many
1314 marks in a document as you like. Click again (or use Ctrl-m again)
1315 to remove the bookmark. To remove all the marks in a given document,
1316 use &quot;Remove Markers&quot; in the Document menu.</p>
1317 <p>To navigate down your document, jumping from one mark to the next,
1318 use Ctrl-. (control period). To go in the opposite direction on
1319 the page, use Ctrl-, (control comma). Using the bookmarking feature
1320 together with the commands to switch from one editor tab to another
1321 (Ctrl-PgUp/PgDn and Ctrl-Tab) provides a particularly fast way to
1322 navigate around multiple files.</p>
1323 </div>
1324 <div class="section" id="code-navigation-history">
1325 <h3><a class="toc-backref" href="#id50">Code navigation history</a></h3>
1326 <p>To ease navigation in source files and especially between
1327 different files, Geany lets you jump between different navigation
1328 points. Currently, this works for the following:</p>
1329 <ul class="simple">
1330 <li><a class="reference internal" href="#go-to-tag-declaration">Go to tag declaration</a></li>
1331 <li><a class="reference internal" href="#go-to-tag-definition">Go to tag definition</a></li>
1332 <li>Symbol list items</li>
1333 <li>Build errors</li>
1334 <li>Message items</li>
1335 </ul>
1336 <p>When using one of these actions, Geany remembers your current position
1337 and jumps to the new one. If you decide to go back to your previous
1338 position in the file, just use &quot;Navigate back a location&quot;. To
1339 get back to the new position again, just use &quot;Navigate forward a
1340 location&quot;. This makes it easier to navigate in e.g. foreign code
1341 and between different files.</p>
1342 </div>
1343 <div class="section" id="sending-text-through-custom-commands">
1344 <h3><a class="toc-backref" href="#id51">Sending text through custom commands</a></h3>
1345 <p>You can define several custom commands in Geany and send the current
1346 selection to one of these commands using the <em>Edit-&gt;Format-&gt;Send
1347 Selection to</em> menu or keybindings. The output of the command will be
1348 used to replace the current selection. This makes it possible to use
1349 text formatting tools with Geany in a general way.</p>
1350 <p>The selected text will be sent to the standard input of the executed
1351 command, so the command should be able to read from it and it should
1352 print all results to its standard output which will be read by
1353 Geany. To help finding errors in executing the command, the output
1354 of the program's standard error will be printed on Geany's standard
1355 output.</p>
1356 <p>If there is no selection, the whole current line is used instead.</p>
1357 <p>To add a custom command, use the <em>Send Selection to-&gt;Set Custom
1358 Commands</em> menu item. Click on <em>Add</em> to get a new item and type the
1359 command. You can also specify some command line options. Empty
1360 commands are not saved.</p>
1361 <p>Normal shell quoting is supported, so you can do things like:</p>
1362 <ul class="simple">
1363 <li><tt class="docutils literal">sed <span class="pre">'s/\./(dot)/g'</span></tt></li>
1364 </ul>
1365 <p>The above example would normally be done with the <a class="reference internal" href="#replace-all">Replace all</a>
1366 function, but it can be handy to have common commands already set up.</p>
1367 </div>
1368 <div class="section" id="context-actions">
1369 <h3><a class="toc-backref" href="#id52">Context actions</a></h3>
1370 <p>You can execute the context action command on the current word at the
1371 cursor position or the available selection. This word or selection
1372 can be used as an argument to the command.
1373 The context action is invoked by a menu entry in the popup menu of the
1374 editor and also a keyboard shortcut (see the section called
1375 <a class="reference internal" href="#keybindings">Keybindings</a>).</p>
1376 <p>The command can be specified in the preferences dialog and also for
1377 each filetype (see &quot;context_action_cmd&quot; in the section called
1378 <a class="reference internal" href="#filetype-configuration">Filetype configuration</a>). When the context action is invoked, the filetype
1379 specific command is used if available, otherwise the command
1380 specified in the preferences dialog is executed.</p>
1381 <p>The current word or selection can be referred with the wildcard &quot;%s&quot;
1382 in the command, it will be replaced by the current word or
1383 selection before the command is executed.</p>
1384 <p>For example a context action can be used to open API documentation
1385 in a browser window, the command to open the PHP API documentation
1386 would be:</p>
1387 <pre class="literal-block">
1388 firefox &quot;http://www.php.net/%s&quot;
1389 </pre>
1390 <p>when executing the command, the %s is substituted by the word near
1391 the cursor position or by the current selection. If the cursor is at
1392 the word &quot;echo&quot;, a browser window will open(assumed your browser is
1393 called firefox) and it will open the address: <a class="reference external" href="http://www.php.net/echo">http://www.php.net/echo</a>.</p>
1394 </div>
1395 <div class="section" id="autocompletion">
1396 <h3><a class="toc-backref" href="#id53">Autocompletion</a></h3>
1397 <p>Geany can offer a list of possible completions for symbols defined in the
1398 tags and for all words in a document.</p>
1399 <p>The autocompletion list for symbols is presented when the first few
1400 characters of the symbol are typed (configurable, see <a class="reference internal" href="#editor-completions-preferences">Editor Completions
1401 preferences</a>, default 4) or when the <em>Complete word</em>
1402 keybinding is pressed (configurable, see <a class="reference internal" href="#editor-keybindings">Editor keybindings</a>,
1403 default Ctrl-Space).</p>
1404 <p>When the defined keybinding is typed and the <em>Autocomplete all words in
1405 document</em> preference (in <a class="reference internal" href="#editor-completions-preferences">Editor Completions preferences</a>)
1406 is selected then the autocompletion list will show all matching words
1407 in the document, if there are no matching symbols.</p>
1408 <p>If you don't want to use autocompletion it can be dismissed until
1409 the next symbol by pressing Escape. The autocompletion list is updated
1410 as more characters are typed so that it only shows completions that start
1411 with the characters typed so far. If no symbols begin with the sequence,
1412 the autocompletion window is closed.</p>
1413 <p>The up and down arrows will move the selected item. The highlighted
1414 item on the autocompletion list can be chosen from the list by pressing
1415 Enter/Return. You can also double-click to select an item. The sequence
1416 will be completed to match the chosen item, and if the <em>Drop rest of
1417 word on completion</em> preference is set (in <a class="reference internal" href="#editor-completions-preferences">Editor Completions
1418 preferences</a>) then any characters after the cursor that match
1419 a symbol or word are deleted.</p>
1420 <div class="section" id="word-part-completion">
1421 <h4><a class="toc-backref" href="#id54">Word part completion</a></h4>
1422 <p>By default, pressing Tab will complete the selected item by word part;
1423 useful e.g. for adding the prefix <tt class="docutils literal">gtk_combo_box_entry_</tt> without typing it
1424 manually:</p>
1425 <ul class="simple">
1426 <li>gtk_com&lt;TAB&gt;</li>
1427 <li>gtk_combo_&lt;TAB&gt;</li>
1428 <li>gtk_combo_box_&lt;e&gt;&lt;TAB&gt;</li>
1429 <li>gtk_combo_box_entry_&lt;s&gt;&lt;ENTER&gt;</li>
1430 <li>gtk_combo_box_entry_set_text_column</li>
1431 </ul>
1432 <p>The key combination can be changed from Tab - See <a class="reference internal" href="#editor-keybindings">Editor keybindings</a>.
1433 If you clear/change the key combination for word part completion, Tab
1434 will complete the whole word instead, like Enter.</p>
1435 </div>
1436 <div class="section" id="scope-autocompletion">
1437 <h4><a class="toc-backref" href="#id55">Scope autocompletion</a></h4>
1438 <p>E.g.:</p>
1439 <pre class="literal-block">
1440 struct
1442 int i;
1443 char c;
1444 } foo;
1445 </pre>
1446 <p>When you type <tt class="docutils literal">foo.</tt> it will show an autocompletion list with 'i' and
1447 'c' symbols.</p>
1448 <p>It only works for languages that set parent scope names for e.g. struct
1449 members. Currently this means C-like languages. The C tag parser only
1450 parses global scopes, so this won't work for structs or objects declared
1451 in local scope.</p>
1452 </div>
1453 </div>
1454 <div class="section" id="user-definable-snippets">
1455 <h3><a class="toc-backref" href="#id56">User-definable snippets</a></h3>
1456 <p>Snippets are small strings or code constructs which can be replaced or
1457 completed to a more complex string. So you can save a lot of time when
1458 typing common strings and letting Geany do the work for you.
1459 To know what to complete or replace Geany reads a configuration file
1460 called <tt class="docutils literal">snippets.conf</tt> at startup.</p>
1461 <p>Maybe you need to often type your name, so define a snippet like this:</p>
1462 <pre class="literal-block">
1463 [Default]
1464 myname=Enrico Tröger
1465 </pre>
1466 <p>Every time you write <tt class="docutils literal">myname</tt> &lt;TAB&gt; in Geany, it will replace &quot;myname&quot;
1467 with &quot;Enrico Tröger&quot;. The key to start autocompletion can be changed
1468 in the preferences dialog, by default it is TAB. The corresponding keybinding
1469 is called <cite>Complete snippet</cite>.</p>
1470 <p><strong>Paths</strong></p>
1471 <p>You can override the default snippets using the user
1472 <tt class="docutils literal">snippets.conf</tt> file. Use the <em>Tools-&gt;Configuration
1473 Files-&gt;snippets.conf</em> menu item. See also <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>.</p>
1474 <p>This adds the default settings to the user file if the file doesn't
1475 exist. Alternatively the file can be created manually, adding only
1476 the settings you want to change. All missing settings will be read
1477 from the system snippets file.</p>
1478 <p><strong>Snippet groups</strong></p>
1479 <p>The file <tt class="docutils literal">snippets.conf</tt> contains sections defining snippets that
1480 are available for particular filetypes and in general.</p>
1481 <p>The two sections &quot;Default&quot; and &quot;Special&quot; apply to all filetypes.
1482 &quot;Default&quot; contains all snippets which are available for every
1483 filetype and &quot;Special&quot; contains snippets which can only be used in
1484 other snippets. So you can define often used parts of snippets and
1485 just use the special snippet as a placeholder (see the
1486 <tt class="docutils literal">snippets.conf</tt> for details).</p>
1487 <p>You can define sections with the name of a filetype eg &quot;C++&quot;. The
1488 snippets in that section are only available for use in files with that
1489 filetype. Snippets in filetype sections will hide snippets with the
1490 same name in the &quot;Default&quot; section when used in a file of that
1491 filetype.</p>
1492 <p><strong>Substitution sequences for snippets</strong></p>
1493 <p>To define snippets you can use several special character sequences which
1494 will be replaced when using the snippet:</p>
1495 <table border="1" class="docutils">
1496 <colgroup>
1497 <col width="22%" />
1498 <col width="78%" />
1499 </colgroup>
1500 <tbody valign="top">
1501 <tr><td>\n or %newline%</td>
1502 <td>Insert a new line (it will be replaced by the used EOL
1503 char(s): LF, CR/LF, or CR).</td>
1504 </tr>
1505 <tr><td>\t or %ws%</td>
1506 <td>Insert an indentation step, it will be replaced according
1507 to the current document's indent mode.</td>
1508 </tr>
1509 <tr><td>\s</td>
1510 <td>\s to force whitespace at beginning or end of a value
1511 ('key= value' won't work, use 'key=\svalue')</td>
1512 </tr>
1513 <tr><td>%cursor%</td>
1514 <td>Place the cursor at this position after completion has
1515 been done. You can define multiple %cursor% wildcards
1516 and use the keybinding <cite>Move cursor in snippet</cite> to jump
1517 to the next defined cursor position in the completed
1518 snippet.</td>
1519 </tr>
1520 <tr><td>%...%</td>
1521 <td>&quot;...&quot; means the name of a key in the &quot;Special&quot; section.
1522 If you have defined a key &quot;brace_open&quot; in the &quot;Special&quot;
1523 section you can use %brace_open% in any other snippet.</td>
1524 </tr>
1525 </tbody>
1526 </table>
1527 <p>Snippet names must not contain spaces otherwise they won't
1528 work correctly. But beside that you can define almost any
1529 string as a snippet and use it later in Geany. It is not limited
1530 to existing contructs of certain programming languages(like <tt class="docutils literal">if</tt>,
1531 <tt class="docutils literal">for</tt>, <tt class="docutils literal">switch</tt>). Define whatever you need.</p>
1532 <p><strong>Template wildcards</strong></p>
1533 <p>Since Geany 0.15 you can also use most of the available templates wildcards
1534 listed in <a class="reference internal" href="#template-wildcards">Template wildcards</a>. All wildcards which are listed as
1535 <cite>available in snippets</cite> can be used. For instance to improve the above example:</p>
1536 <pre class="literal-block">
1537 [Default]
1538 myname=My name is {developer}
1539 mysystem=My system: {command:uname -a}
1540 </pre>
1541 <p>this will replace <tt class="docutils literal">myname</tt> with &quot;My name is &quot; and the value of the template
1542 preference <tt class="docutils literal">developer</tt>.</p>
1543 <p><strong>Word characters</strong></p>
1544 <p>You can change the way Geany recognizes the word to complete,
1545 that is how the start and end of a word is recognised when the
1546 snippet completion is requested. The section &quot;Special&quot; may
1547 contain a key &quot;wordchars&quot; which lists all characters a string may contain
1548 to be recognized as a word for completion. Leave it commented to use
1549 default characters or define it to add or remove characters to fit your
1550 needs.</p>
1551 <div class="section" id="snippet-keybindings">
1552 <h4><a class="toc-backref" href="#id57">Snippet keybindings</a></h4>
1553 <p>Normally you would type the snippet name and press Tab. However, you
1554 can define keybindings for snippets under the <em>Keybindings</em> group in
1555 <tt class="docutils literal">snippets.conf</tt>:</p>
1556 <pre class="literal-block">
1557 [Keybindings]
1558 for=&lt;Ctrl&gt;7
1559 block_cursor=&lt;Ctrl&gt;8
1560 </pre>
1561 <div class="note">
1562 <p class="first admonition-title">Note</p>
1563 <p class="last">Snippet keybindings may be overridden by Geany's configurable
1564 keybindings.</p>
1565 </div>
1566 </div>
1567 </div>
1568 <div class="section" id="inserting-unicode-characters">
1569 <h3><a class="toc-backref" href="#id58">Inserting Unicode characters</a></h3>
1570 <p>You can insert Unicode code points by hitting Ctrl-Shift-u, then still holding
1571 Ctrl-Shift, type some hex digits representing the code point for the character
1572 you want and hit Enter or Return (still holding Ctrl-Shift). If you release
1573 Ctrl-Shift before hitting Enter or Return (or any other character), the code
1574 insertion is completed, but the typed character is also entered. In the case
1575 of Enter/Return, it is a newline, as you might expect.</p>
1576 <p>In some earlier versions of Geany, you might need to first unbind Ctrl-Shift-u
1577 in the <a class="reference internal" href="#keybinding-preferences">keybinding preferences</a>, then select <em>Tools-&gt;Reload Configuration</em>
1578 or restart Geany. Note that it works slightly differently from other GTK
1579 applications, in that you'll need to continue to hold down the Ctrl and Shift
1580 keys while typing the code point hex digits (and the Enter or Return to finish the code point).</p>
1581 </div>
1582 </div>
1583 <div class="section" id="search-replace-and-go-to">
1584 <h2><a class="toc-backref" href="#id59">Search, replace and go to</a></h2>
1585 <p>This section describes search-related commands from the Search menu
1586 and the editor window's popup menu:</p>
1587 <ul class="simple">
1588 <li>Find</li>
1589 <li>Find selection</li>
1590 <li>Find usage</li>
1591 <li>Find in files</li>
1592 <li>Replace</li>
1593 <li>Go to tag definition</li>
1594 <li>Go to tag declaration</li>
1595 <li>Go to line</li>
1596 </ul>
1597 <p>See also <a class="reference internal" href="#search">Search</a> preferences.</p>
1598 <div class="section" id="toolbar-entries">
1599 <h3><a class="toc-backref" href="#id60">Toolbar entries</a></h3>
1600 <p>There are also two toolbar entries:</p>
1601 <ul class="simple">
1602 <li>Search bar</li>
1603 <li>Go to line entry</li>
1604 </ul>
1605 <p>There are keybindings to focus each of these - see <a class="reference internal" href="#focus-keybindings">Focus
1606 keybindings</a>. Pressing Escape will then focus the editor.</p>
1607 <div class="section" id="search-bar">
1608 <h4><a class="toc-backref" href="#id61">Search bar</a></h4>
1609 <p>The quickest way to find some text is to use the search bar entry in
1610 the toolbar. This performs a case-insensitive search in the current
1611 document whilst you type. Pressing Enter will search again, and pressing
1612 Shift-Enter will search backwards.</p>
1613 </div>
1614 </div>
1615 <div class="section" id="find">
1616 <h3><a class="toc-backref" href="#id62">Find</a></h3>
1617 <p>The Find dialog is used for finding text in one or more open documents.</p>
1618 <img alt="./images/find_dialog.png" src="./images/find_dialog.png" />
1619 <div class="section" id="matching-options">
1620 <h4><a class="toc-backref" href="#id63">Matching options</a></h4>
1621 <p>The syntax for the <em>Use regular expressions</em> option is shown in
1622 <a class="reference internal" href="#regular-expressions">Regular expressions</a>.</p>
1623 <div class="note">
1624 <p class="first admonition-title">Note</p>
1625 <p class="last"><em>Use escape sequences</em> is implied for regular expressions.</p>
1626 </div>
1627 <p>The <em>Use escape sequences</em> option will transform any escaped characters
1628 into their UTF-8 equivalent. For example, \t will be transformed into
1629 a tab character. Other recognized symbols are: \\, \n, \r, \uXXXX
1630 (Unicode characters).</p>
1631 </div>
1632 <div class="section" id="find-all">
1633 <h4><a class="toc-backref" href="#id64">Find all</a></h4>
1634 <p>To find all matches, click on the Find All expander. This will reveal
1635 several options:</p>
1636 <ul class="simple">
1637 <li>In Document</li>
1638 <li>In Session</li>
1639 <li>Mark</li>
1640 </ul>
1641 <p>Find All In Document will show a list of matching lines in the
1642 current document in the Messages tab of the Message Window. <em>Find All
1643 In Session</em> does the same for all open documents.</p>
1644 <p>Mark will highlight all matches in the current document with a
1645 colored box. These markers can be removed by selecting the
1646 Remove Markers command from the Document menu.</p>
1647 </div>
1648 <div class="section" id="change-font-in-search-dialog-text-fields">
1649 <h4><a class="toc-backref" href="#id65">Change font in search dialog text fields</a></h4>
1650 <p>All search related dialogs use a Monospace for the text input fields to
1651 increase the readability of input text. This is useful when you are
1652 typing input such as regular expressions with spaces, periods and commas which
1653 might it hard to read with a proportional font.</p>
1654 <p>If you want to change the font, you can do this easily
1655 by inserting the following style into your <tt class="docutils literal"><span class="pre">.gtkrc-2.0</span></tt>
1656 (usually found in your home directory on UNIX-like systems and in the
1657 etc subdirectory of your Geany installation on Windows):</p>
1658 <pre class="literal-block">
1659 style &quot;search_style&quot;
1661 font_name=&quot;Monospace 8&quot;
1663 widget &quot;GeanyDialogSearch.*.GtkEntry&quot; style:highest &quot;search_style&quot;
1664 </pre>
1665 <p>Please note the addition of &quot;:highest&quot; in the last line which sets the priority
1666 of this style to the highest available. Otherwise, the style is ignored
1667 for the search dialogs.</p>
1668 </div>
1669 </div>
1670 <div class="section" id="find-selection">
1671 <h3><a class="toc-backref" href="#id66">Find selection</a></h3>
1672 <p>The <em>Find Next/Previous Selection</em> commands perform a search for the
1673 current selected text. If nothing is selected, by default the current
1674 word is used instead. This can be customized by the
1675 <em>find_selection_type</em> preference - see <a class="reference internal" href="#various-preferences">Various preferences</a>.</p>
1676 <table border="1" class="docutils">
1677 <colgroup>
1678 <col width="10%" />
1679 <col width="90%" />
1680 </colgroup>
1681 <thead valign="bottom">
1682 <tr><th class="head">Value</th>
1683 <th class="head"><em>find_selection_type</em> behaviour</th>
1684 </tr>
1685 </thead>
1686 <tbody valign="top">
1687 <tr><td>0</td>
1688 <td>Use the current word (default).</td>
1689 </tr>
1690 <tr><td>1</td>
1691 <td>Try the X selection first, then current word.</td>
1692 </tr>
1693 <tr><td>2</td>
1694 <td>Repeat last search.</td>
1695 </tr>
1696 </tbody>
1697 </table>
1698 </div>
1699 <div class="section" id="find-usage">
1700 <h3><a class="toc-backref" href="#id67">Find usage</a></h3>
1701 <p>Find usage searches all open files. It is similar to the Find All In
1702 Session option in the Find dialog.</p>
1703 <p>If there is a selection, then it is used as the search text; otherwise
1704 the current word is used. The current word is either taken from the
1705 word nearest the edit cursor, or the word underneath the popup menu
1706 click position when the popup menu is used. The search results are
1707 shown in the Messages tab of the Message Window.</p>
1708 </div>
1709 <div class="section" id="find-in-files">
1710 <h3><a class="toc-backref" href="#id68">Find in files</a></h3>
1711 <p>Find in files is a more powerful version of Find usage that searches
1712 all files in a certain directory using the Grep tool. The Grep tool
1713 must be correctly set in Preferences to the path of the system's Grep
1714 utility. GNU Grep is recommended (see note below).</p>
1715 <img alt="./images/find_in_files_dialog.png" src="./images/find_in_files_dialog.png" />
1716 <p>The <em>Search</em> field is initially set to the current word in the editor
1717 (depending on <a class="reference internal" href="#search">Search</a> preferences).</p>
1718 <p>The <em>Files</em> setting allows to choose which files are included in the
1719 search, depending on the mode:</p>
1720 <dl class="docutils">
1721 <dt>All</dt>
1722 <dd>Search in all files;</dd>
1723 <dt>Project</dt>
1724 <dd>Use the current project's patterns, see <a class="reference internal" href="#project-properties">Project properties</a>;</dd>
1725 <dt>Custom</dt>
1726 <dd>Use custom patterns.</dd>
1727 </dl>
1728 <p>Both project and custom patterns use a glob-style syntax, each
1729 pattern separated by a space. To search all <tt class="docutils literal">.c</tt> and <tt class="docutils literal">.h</tt> files,
1730 use: <tt class="docutils literal">*.c *.h</tt>.
1731 Note that an empty pattern list searches in all files rather
1732 than none.</p>
1733 <p>The <em>Directory</em> field is initially set to the current document's directory,
1734 unless this field has already been edited and the current document has
1735 not changed. Otherwise, the current document's directory is prepended to
1736 the drop-down history. This can be disabled - see <a class="reference internal" href="#search">Search</a> preferences.</p>
1737 <p>The <em>Encoding</em> field can be used to define the encoding of the files
1738 to be searched. The entered search text is converted to the chosen encoding
1739 and the search results are converted back to UTF-8.</p>
1740 <p>The <em>Extra options</em> field is used to pass any additional arguments to
1741 the grep tool.</p>
1742 <div class="note">
1743 <p class="first admonition-title">Note</p>
1744 <p class="last">The <em>Files</em> setting uses <tt class="docutils literal"><span class="pre">--include=</span></tt> when searching recursively,
1745 <em>Recurse in subfolders</em> uses <tt class="docutils literal"><span class="pre">-r</span></tt>; both are GNU Grep options and may
1746 not work with other Grep implementations.</p>
1747 </div>
1748 <div class="section" id="filtering-out-version-control-files">
1749 <h4><a class="toc-backref" href="#id69">Filtering out version control files</a></h4>
1750 <p>When using the <em>Recurse in subfolders</em> option with a directory that's
1751 under version control, you can set the <em>Extra options</em> field to filter
1752 out version control files.</p>
1753 <p>If you have GNU Grep &gt;= 2.5.2 you can use the <tt class="docutils literal"><span class="pre">--exclude-dir</span></tt>
1754 argument to filter out CVS and hidden directories like <tt class="docutils literal">.svn</tt>.</p>
1755 <p>Example: <tt class="docutils literal"><span class="pre">--exclude-dir=.svn</span> <span class="pre">--exclude-dir=CVS</span></tt></p>
1756 <p>If you have an older Grep, you can try using the <tt class="docutils literal"><span class="pre">--exclude</span></tt> flag
1757 to filter out filenames.</p>
1758 <p>SVN Example: <tt class="docutils literal"><span class="pre">--exclude=*.svn-base</span></tt></p>
1759 <p>The --exclude argument only matches the file name part, not the path.</p>
1760 </div>
1761 </div>
1762 <div class="section" id="replace">
1763 <h3><a class="toc-backref" href="#id70">Replace</a></h3>
1764 <p>The Replace dialog is used for replacing text in one or more open
1765 documents.</p>
1766 <img alt="./images/replace_dialog.png" src="./images/replace_dialog.png" />
1767 <p>The Replace dialog has the same options for matching text as the Find
1768 dialog. See the section <a class="reference internal" href="#matching-options">Matching options</a>.</p>
1769 <p>The <em>Use regular expressions</em> option allows regular expressions to
1770 be used in the search string and back references in the replacement
1771 text -- see the entry for '\n' in <a class="reference internal" href="#regular-expressions">Regular expressions</a>.</p>
1772 <div class="section" id="replace-all">
1773 <h4><a class="toc-backref" href="#id71">Replace all</a></h4>
1774 <p>To replace several matches, click on the <em>Replace All</em> expander. This
1775 will reveal several options:</p>
1776 <ul class="simple">
1777 <li>In Document</li>
1778 <li>In Session</li>
1779 <li>In Selection</li>
1780 </ul>
1781 <p><em>Replace All In Document</em> will replace all matching text in the
1782 current document. <em>Replace All In Session</em> does the same for all open
1783 documents. <em>Replace All In Selection</em> will replace all matching text
1784 in the current selection of the current document.</p>
1785 </div>
1786 </div>
1787 <div class="section" id="go-to-tag-definition">
1788 <h3><a class="toc-backref" href="#id72">Go to tag definition</a></h3>
1789 <p>If the current word or selection is the name of a tag definition
1790 (e.g. a function name) and the file containing the tag definition is
1791 open, this command will switch to that file and go to the
1792 corresponding line number. The current word is either the word
1793 nearest the edit cursor, or the word underneath the popup menu click
1794 position when the popup menu is used.</p>
1795 <div class="note">
1796 <p class="first admonition-title">Note</p>
1797 <p class="last">If the corresponding tag is on the current line, Geany will first
1798 look for a tag declaration instead, as this is more useful.
1799 Likewise <em>Go to tag declaration</em> will search for a tag definition
1800 first in this case also.</p>
1801 </div>
1802 </div>
1803 <div class="section" id="go-to-tag-declaration">
1804 <h3><a class="toc-backref" href="#id73">Go to tag declaration</a></h3>
1805 <p>Like <em>Go to tag definition</em>, but for a forward declaration such as a
1806 C function prototype or <tt class="docutils literal">extern</tt> declaration instead of a function
1807 body.</p>
1808 </div>
1809 <div class="section" id="go-to-line">
1810 <h3><a class="toc-backref" href="#id74">Go to line</a></h3>
1811 <p>Go to a particular line number in the current file.</p>
1812 </div>
1813 <div class="section" id="regular-expressions">
1814 <h3><a class="toc-backref" href="#id75">Regular expressions</a></h3>
1815 <p>You can use regular expressions in the Find and Replace dialogs
1816 by selecting the <em>Use regular expressions</em> check box (see <a class="reference internal" href="#matching-options">Matching
1817 options</a>). The syntax is Perl compatible. Basic syntax is described
1818 in the table below. For full details, see
1819 <a class="reference external" href="http://www.geany.org/manual/gtk/glib/glib-regex-syntax.html">http://www.geany.org/manual/gtk/glib/glib-regex-syntax.html</a>.</p>
1820 <div class="note">
1821 <p class="first admonition-title">Note</p>
1822 <ol class="last arabic simple">
1823 <li>The <em>Use escape sequences</em> dialog option always applies for regular
1824 expressions.</li>
1825 <li>Searching backwards with regular expressions is not supported.</li>
1826 </ol>
1827 </div>
1828 <p><strong>In a regular expression, the following characters are interpreted:</strong></p>
1829 <table border="1" class="docutils">
1830 <colgroup>
1831 <col width="10%" />
1832 <col width="90%" />
1833 </colgroup>
1834 <tbody valign="top">
1835 <tr><td>.</td>
1836 <td>Matches any character.</td>
1837 </tr>
1838 <tr><td>(</td>
1839 <td>This marks the start of a region for tagging a match.</td>
1840 </tr>
1841 <tr><td>)</td>
1842 <td>This marks the end of a tagged region.</td>
1843 </tr>
1844 <tr><td>\n</td>
1845 <td><p class="first">Where n is 1 through 9 refers to the first through ninth tagged
1846 region when searching or replacing.</p>
1847 <p>Searching for (Wiki)\1 matches WikiWiki.</p>
1848 <p class="last">If the search string was Fred([1-9])XXX and the
1849 replace string was Sam\1YYY, when applied to Fred2XXX this
1850 would generate Sam2YYY.</p>
1851 </td>
1852 </tr>
1853 <tr><td>\0</td>
1854 <td>When replacing, the whole matching text.</td>
1855 </tr>
1856 <tr><td>\b</td>
1857 <td>This matches a word boundary.</td>
1858 </tr>
1859 <tr><td>\c</td>
1860 <td><p class="first">A backslash followed by d, D, s, S, w or W, becomes a
1861 character class (both inside and outside sets []).</p>
1862 <ul class="last simple">
1863 <li>d: decimal digits</li>
1864 <li>D: any char except decimal digits</li>
1865 <li>s: whitespace (space, \t \n \r \f \v)</li>
1866 <li>S: any char except whitespace (see above)</li>
1867 <li>w: alphanumeric &amp; underscore</li>
1868 <li>W: any char except alphanumeric &amp; underscore</li>
1869 </ul>
1870 </td>
1871 </tr>
1872 <tr><td>\x</td>
1873 <td>This allows you to use a character x that would otherwise have
1874 a special meaning. For example, \[ would be interpreted as [
1875 and not as the start of a character set. Use \\ for a literal
1876 backslash.</td>
1877 </tr>
1878 <tr><td>[...]</td>
1879 <td><p class="first">Matches one of the characters in the set. If the first
1880 character in the set is ^, it matches the characters NOT in
1881 the set, i.e. complements the set. A shorthand S-E (start
1882 dash end) is used to specify a set of characters S up to E,
1883 inclusive.</p>
1884 <p>The special characters ] and - have no special
1885 meaning if they appear first in the set. - can also be last
1886 in the set. To include both, put ] first: []A-Z-].</p>
1887 <p>Examples:</p>
1888 <pre class="last literal-block">
1889 []|-] matches these 3 chars
1890 []-|] matches from ] to | chars
1891 [a-z] any lowercase alpha
1892 [^]-] any char except - and ]
1893 [^A-Z] any char except uppercase alpha
1894 [a-zA-Z] any alpha
1895 </pre>
1896 </td>
1897 </tr>
1898 <tr><td>^</td>
1899 <td>This matches the start of a line (unless used inside a set, see
1900 above).</td>
1901 </tr>
1902 <tr><td>$</td>
1903 <td>This matches the end of a line.</td>
1904 </tr>
1905 <tr><td>*</td>
1906 <td>This matches 0 or more times. For example, Sa*m matches Sm, Sam,
1907 Saam, Saaam and so on.</td>
1908 </tr>
1909 <tr><td>+</td>
1910 <td>This matches 1 or more times. For example, Sa+m matches Sam,
1911 Saam, Saaam and so on.</td>
1912 </tr>
1913 <tr><td>?</td>
1914 <td>This matches 0 or 1 time(s). For example, Joh?n matches John, Jon.</td>
1915 </tr>
1916 </tbody>
1917 </table>
1918 <div class="note">
1919 <p class="first admonition-title">Note</p>
1920 <p class="last">This table is adapted from Scintilla and SciTE documentation,
1921 distributed under the <a class="reference internal" href="#license-for-scintilla-and-scite">License for Scintilla and SciTE</a>.</p>
1922 </div>
1923 </div>
1924 </div>
1925 <div class="section" id="view-menu">
1926 <h2><a class="toc-backref" href="#id76">View menu</a></h2>
1927 <p>The View menu allows various elements of the main window to be shown
1928 or hidden, and also provides various display-related editor options.</p>
1929 <div class="section" id="color-schemes-menu">
1930 <h3><a class="toc-backref" href="#id77">Color schemes menu</a></h3>
1931 <p>The Color schemes menu is available under the <em>View-&gt;Editor</em> submenu.
1932 It lists various color schemes for editor highlighting styles,
1933 including the default scheme first. Other items are available based
1934 on what color scheme files Geany found at startup.</p>
1935 <p>Color scheme files are read from the <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a> under
1936 the <tt class="docutils literal">colorschemes</tt> subdirectory. They should have the extension
1937 <tt class="docutils literal">.conf</tt>. The default color scheme
1938 is read from <tt class="docutils literal">filetypes.common</tt>.</p>
1939 <p>The <a class="reference internal" href="#named-styles-section">[named_styles] section</a> and <a class="reference internal" href="#named-colors-section">[named_colors] section</a> are the
1940 same as for <tt class="docutils literal">filetypes.common</tt>.</p>
1941 <p>The <tt class="docutils literal">[theme_info]</tt> section can contain information about the
1942 theme. The <tt class="docutils literal">name</tt> and <tt class="docutils literal">description</tt> keys are read to set the
1943 menu item text and tooltip, respectively. These keys can have
1944 translations, e.g.:</p>
1945 <pre class="literal-block">
1946 key=Hello
1947 key[de]=Hallo
1948 key[fr_FR]=Bonjour
1949 </pre>
1950 </div>
1951 </div>
1952 <div class="section" id="tags">
1953 <h2><a class="toc-backref" href="#id78">Tags</a></h2>
1954 <p>Tags are information that relates symbols in a program with the
1955 source file location of the declaration and definition.</p>
1956 <p>Geany has built-in functionality for generating tag information (aka
1957 &quot;workspace tags&quot;) for supported filetypes when you open a file. You
1958 can also have Geany automatically load external tag files (aka &quot;global
1959 tags files&quot;) upon startup, or manually using <em>Tools --&gt; Load Tags</em>.</p>
1960 <p>Geany uses its own tag file format, similar to what <tt class="docutils literal">ctags</tt> uses
1961 (but is incompatible with ctags). You use Geany to generate global
1962 tags files, as described below.</p>
1963 <div class="section" id="workspace-tags">
1964 <h3><a class="toc-backref" href="#id79">Workspace tags</a></h3>
1965 <p>Tags for each document are parsed whenever a file is loaded, saved or
1966 modified (see <em>Symbol list update frequency</em> preference in the <a class="reference internal" href="#editor-completions-preferences">Editor
1967 Completions preferences</a>). These are shown in the Symbol list in the
1968 Sidebar. These tags are also used for autocompletion of symbols and calltips
1969 for all documents open in the current session that have the same filetype.</p>
1970 <p>The <em>Go to Tag</em> commands can be used with all workspace tags. See
1971 <a class="reference internal" href="#go-to-tag-definition">Go to tag definition</a>.</p>
1972 </div>
1973 <div class="section" id="global-tags">
1974 <h3><a class="toc-backref" href="#id80">Global tags</a></h3>
1975 <p>Global tags are used to provide autocompletion of symbols and calltips
1976 without having to open the corresponding source files. This is intended
1977 for library APIs, as the tags file only has to be updated when you upgrade
1978 the library.</p>
1979 <p>You can load a custom global tags file in two ways:</p>
1980 <ul class="simple">
1981 <li>Using the <em>Load Tags</em> command in the Tools menu.</li>
1982 <li>By moving or symlinking tags files to the <tt class="docutils literal">tags</tt> subdirectory of
1983 one of the <a class="reference internal" href="#configuration-file-paths">configuration file paths</a> before starting Geany.</li>
1984 </ul>
1985 <p>You can either download these files or generate your own. They have
1986 the format:</p>
1987 <pre class="literal-block">
1988 name.lang_ext.tags
1989 </pre>
1990 <p><em>lang_ext</em> is one of the extensions set for the filetype associated
1991 with the tags. See the section called <a class="reference internal" href="#filetype-extensions">Filetype extensions</a> for
1992 more information.</p>
1993 <div class="section" id="default-global-tags-files">
1994 <h4><a class="toc-backref" href="#id81">Default global tags files</a></h4>
1995 <p>For some languages, a list of global tags is loaded when the
1996 corresponding filetype is first used. Currently these are for:</p>
1997 <ul class="simple">
1998 <li>C</li>
1999 <li>Pascal</li>
2000 <li>PHP</li>
2001 <li>HTML -- &amp;symbol; completion, e.g. for ampersand, copyright, etc.</li>
2002 <li>LaTeX</li>
2003 <li>Python</li>
2004 </ul>
2005 </div>
2006 <div class="section" id="global-tags-file-format">
2007 <h4><a class="toc-backref" href="#id82">Global tags file format</a></h4>
2008 <p>Global tags files can have two different formats:</p>
2009 <ul class="simple">
2010 <li>Tagmanager format</li>
2011 <li>Pipe-separated format</li>
2012 </ul>
2013 <p>The first line of global tags files should be a comment, introduced
2014 by <tt class="docutils literal">#</tt> followed by a space and a string like <tt class="docutils literal">format=pipe</tt>
2015 or <tt class="docutils literal">format=tagmanager</tt> respectively, these are case-sensitive.
2016 This helps Geany to read the file properly. If this line
2017 is missing, Geany tries to auto-detect the used format but this
2018 might fail.</p>
2019 <p>The Tagmanager format is a bit more complex and is used for files
2020 created by the <tt class="docutils literal">geany <span class="pre">-g</span></tt> command. There is one tag per line.
2021 Different tag attributes like the return value or the argument list
2022 are separated with different characters indicating the type of the
2023 following argument.</p>
2024 <div class="section" id="pipe-separated-format">
2025 <h5><a class="toc-backref" href="#id83">Pipe-separated format</a></h5>
2026 <p>The Pipe-separated format is easier to read and write.
2027 There is one tag per line and different tag attributes are separated
2028 by the pipe character (<tt class="docutils literal">|</tt>). A line looks like:</p>
2029 <pre class="literal-block">
2030 basename|string|(string path [, string suffix])|
2031 </pre>
2032 <div class="line-block">
2033 <div class="line">The first field is the tag name (usually a function name).</div>
2034 <div class="line">The second field is the type of the return value.</div>
2035 <div class="line">The third field is the argument list for this tag.</div>
2036 <div class="line">The fourth field is the description for this tag but
2037 currently unused and should be left empty.</div>
2038 </div>
2039 <p>Except for the first field (tag name), all other field can be left
2040 empty but the pipe separator must appear for them.</p>
2041 <p>You can easily write your own global tag files using this format.
2042 Just save them in your tags directory, as described earlier in the
2043 section <a class="reference internal" href="#global-tags">Global tags</a>.</p>
2044 </div>
2045 </div>
2046 <div class="section" id="generating-a-global-tags-file">
2047 <h4><a class="toc-backref" href="#id84">Generating a global tags file</a></h4>
2048 <p>You can generate your own global tags files by parsing a list of
2049 source files. The command is:</p>
2050 <pre class="literal-block">
2051 geany -g [-P] &lt;Tag File&gt; &lt;File list&gt;
2052 </pre>
2053 <ul class="simple">
2054 <li>Tag File filename should be in the format described earlier --
2055 see the section called <a class="reference internal" href="#global-tags">Global tags</a>.</li>
2056 <li>File list is a list of filenames, each with a full path (unless
2057 you are generating C/C++ tags and have set the CFLAGS environment
2058 variable appropriately).</li>
2059 <li><tt class="docutils literal"><span class="pre">-P</span></tt> or <tt class="docutils literal"><span class="pre">--no-preprocessing</span></tt> disables using the C pre-processor
2060 to process <tt class="docutils literal">#include</tt> directives for C/C++ source files. Use this
2061 option if you want to specify each source file on the command-line
2062 instead of using a 'master' header file. Also can be useful if you
2063 don't want to specify the CFLAGS environment variable.</li>
2064 </ul>
2065 <p>Example for the wxD library for the D programming language:</p>
2066 <pre class="literal-block">
2067 geany -g wxd.d.tags /home/username/wxd/wx/*.d
2068 </pre>
2069 <div class="section" id="generating-c-c-tag-files">
2070 <h5><a class="toc-backref" href="#id85">Generating C/C++ tag files</a></h5>
2071 <p>You may need to first setup the <a class="reference internal" href="#c-ignore-tags">C ignore.tags</a> file.</p>
2072 <p>For C/C++ tag files gcc is required by default, so that header files
2073 can be preprocessed to include any other headers they depend upon. If
2074 you do not want this, use the <tt class="docutils literal"><span class="pre">-P</span></tt> option described above.</p>
2075 <p>For preprocessing, the environment variable CFLAGS should be set with
2076 appropriate <tt class="docutils literal"><span class="pre">-I/path</span></tt> include paths. The following example works with
2077 the bash shell, generating tags for the GnomeUI library:</p>
2078 <pre class="literal-block">
2079 CFLAGS=`pkg-config --cflags libgnomeui-2.0` geany -g gnomeui.c.tags \
2080 /usr/include/libgnomeui-2.0/gnome.h
2081 </pre>
2082 <p>You can adapt this command to use CFLAGS and header files appropriate
2083 for whichever libraries you want.</p>
2084 </div>
2085 <div class="section" id="generating-tag-files-on-windows">
2086 <h5><a class="toc-backref" href="#id86">Generating tag files on Windows</a></h5>
2087 <p>This works basically the same as on other platforms:</p>
2088 <pre class="literal-block">
2089 &quot;c:\program files\geany\bin\geany&quot; -g c:\mytags.php.tags c:\code\somefile.php
2090 </pre>
2091 </div>
2092 </div>
2093 </div>
2094 <div class="section" id="c-ignore-tags">
2095 <h3><a class="toc-backref" href="#id87">C ignore.tags</a></h3>
2096 <p>You can ignore certain tags for C-based languages if they would lead
2097 to wrong parsing of the code. Use the <em>Tools-&gt;Configuration
2098 Files-&gt;ignore.tags</em> menu item to open the user <tt class="docutils literal">ignore.tags</tt> file.
2099 See also <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>.</p>
2100 <p>List all tag names you want to ignore in this file, separated by spaces
2101 and/or newlines.</p>
2102 <p>Example:</p>
2103 <pre class="literal-block">
2104 G_GNUC_NULL_TERMINATED
2105 G_GNUC_PRINTF
2106 G_GNUC_WARN_UNUSED_RESULT
2107 </pre>
2108 <p>This will parse code like:</p>
2109 <p><tt class="docutils literal">gchar **utils_strv_new(const gchar *first, <span class="pre">...)</span>
2110 G_GNUC_NULL_TERMINATED;</tt></p>
2111 <p>More detailed information about ignore tags usage from the Exuberant Ctags
2112 manual page:</p>
2113 <blockquote>
2114 Specifies a list of identifiers which are to be specially handled
2115 while parsing C and C++ source files. This option is specifically
2116 provided to handle special cases arising through the use of
2117 pre-processor macros. When the identifiers listed are simple identifiers,
2118 these identifiers will be ignored during parsing of the source files.
2119 If an identifier is suffixed with a '+' character, ctags will also
2120 ignore any parenthesis-enclosed argument list which may immediately
2121 follow the identifier in the source files.
2122 If two identifiers are separated with the '=' character, the first
2123 identifiers is replaced by the second identifiers for parsing purposes.</blockquote>
2124 <p>For even more detailed information please read the manual page of
2125 Exuberant Ctags.</p>
2126 <p>Geany extends Ctags with a '*' character suffix - this means use
2127 prefix matching, e.g. G_GNUC_* will match G_GNUC_NULL_TERMINATED, etc.
2128 Note that prefix match items should be put after other items to ensure
2129 that items like G_GNUC_PRINTF+ get parsed correctly.</p>
2130 </div>
2131 </div>
2132 <div class="section" id="preferences">
2133 <h2><a class="toc-backref" href="#id88">Preferences</a></h2>
2134 <p>You may adjust Geany's settings using the Edit --&gt; Preferences
2135 dialog. Any changes you make there can be applied by hitting either
2136 the Apply or the OK button. These settings will persist between Geany
2137 sessions. Note that most settings here have descriptive popup bubble
2138 help -- just hover the mouse over the item in question to get help
2139 on it.</p>
2140 <p>You may also adjust some View settings (under the View menu) that
2141 persist between Geany sessions. The settings under the Document menu,
2142 however, are only for the current document and revert to defaults
2143 when restarting Geany.</p>
2144 <div class="note">
2145 <p class="first admonition-title">Note</p>
2146 <p class="last">In the paragraphs that follow, the text describing a dialog tab
2147 comes after the screenshot of that tab.</p>
2148 </div>
2149 <div class="section" id="general-startup-preferences">
2150 <h3><a class="toc-backref" href="#id89">General Startup preferences</a></h3>
2151 <img alt="./images/pref_dialog_gen_startup.png" src="./images/pref_dialog_gen_startup.png" />
2152 <div class="section" id="id1">
2153 <h4><a class="toc-backref" href="#id90">Startup</a></h4>
2154 <dl class="docutils">
2155 <dt>Load files from the last session</dt>
2156 <dd>On startup, load the same files you had open the last time you
2157 used Geany.</dd>
2158 <dt>Load virtual terminal support</dt>
2159 <dd>Load the library for running a terminal in the message window area.</dd>
2160 <dt>Enable plugin support</dt>
2161 <dd>Allow plugins to be used in Geany.</dd>
2162 </dl>
2163 </div>
2164 <div class="section" id="shutdown">
2165 <h4><a class="toc-backref" href="#id91">Shutdown</a></h4>
2166 <dl class="docutils">
2167 <dt>Save window position and geometry</dt>
2168 <dd>Save the current position and size of the main window so next time
2169 you open Geany it's in the same location.</dd>
2170 <dt>Confirm Exit</dt>
2171 <dd>Have a dialog pop up to confirm that you really want to quit Geany.</dd>
2172 </dl>
2173 </div>
2174 <div class="section" id="paths">
2175 <h4><a class="toc-backref" href="#id92">Paths</a></h4>
2176 <dl class="docutils">
2177 <dt>Startup path</dt>
2178 <dd>Path to start in when opening or saving files.
2179 It must be an absolute path.</dd>
2180 <dt>Project files</dt>
2181 <dd>Path to start in when opening project files.</dd>
2182 <dt>Extra plugin path</dt>
2183 <dd>By default Geany looks in the system installation and the user
2184 configuration - see <a class="reference internal" href="#plugins">Plugins</a>. In addition the path entered here will be
2185 searched.
2186 Usually you do not need to set an additional path to search for
2187 plugins. It might be useful when Geany is installed on a multi-user machine
2188 and additional plugins are available in a common location for all users.
2189 Leave blank to not set an additional lookup path.</dd>
2190 </dl>
2191 </div>
2192 </div>
2193 <div class="section" id="general-miscellaneous-preferences">
2194 <h3><a class="toc-backref" href="#id93">General Miscellaneous preferences</a></h3>
2195 <img alt="./images/pref_dialog_gen_misc.png" src="./images/pref_dialog_gen_misc.png" />
2196 <div class="section" id="miscellaneous">
2197 <h4><a class="toc-backref" href="#id94">Miscellaneous</a></h4>
2198 <dl class="docutils">
2199 <dt>Beep on errors when compilation has finished</dt>
2200 <dd>Have the computer make a beeping sound when compilation of your program
2201 has completed or any errors occurred.</dd>
2202 <dt>Switch status message list at new message</dt>
2203 <dd>Switch to the status message tab (in the notebook window at the bottom)
2204 once a new status message arrives.</dd>
2205 <dt>Suppress status messages in the status bar</dt>
2206 <dd><p class="first">Remove all messages from the status bar. The messages are still displayed
2207 in the status messages window.</p>
2208 <div class="tip last">
2209 <p class="first admonition-title">Tip</p>
2210 <p class="last">Another option is to use the <em>Switch to Editor</em> keybinding - it
2211 reshows the document statistics on the status bar. See <a class="reference internal" href="#focus-keybindings">Focus
2212 keybindings</a>.</p>
2213 </div>
2214 </dd>
2215 <dt>Use Windows File Open/Save dialogs</dt>
2216 <dd>Defines whether to use the native Windows File Open/Save dialogs or
2217 whether to use the GTK default dialogs.</dd>
2218 <dt>Auto-focus widgets (focus follows mouse)</dt>
2219 <dd>Give the focus automatically to widgets below the mouse cursor.
2220 This works for the main editor widget, the scribble, the toolbar search field
2221 goto line fields and the VTE.</dd>
2222 </dl>
2223 </div>
2224 <div class="section" id="search">
2225 <h4><a class="toc-backref" href="#id95">Search</a></h4>
2226 <dl class="docutils">
2227 <dt>Always wrap search</dt>
2228 <dd>Always wrap search around the document when finding a match.</dd>
2229 <dt>Hide the Find dialog</dt>
2230 <dd>Hide the <a class="reference internal" href="#find">Find</a> dialog after clicking Find Next/Previous.</dd>
2231 <dt>Use the current word under the cursor for Find dialogs</dt>
2232 <dd>Use current word under the cursor when opening the Find, Find in Files or Replace dialog and
2233 there is no selection. When this option is disabled, the search term last used in the
2234 appropriate Find dialog is used.</dd>
2235 <dt>Use the current file's directory for Find in Files</dt>
2236 <dd>When opening the Find in Files dialog, set the directory to search to the directory of the current
2237 active file. When this option is disabled, the directory of the last use of the Find in Files
2238 dialog is used. See <a class="reference internal" href="#find-in-files">Find in Files</a> for details.</dd>
2239 </dl>
2240 </div>
2241 <div class="section" id="projects">
2242 <h4><a class="toc-backref" href="#id96">Projects</a></h4>
2243 <dl class="docutils">
2244 <dt>Use project-based session files</dt>
2245 <dd>Save your current session when closing projects. You will be able to
2246 resume different project sessions, automatically opening the files
2247 you had open previously.</dd>
2248 <dt>Store project file inside the project base directory</dt>
2249 <dd>When creating new projects, the default path for the project file contains
2250 the project base path. Without this option enabled, the default project file
2251 path is one level above the project base path.
2252 In either case, you can easily set the final project file path in the
2253 <em>New Project</em> dialog. This option provides the more common
2254 defaults automatically for convenience.</dd>
2255 </dl>
2256 </div>
2257 </div>
2258 <div class="section" id="interface-preferences">
2259 <h3><a class="toc-backref" href="#id97">Interface preferences</a></h3>
2260 <img alt="./images/pref_dialog_interface_interface.png" src="./images/pref_dialog_interface_interface.png" />
2261 <div class="section" id="sidebar">
2262 <h4><a class="toc-backref" href="#id98">Sidebar</a></h4>
2263 <dl class="docutils">
2264 <dt>Show sidebar</dt>
2265 <dd>Whether to show the sidebar at all.</dd>
2266 <dt>Show symbol list</dt>
2267 <dd>Show the list of functions, variables, and other information in the
2268 current document you are editing.</dd>
2269 <dt>Show documents list</dt>
2270 <dd>Show all the documents you have open currently. This can be used to
2271 change between documents (see <a class="reference internal" href="#switching-between-documents">Switching between documents</a>) and
2272 to perform some common operations such as saving, closing and reloading.</dd>
2273 <dt>Position</dt>
2274 <dd>Whether to place the sidebar on the left or right of the editor window.</dd>
2275 </dl>
2276 </div>
2277 <div class="section" id="fonts">
2278 <h4><a class="toc-backref" href="#id99">Fonts</a></h4>
2279 <dl class="docutils">
2280 <dt>Editor</dt>
2281 <dd>Change the font used to display documents.</dd>
2282 <dt>Symbol list</dt>
2283 <dd>Change the font used for the Symbols sidebar tab.</dd>
2284 <dt>Message window</dt>
2285 <dd>Change the font used for the message window area.</dd>
2286 </dl>
2287 </div>
2288 <div class="section" id="id2">
2289 <h4><a class="toc-backref" href="#id100">Miscellaneous</a></h4>
2290 <dl class="docutils">
2291 <dt>Show status bar</dt>
2292 <dd>Show the status bar at the bottom of the main window. It gives information about
2293 the file you are editing like the line and column you are on, whether any
2294 modifications were done, the file encoding, the filetype and other information.</dd>
2295 </dl>
2296 </div>
2297 </div>
2298 <div class="section" id="interface-notebook-tab-preferences">
2299 <h3><a class="toc-backref" href="#id101">Interface Notebook tab preferences</a></h3>
2300 <img alt="./images/pref_dialog_interface_notebook.png" src="./images/pref_dialog_interface_notebook.png" />
2301 <div class="section" id="editor-tabs">
2302 <h4><a class="toc-backref" href="#id102">Editor tabs</a></h4>
2303 <dl class="docutils">
2304 <dt>Show editor tabs</dt>
2305 <dd>Show a notebook tab for all documents so you can switch between them
2306 using the mouse (instead of using the Documents window).</dd>
2307 <dt>Show close buttons</dt>
2308 <dd>Make each tab show a close button so you can easily close open
2309 documents.</dd>
2310 <dt>Placement of new file tabs</dt>
2311 <dd>Whether to create a document with its notebook tab to the left or
2312 right of all existing tabs.</dd>
2313 <dt>Next to current</dt>
2314 <dd>Whether to place file tabs next to the current tab
2315 rather than at the edges of the notebook.</dd>
2316 <dt>Double-clicking hides all additional widgets</dt>
2317 <dd>Whether to call the View-&gt;Toggle All Additional Widgets command
2318 when double-clicking on a notebook tab.</dd>
2319 </dl>
2320 </div>
2321 <div class="section" id="tab-positions">
2322 <h4><a class="toc-backref" href="#id103">Tab positions</a></h4>
2323 <dl class="docutils">
2324 <dt>Editor</dt>
2325 <dd>Set the positioning of the editor's notebook tabs to the right,
2326 left, top, or bottom of the editing window.</dd>
2327 <dt>Sidebar</dt>
2328 <dd>Set the positioning of the sidebar's notebook tabs to the right,
2329 left, top, or bottom of the sidebar window.</dd>
2330 <dt>Message window</dt>
2331 <dd>Set the positioning of the message window's notebook tabs to the
2332 right, left, top, or bottom of the message window.</dd>
2333 </dl>
2334 </div>
2335 </div>
2336 <div class="section" id="interface-toolbar-preferences">
2337 <h3><a class="toc-backref" href="#id104">Interface Toolbar preferences</a></h3>
2338 <p>Affects the main toolbar underneath the menu bar.</p>
2339 <img alt="./images/pref_dialog_interface_toolbar.png" src="./images/pref_dialog_interface_toolbar.png" />
2340 <div class="section" id="toolbar">
2341 <h4><a class="toc-backref" href="#id105">Toolbar</a></h4>
2342 <dl class="docutils">
2343 <dt>Show Toolbar</dt>
2344 <dd>Whether to show the toolbar.</dd>
2345 <dt>Append Toolbar to the Menu</dt>
2346 <dd>Allows to append the toolbar to the main menu bar instead of placing it below.
2347 This is useful to save vertical space.</dd>
2348 <dt>Customize Toolbar</dt>
2349 <dd>See <a class="reference internal" href="#customizing-the-toolbar">Customizing the toolbar</a>.</dd>
2350 </dl>
2351 </div>
2352 <div class="section" id="appearance">
2353 <h4><a class="toc-backref" href="#id106">Appearance</a></h4>
2354 <dl class="docutils">
2355 <dt>Icon Style</dt>
2356 <dd>Select the toolbar icon style to use - either icons and text, just
2357 icons or just text.
2358 The choice System default uses whatever icon style is set by GTK.</dd>
2359 <dt>Icon size</dt>
2360 <dd>Select the size of the icons you see (large, small or very small).
2361 The choice System default uses whatever icon size is set by GTK.</dd>
2362 </dl>
2363 </div>
2364 </div>
2365 <div class="section" id="editor-features-preferences">
2366 <h3><a class="toc-backref" href="#id107">Editor Features preferences</a></h3>
2367 <img alt="./images/pref_dialog_edit_features.png" src="./images/pref_dialog_edit_features.png" />
2368 <div class="section" id="features">
2369 <h4><a class="toc-backref" href="#id108">Features</a></h4>
2370 <dl class="docutils">
2371 <dt>Line wrapping</dt>
2372 <dd>Show long lines wrapped around to new display lines.</dd>
2373 </dl>
2374 <dl class="docutils" id="smart-home-key">
2375 <dt>&quot;Smart&quot; home key</dt>
2376 <dd>Whether to move the cursor to the first non-whitespace character
2377 on the line when you hit the home key on your keyboard. Pressing it
2378 again will go to the very start of the line.</dd>
2379 <dt>Disable Drag and Drop</dt>
2380 <dd>Do not allow the dragging and dropping of selected text in documents.</dd>
2381 <dt>Code folding</dt>
2382 <dd>Allow groups of lines in a document to be collapsed for easier
2383 navigation/editing.</dd>
2384 <dt>Fold/Unfold all children of a fold point</dt>
2385 <dd>Whether to fold/unfold all child fold points when a parent line
2386 is folded.</dd>
2387 <dt>Use indicators to show compile errors</dt>
2388 <dd>Underline lines with compile errors using red squiggles to indicate
2389 them in the editor area.</dd>
2390 <dt>Newline strips trailing spaces</dt>
2391 <dd>Remove any whitespace at the end of the line when you hit the
2392 Enter/Return key. See also <a class="reference internal" href="#strip-trailing-spaces">Strip trailing spaces</a>.</dd>
2393 <dt>Line breaking column</dt>
2394 <dd>The editor column number to insert a newline at when Line Breaking
2395 is enabled for the current document.</dd>
2396 <dt>Comment toggle marker</dt>
2397 <dd>A string which is added when toggling a line comment in a source file.
2398 It is used to mark the comment as toggled.</dd>
2399 </dl>
2400 </div>
2401 </div>
2402 <div class="section" id="editor-indentation-preferences">
2403 <h3><a class="toc-backref" href="#id109">Editor Indentation preferences</a></h3>
2404 <img alt="./images/pref_dialog_edit_indentation.png" src="./images/pref_dialog_edit_indentation.png" />
2405 <div class="section" id="indentation-group">
2406 <h4><a class="toc-backref" href="#id110">Indentation group</a></h4>
2407 <p>See <a class="reference internal" href="#indentation">Indentation</a> for more information.</p>
2408 <dl class="docutils">
2409 <dt>Width</dt>
2410 <dd>The width of a single indent size in spaces. By default the indent
2411 size is equivalent to 4 spaces.</dd>
2412 <dt>Detect width from file</dt>
2413 <dd>Try to detect and set the indent width based on file content, when
2414 a file is opened.</dd>
2415 <dt>Type</dt>
2416 <dd><p class="first">When Geany inserts indentation, whether to use:</p>
2417 <ul class="simple">
2418 <li>Just Tabs</li>
2419 <li>Just Spaces</li>
2420 <li>Tabs and Spaces, depending on how much indentation is on a line</li>
2421 </ul>
2422 <p class="last">The <em>Tabs and Spaces</em> indent type is also known as <em>Soft tab
2423 support</em> in some other editors.</p>
2424 </dd>
2425 <dt>Detect type from file</dt>
2426 <dd>Try to detect and set the indent type based on file content, when
2427 a file is opened.</dd>
2428 <dt>Auto-indent mode</dt>
2429 <dd><p class="first">The type of auto-indentation you wish to use after pressing Enter,
2430 if any.</p>
2431 <dl class="last docutils">
2432 <dt>Basic</dt>
2433 <dd>Just add the indentation of the previous line.</dd>
2434 <dt>Current chars</dt>
2435 <dd>Add indentation based on the current filetype and any characters at
2436 the end of the line such as <tt class="docutils literal">{</tt>, <tt class="docutils literal">}</tt> for C, <tt class="docutils literal">:</tt> for Python.</dd>
2437 <dt>Match braces</dt>
2438 <dd>Like <em>Current chars</em> but for C-like languages, make a closing
2439 <tt class="docutils literal">}</tt> brace line up with the matching opening brace.</dd>
2440 </dl>
2441 </dd>
2442 <dt>Tab key indents</dt>
2443 <dd><p class="first">If set, pressing tab will indent the current line or selection, and
2444 unindent when pressing Shift-tab. Otherwise, the tab key will
2445 insert a tab character into the document (which can be different
2446 from indentation, depending on the indent type).</p>
2447 <div class="note last">
2448 <p class="first admonition-title">Note</p>
2449 <p class="last">There are also separate configurable keybindings for indent &amp;
2450 unindent, but this preference allows the tab key to have different
2451 meanings in different contexts - e.g. for snippet completion.</p>
2452 </div>
2453 </dd>
2454 </dl>
2455 </div>
2456 </div>
2457 <div class="section" id="editor-completions-preferences">
2458 <h3><a class="toc-backref" href="#id111">Editor Completions preferences</a></h3>
2459 <img alt="./images/pref_dialog_edit_completions.png" src="./images/pref_dialog_edit_completions.png" />
2460 <div class="section" id="completions">
2461 <h4><a class="toc-backref" href="#id112">Completions</a></h4>
2462 <dl class="docutils">
2463 <dt>Snippet Completion</dt>
2464 <dd>Whether to replace special keywords after typing Tab into a
2465 pre-defined text snippet.
2466 See <a class="reference internal" href="#user-definable-snippets">User-definable snippets</a>.</dd>
2467 <dt>XML/HTML tag auto-closing</dt>
2468 <dd>When you open an XML/HTML tag automatically generate its
2469 completion tag.</dd>
2470 <dt>Automatic continuation multi-line comments</dt>
2471 <dd><p class="first">Continue automatically multi-line comments in languages like C, C++
2472 and Java when a new line is entered inside such a comment.
2473 With this option enabled, Geany will insert a <tt class="docutils literal">*</tt> on every new line
2474 inside a multi-line comment, for example when you press return in the
2475 following C code:</p>
2476 <pre class="literal-block">
2478 * This is a C multi-line comment, press &lt;Return&gt;
2479 </pre>
2480 <p>then Geany would insert:</p>
2481 <pre class="literal-block">
2483 </pre>
2484 <p class="last">on the next line with the correct indentation based on the previous line,
2485 as long as the multi-line is not closed by <tt class="docutils literal">*/</tt>.</p>
2486 </dd>
2487 <dt>Autocomplete symbols</dt>
2488 <dd>When you start to type a symbol name, look for the full string to
2489 allow it to be completed for you.</dd>
2490 <dt>Autocomplete all words in document</dt>
2491 <dd>When you start to type a word, Geany will search the whole document for
2492 words starting with the typed part to complete it, assuming there
2493 are no tag names to show.</dd>
2494 <dt>Drop rest of word on completion</dt>
2495 <dd>Remove any word part to the right of the cursor when choosing a
2496 completion list item.</dd>
2497 <dt>Characters to type for autocompletion</dt>
2498 <dd>Number of characters of a word to type before autocompletion is
2499 displayed.</dd>
2500 <dt>Completion list height</dt>
2501 <dd>The number of rows to display for the autocompletion window.</dd>
2502 <dt>Max. symbol name suggestions</dt>
2503 <dd>The maximum number of items in the autocompletion list.</dd>
2504 <dt>Symbol list update frequency</dt>
2505 <dd><p class="first">The minimum delay (in milliseconds) between two symbol list updates.</p>
2506 <p>This option determines how frequently the tag list is updated for the
2507 current document. The smaller the delay, the more up-to-date the symbol
2508 list (and then the completions); but rebuilding the symbol list has a
2509 cost in performance, especially with large files.</p>
2510 <p>The default value is 250ms, which means the symbol list will be updated
2511 at most four times per second, even if the document changes continuously.</p>
2512 <p class="last">A value of 0 disables automatic updates, so the symbol list will only be
2513 updated upon document saving.</p>
2514 </dd>
2515 </dl>
2516 </div>
2517 <div class="section" id="auto-close-quotes-and-brackets">
2518 <h4><a class="toc-backref" href="#id113">Auto-close quotes and brackets</a></h4>
2519 <p>Geany can automatically insert a closing bracket and quote characters when
2520 you open them. For instance, you type a <tt class="docutils literal">(</tt> and Geany will automatically
2521 insert <tt class="docutils literal">)</tt>. With the following options, you can define for which
2522 characters this should work.</p>
2523 <dl class="docutils">
2524 <dt>Parenthesis ( )</dt>
2525 <dd>Auto-close parenthesis when typing an opening one</dd>
2526 <dt>Curly brackets { }</dt>
2527 <dd>Auto-close curly brackets (braces) when typing an opening one</dd>
2528 <dt>Square brackets [ ]</dt>
2529 <dd>Auto-close square brackets when typing an opening one</dd>
2530 <dt>Single quotes ' '</dt>
2531 <dd>Auto-close single quotes when typing an opening one</dd>
2532 <dt>Double quotes &quot; &quot;</dt>
2533 <dd>Auto-close double quotes when typing an opening one</dd>
2534 </dl>
2535 </div>
2536 </div>
2537 <div class="section" id="editor-display-preferences">
2538 <h3><a class="toc-backref" href="#id114">Editor Display preferences</a></h3>
2539 <p>This is for visual elements displayed in the editor window.</p>
2540 <img alt="./images/pref_dialog_edit_display.png" src="./images/pref_dialog_edit_display.png" />
2541 <div class="section" id="display">
2542 <h4><a class="toc-backref" href="#id115">Display</a></h4>
2543 <dl class="docutils">
2544 <dt>Invert syntax highlighting colors</dt>
2545 <dd>Invert all colors, by default this makes white text on a black
2546 background.</dd>
2547 <dt>Show indendation guides</dt>
2548 <dd>Show vertical lines to help show how much leading indentation there
2549 is on each line.</dd>
2550 <dt>Show whitespaces</dt>
2551 <dd>Mark all tabs with an arrow &quot;--&gt;&quot; symbol and spaces with dots to
2552 show which kinds of whitespace are used.</dd>
2553 <dt>Show line endings</dt>
2554 <dd>Display a symbol everywhere that a carriage return or line feed
2555 is present.</dd>
2556 <dt>Show line numbers</dt>
2557 <dd>Show or hide the Line Number margin.</dd>
2558 <dt>Show markers margin</dt>
2559 <dd>Show or hide the small margin right of the line numbers, which is used
2560 to mark lines.</dd>
2561 <dt>Stop scrolling at last line</dt>
2562 <dd>When enabled Geany stops scrolling when at the last line of the document.
2563 Otherwise you can scroll one more page even if there are no real lines.</dd>
2564 </dl>
2565 </div>
2566 <div class="section" id="long-line-marker">
2567 <h4><a class="toc-backref" href="#id116">Long line marker</a></h4>
2568 <p>The long line marker helps to indicate overly-long lines, or as a hint
2569 to the user for when to break the line.</p>
2570 <dl class="docutils">
2571 <dt>Type</dt>
2572 <dd><dl class="first last docutils">
2573 <dt>Line</dt>
2574 <dd>Show a thin vertical line in the editor window at the given column
2575 position.</dd>
2576 <dt>Background</dt>
2577 <dd>Change the background color of characters after the given column
2578 position to the color set below. (This is recommended over the
2579 <em>Line</em> setting if you use proportional fonts).</dd>
2580 <dt>Disabled</dt>
2581 <dd>Don't mark long lines at all.</dd>
2582 </dl>
2583 </dd>
2584 <dt>Long line marker</dt>
2585 <dd>Set this value to a value greater than zero to specify the column
2586 where it should appear.</dd>
2587 <dt>Long line marker color</dt>
2588 <dd>Set the color of the long line marker.</dd>
2589 </dl>
2590 </div>
2591 <div class="section" id="virtual-spaces">
2592 <h4><a class="toc-backref" href="#id117">Virtual spaces</a></h4>
2593 <p>Virtual space is space beyond the end of each line.
2594 The cursor may be moved into virtual space but no real space will be
2595 added to the document until there is some text typed or some other
2596 text insertion command is used.</p>
2597 <dl class="docutils">
2598 <dt>Disabled</dt>
2599 <dd>Do not show virtual spaces</dd>
2600 <dt>Only for rectangular selections</dt>
2601 <dd>Only show virtual spaces beyond the end of lines when drawing a rectangular selection</dd>
2602 <dt>Always</dt>
2603 <dd>Always show virtual spaces beyond the end of lines</dd>
2604 </dl>
2605 </div>
2606 </div>
2607 <div class="section" id="files-preferences">
2608 <h3><a class="toc-backref" href="#id118">Files preferences</a></h3>
2609 <img alt="./images/pref_dialog_files.png" src="./images/pref_dialog_files.png" />
2610 <div class="section" id="new-files">
2611 <h4><a class="toc-backref" href="#id119">New files</a></h4>
2612 <dl class="docutils">
2613 <dt>Open new documents from the command-line</dt>
2614 <dd>Whether to create new documents when passing filenames that don't
2615 exist from the command-line.</dd>
2616 <dt>Default encoding (new files)</dt>
2617 <dd>The type of file encoding you wish to use when creating files.</dd>
2618 <dt>Used fixed encoding when opening files</dt>
2619 <dd>Assume all files you are opening are using the type of encoding specified below.</dd>
2620 <dt>Default encoding (existing files)</dt>
2621 <dd>Opens all files with the specified encoding instead of auto-detecting it.
2622 Use this option when it's not possible for Geany to detect the exact encoding.</dd>
2623 <dt>Default end of line characters</dt>
2624 <dd>The end of line characters to which should be used for new files.
2625 On Windows systems, you generally want to use CR/LF which are the common
2626 characters to mark line breaks.
2627 On Unix-like systems, LF is default and CR is used on MAC systems.</dd>
2628 </dl>
2629 </div>
2630 <div class="section" id="saving-files">
2631 <h4><a class="toc-backref" href="#id120">Saving files</a></h4>
2632 <p>Perform formatting operations when a document is saved. These
2633 can each be undone with the Undo command.</p>
2634 <dl class="docutils">
2635 <dt>Ensure newline at file end</dt>
2636 <dd>Add a newline at the end of the document if one is missing.</dd>
2637 <dt>Ensure consistent line endings</dt>
2638 <dd>Ensures that newline characters always get converted before
2639 saving, avoiding mixed line endings in the same file.</dd>
2640 </dl>
2641 <dl class="docutils" id="strip-trailing-spaces">
2642 <dt>Strip trailing spaces</dt>
2643 <dd><p class="first">Remove any whitespace at the end of each document line.</p>
2644 <div class="note last">
2645 <p class="first admonition-title">Note</p>
2646 <p class="last">This does not apply to Diff documents, e.g. patch files.</p>
2647 </div>
2648 </dd>
2649 <dt>Replace tabs by space</dt>
2650 <dd><p class="first">Replace all tabs in the document with the equivalent number of spaces.</p>
2651 <div class="note last">
2652 <p class="first admonition-title">Note</p>
2653 <p class="last">It is better to use spaces to indent than use this preference - see
2654 <a class="reference internal" href="#indentation">Indentation</a>.</p>
2655 </div>
2656 </dd>
2657 </dl>
2658 </div>
2659 <div class="section" id="id3">
2660 <h4><a class="toc-backref" href="#id121">Miscellaneous</a></h4>
2661 <dl class="docutils">
2662 <dt>Recent files list length</dt>
2663 <dd>The number of files to remember in the recently used files list.</dd>
2664 <dt>Disk check timeout</dt>
2665 <dd><p class="first">The number of seconds to periodically check the current document's
2666 file on disk in case it has changed. Setting it to 0 will disable
2667 this feature.</p>
2668 <div class="note last">
2669 <p class="first admonition-title">Note</p>
2670 <p class="last">These checks are only performed on local files. Remote files are
2671 not checked for changes due to performance issues
2672 (remote files are files in <tt class="docutils literal"><span class="pre">~/.gvfs/</span></tt>).</p>
2673 </div>
2674 </dd>
2675 </dl>
2676 </div>
2677 </div>
2678 <div class="section" id="tools-preferences">
2679 <h3><a class="toc-backref" href="#id122">Tools preferences</a></h3>
2680 <img alt="./images/pref_dialog_tools.png" src="./images/pref_dialog_tools.png" />
2681 <div class="section" id="tool-paths">
2682 <h4><a class="toc-backref" href="#id123">Tool paths</a></h4>
2683 <dl class="docutils">
2684 <dt>Terminal</dt>
2685 <dd>The command to execute a script in a terminal. Occurrences of %c
2686 in the command are substituted with the run script name, see
2687 <a class="reference internal" href="#terminal-emulators">Terminal emulators</a>.</dd>
2688 <dt>Browser</dt>
2689 <dd>The location of your web browser executable.</dd>
2690 <dt>Grep</dt>
2691 <dd>The location of the grep executable.</dd>
2692 </dl>
2693 <div class="note">
2694 <p class="first admonition-title">Note</p>
2695 <p class="last">For Windows users: at the time of writing it is recommended to use
2696 the grep.exe from the UnxUtils project
2697 (<a class="reference external" href="http://sourceforge.net/projects/unxutils">http://sourceforge.net/projects/unxutils</a>). The grep.exe from the
2698 Mingw project for instance might not work with Geany at the moment.</p>
2699 </div>
2700 </div>
2701 <div class="section" id="commands">
2702 <h4><a class="toc-backref" href="#id124">Commands</a></h4>
2703 <dl class="docutils">
2704 <dt>Context action</dt>
2705 <dd>Set this to a command to execute on the current word.
2706 You can use the &quot;%s&quot; wildcard to pass the current word below the cursor
2707 to the specified command.</dd>
2708 </dl>
2709 </div>
2710 </div>
2711 <div class="section" id="template-preferences">
2712 <h3><a class="toc-backref" href="#id125">Template preferences</a></h3>
2713 <p>This data is used as meta data for various template text to insert into
2714 a document, such as the file header. You only need to set fields that
2715 you want to use in your template files.</p>
2716 <img alt="./images/pref_dialog_templ.png" src="./images/pref_dialog_templ.png" />
2717 <div class="section" id="template-data">
2718 <h4><a class="toc-backref" href="#id126">Template data</a></h4>
2719 <dl class="docutils">
2720 <dt>Developer</dt>
2721 <dd>The name of the developer who will be creating files.</dd>
2722 <dt>Initials</dt>
2723 <dd>The initials of the developer.</dd>
2724 <dt>Mail address</dt>
2725 <dd><p class="first">The email address of the developer.</p>
2726 <div class="note last">
2727 <p class="first admonition-title">Note</p>
2728 <p class="last">You may wish to add anti-spam markup, e.g. <tt class="docutils literal">name&lt;at&gt;site&lt;dot&gt;ext</tt>.</p>
2729 </div>
2730 </dd>
2731 <dt>Company</dt>
2732 <dd>The company the developer is working for.</dd>
2733 <dt>Initial version</dt>
2734 <dd>The initial version of files you will be creating.</dd>
2735 <dt>Year</dt>
2736 <dd>Specify a format for the the {year} wildcard. You can use any conversion specifiers
2737 which can be used with the ANSI C strftime function. For details please see
2738 <a class="reference external" href="http://man.cx/strftime">http://man.cx/strftime</a>.</dd>
2739 <dt>Date</dt>
2740 <dd>Specify a format for the the {date} wildcard. You can use any conversion specifiers
2741 which can be used with the ANSI C strftime function. For details please see
2742 <a class="reference external" href="http://man.cx/strftime">http://man.cx/strftime</a>.</dd>
2743 <dt>Date &amp; Time</dt>
2744 <dd>Specify a format for the the {datetime} wildcard. You can use any conversion specifiers
2745 which can be used with the ANSI C strftime function. For details please see
2746 <a class="reference external" href="http://man.cx/strftime">http://man.cx/strftime</a>.</dd>
2747 </dl>
2748 </div>
2749 </div>
2750 <div class="section" id="keybinding-preferences">
2751 <h3><a class="toc-backref" href="#id127">Keybinding preferences</a></h3>
2752 <img alt="./images/pref_dialog_keys.png" src="./images/pref_dialog_keys.png" />
2753 <p>There are some commands listed in the keybinding dialog that are not, by default,
2754 bound to a key combination, and may not be available as a menu item.</p>
2755 <div class="note">
2756 <p class="first admonition-title">Note</p>
2757 <p class="last">For more information see the section <a class="reference internal" href="#keybindings">Keybindings</a>.</p>
2758 </div>
2759 </div>
2760 <div class="section" id="printing-preferences">
2761 <h3><a class="toc-backref" href="#id128">Printing preferences</a></h3>
2762 <img alt="./images/pref_dialog_printing.png" src="./images/pref_dialog_printing.png" />
2763 <dl class="docutils">
2764 <dt>Use external command for printing</dt>
2765 <dd>Use a system command to print your file out.</dd>
2766 <dt>Use native GTK printing</dt>
2767 <dd>Let the GTK GUI toolkit handle your print request.</dd>
2768 <dt>Print line numbers</dt>
2769 <dd>Print the line numbers on the left of your paper.</dd>
2770 <dt>Print page number</dt>
2771 <dd>Print the page number on the bottom right of your paper.</dd>
2772 <dt>Print page header</dt>
2773 <dd>Print a header on every page that is sent to the printer.</dd>
2774 <dt>Use base name of the printed file</dt>
2775 <dd>Don't use the entire path for the header, only the filename.</dd>
2776 <dt>Date format</dt>
2777 <dd>How the date should be printed. You can use the same format
2778 specifiers as in the ANSI C function strftime(). For details please
2779 see <a class="reference external" href="http://man.cx/strftime">http://man.cx/strftime</a>.</dd>
2780 </dl>
2781 </div>
2782 <div class="section" id="various-preferences">
2783 <h3><a class="toc-backref" href="#id129">Various preferences</a></h3>
2784 <img alt="./images/pref_dialog_various.png" src="./images/pref_dialog_various.png" />
2785 <p>Rarely used preferences, explained in the table below. A few of them require
2786 restart to take effect, and a few other will only affect newly opened or created
2787 documents before restart.</p>
2788 <table border="1" class="docutils">
2789 <colgroup>
2790 <col width="34%" />
2791 <col width="44%" />
2792 <col width="11%" />
2793 <col width="12%" />
2794 </colgroup>
2795 <thead valign="bottom">
2796 <tr><th class="head">Key</th>
2797 <th class="head">Description</th>
2798 <th class="head">Default</th>
2799 <th class="head">Applies</th>
2800 </tr>
2801 </thead>
2802 <tbody valign="top">
2803 <tr><td><strong>Editor related</strong></td>
2804 <td>&nbsp;</td>
2805 <td>&nbsp;</td>
2806 <td>&nbsp;</td>
2807 </tr>
2808 <tr><td>use_gtk_word_boundaries</td>
2809 <td>Whether to look for the end of a word
2810 when using word-boundary related
2811 Scintilla commands (see <a class="reference internal" href="#scintilla-keyboard-commands">Scintilla
2812 keyboard commands</a>).</td>
2813 <td>true</td>
2814 <td>to new
2815 documents</td>
2816 </tr>
2817 <tr><td>brace_match_ltgt</td>
2818 <td>Whether to highlight &lt;, &gt; angle brackets.</td>
2819 <td>false</td>
2820 <td>immediately</td>
2821 </tr>
2822 <tr><td>complete_snippets_whilst_editing</td>
2823 <td>Whether to allow completion of snippets
2824 when editing an existing line (i.e. there
2825 is some text after the current cursor
2826 position on the line). Only used when the
2827 keybinding <cite>Complete snippet</cite> is set to
2828 <tt class="docutils literal">Space</tt>.</td>
2829 <td>false</td>
2830 <td>immediately</td>
2831 </tr>
2832 <tr><td>show_editor_scrollbars</td>
2833 <td>Whether to display scrollbars. If set to
2834 false, the horizontal and vertical
2835 scrollbars are hidden completely.</td>
2836 <td>true</td>
2837 <td>immediately</td>
2838 </tr>
2839 <tr><td>indent_hard_tab_width</td>
2840 <td>The size of a tab character. Don't change
2841 it unless you really need to; use the
2842 indentation settings instead.</td>
2843 <td>8</td>
2844 <td>immediately</td>
2845 </tr>
2846 <tr><td><strong>Interface related</strong></td>
2847 <td>&nbsp;</td>
2848 <td>&nbsp;</td>
2849 <td>&nbsp;</td>
2850 </tr>
2851 <tr><td>show_symbol_list_expanders</td>
2852 <td>Whether to show or hide the small
2853 expander icons on the symbol list
2854 treeview.</td>
2855 <td>true</td>
2856 <td>to new
2857 documents</td>
2858 </tr>
2859 <tr><td>allow_always_save</td>
2860 <td>Whether files can be saved always, even
2861 if they don't have any changes.
2862 By default, the Save button and menu
2863 item are disabled when a file is
2864 unchanged. When setting this option to
2865 true, the Save button and menu item are
2866 always active and files can be saved.</td>
2867 <td>false</td>
2868 <td>immediately</td>
2869 </tr>
2870 <tr><td>compiler_tab_autoscroll</td>
2871 <td>Whether to automatically scroll to the
2872 last line of the output in the Compiler
2873 tab.</td>
2874 <td>true</td>
2875 <td>immediately</td>
2876 </tr>
2877 <tr><td>statusbar_template</td>
2878 <td>The status bar statistics line format.
2879 (Search in src/ui_utils.c for details).</td>
2880 <td>See below.</td>
2881 <td>immediately</td>
2882 </tr>
2883 <tr><td>new_document_after_close</td>
2884 <td>Whether to open a new document after all
2885 documents have been closed.</td>
2886 <td>false</td>
2887 <td>immediately</td>
2888 </tr>
2889 <tr><td>msgwin_status_visible</td>
2890 <td>Whether to show the Status tab in the
2891 Messages Window</td>
2892 <td>true</td>
2893 <td>immediately</td>
2894 </tr>
2895 <tr><td>msgwin_compiler_visible</td>
2896 <td>Whether to show the Compiler tab in the
2897 Messages Window</td>
2898 <td>true</td>
2899 <td>immediately</td>
2900 </tr>
2901 <tr><td>msgwin_messages_visible</td>
2902 <td>Whether to show the Messages tab in the
2903 Messages Window</td>
2904 <td>true</td>
2905 <td>immediately</td>
2906 </tr>
2907 <tr><td>msgwin_scribble_visible</td>
2908 <td>Whether to show the Scribble tab in the
2909 Messages Window</td>
2910 <td>true</td>
2911 <td>immediately</td>
2912 </tr>
2913 </tbody>
2914 </table>
2915 <p>By default, statusbar_template is empty. This tells Geany to use its
2916 internal default, which is currently:</p>
2917 <p><tt class="docutils literal">line: %l / %L\t col: %c\t sel: %s\t %w&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; %t&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; %mmode: %M&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; encoding: %e&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; filetype: %f&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; scope: %S</tt></p>
2918 <p>Note that <tt class="docutils literal">\t</tt> = tab.</p>
2919 <table border="1" class="docutils">
2920 <colgroup>
2921 <col width="33%" />
2922 <col width="45%" />
2923 <col width="10%" />
2924 <col width="11%" />
2925 </colgroup>
2926 <thead valign="bottom">
2927 <tr><th class="head">Key</th>
2928 <th class="head">Description</th>
2929 <th class="head">Default</th>
2930 <th class="head">Applies</th>
2931 </tr>
2932 </thead>
2933 <tbody valign="top">
2934 <tr><td><strong>VTE related</strong></td>
2935 <td>&nbsp;</td>
2936 <td>&nbsp;</td>
2937 <td>&nbsp;</td>
2938 </tr>
2939 <tr><td>emulation</td>
2940 <td>Terminal emulation mode. Only change this
2941 if you have VTE termcap files other than
2942 <tt class="docutils literal">vte/termcap/xterm</tt>.</td>
2943 <td>xterm</td>
2944 <td>immediately</td>
2945 </tr>
2946 <tr><td>send_selection_unsafe</td>
2947 <td>By default, Geany strips any trailing
2948 newline characters from the current
2949 selection before sending it to the terminal
2950 to not execute arbitrary code. This is
2951 mainly a security feature.
2952 If, for whatever reasons, you really want
2953 it to be executed directly, set this option
2954 to true.</td>
2955 <td>false</td>
2956 <td>immediately</td>
2957 </tr>
2958 <tr><td>send_cmd_prefix</td>
2959 <td>String with which prefix the commands sent
2960 to the shell. This may be used to tell
2961 some shells (BASH with <tt class="docutils literal">HISTCONTROL</tt> set
2962 to <tt class="docutils literal">ignorespace</tt>, ZSH with
2963 <tt class="docutils literal">HIST_IGNORE_SPACE</tt> enabled, etc.) from
2964 putting these commands in their history by
2965 setting this to a space. Note that leading
2966 spaces must be escaped using <cite>s</cite> in the
2967 configuration file.</td>
2968 <td>Empty</td>
2969 <td>immediately</td>
2970 </tr>
2971 <tr><td><strong>File related</strong></td>
2972 <td>&nbsp;</td>
2973 <td>&nbsp;</td>
2974 <td>&nbsp;</td>
2975 </tr>
2976 <tr><td>use_atomic_file_saving</td>
2977 <td>Defines the mode how Geany saves files to
2978 disk. If disabled, Geany directly writes
2979 the content of the document to disk. This
2980 might cause loss of data when there is
2981 no more free space on disk to save the
2982 file. When set to true, Geany first saves
2983 the contents into a temporary file and if
2984 this succeeded, the temporary file is
2985 moved to the real file to save.
2986 This gives better error checking in case of
2987 no more free disk space. But it also
2988 destroys hard links of the original file
2989 and its permissions (e.g. executable flags
2990 are reset). Use this with care as it can
2991 break things seriously.
2992 The better approach would be to ensure your
2993 disk won't run out of free space.</td>
2994 <td>false</td>
2995 <td>immediately</td>
2996 </tr>
2997 <tr><td>use_gio_unsafe_file_saving</td>
2998 <td>Whether to use GIO as the unsafe file
2999 saving backend. It is better on most
3000 situations but is known not to work
3001 correctly on some complex setups.</td>
3002 <td>true</td>
3003 <td>immediately</td>
3004 </tr>
3005 <tr><td>gio_unsafe_save_backup</td>
3006 <td>Make a backup when using GIO unsafe file
3007 saving. Backup is named <cite>filename~</cite>.</td>
3008 <td>false</td>
3009 <td>immediately</td>
3010 </tr>
3011 <tr><td><strong>Filetype related</strong></td>
3012 <td>&nbsp;</td>
3013 <td>&nbsp;</td>
3014 <td>&nbsp;</td>
3015 </tr>
3016 <tr><td>extract_filetype_regex</td>
3017 <td>Regex to extract filetype name from file
3018 via capture group one.</td>
3019 <td>See below.</td>
3020 <td>immediately</td>
3021 </tr>
3022 <tr><td><strong>Search related</strong></td>
3023 <td>&nbsp;</td>
3024 <td>&nbsp;</td>
3025 <td>&nbsp;</td>
3026 </tr>
3027 <tr><td>find_selection_type</td>
3028 <td>See <a class="reference internal" href="#find-selection">Find selection</a>.</td>
3029 <td>0</td>
3030 <td>immediately</td>
3031 </tr>
3032 <tr><td><strong>Build Menu related</strong></td>
3033 <td>&nbsp;</td>
3034 <td>&nbsp;</td>
3035 <td>&nbsp;</td>
3036 </tr>
3037 <tr><td>number_ft_menu_items</td>
3038 <td>The maximum number of menu items in the
3039 filetype section of the Build menu.</td>
3040 <td>2</td>
3041 <td>on restart</td>
3042 </tr>
3043 <tr><td>number_non_ft_menu_items</td>
3044 <td>The maximum number of menu items in the
3045 independent section of the Build menu.</td>
3046 <td>3</td>
3047 <td>on restart</td>
3048 </tr>
3049 <tr><td>number_exec_menu_items</td>
3050 <td>The maximum number of menu items in the
3051 execute section of the Build menu.</td>
3052 <td>2</td>
3053 <td>on restart</td>
3054 </tr>
3055 </tbody>
3056 </table>
3057 <p>The extract_filetype_regex has the default value GEANY_DEFAULT_FILETYPE_REGEX.</p>
3058 </div>
3059 <div class="section" id="terminal-vte-preferences">
3060 <h3><a class="toc-backref" href="#id130">Terminal (VTE) preferences</a></h3>
3061 <p>See also: <a class="reference internal" href="#virtual-terminal-emulator-widget-vte">Virtual terminal emulator widget (VTE)</a>.</p>
3062 <img alt="./images/pref_dialog_vte.png" src="./images/pref_dialog_vte.png" />
3063 <div class="section" id="terminal-widget">
3064 <h4><a class="toc-backref" href="#id131">Terminal widget</a></h4>
3065 <dl class="docutils">
3066 <dt>Terminal font</dt>
3067 <dd>Select the font that will be used in the terminal emulation control.</dd>
3068 <dt>Foreground color</dt>
3069 <dd>Select the font color.</dd>
3070 <dt>Background color</dt>
3071 <dd>Select the background color of the terminal.</dd>
3072 <dt>Background image</dt>
3073 <dd>Select the background image to show behind the terminal's text.</dd>
3074 <dt>Scrollback lines</dt>
3075 <dd>The number of lines buffered so that you can scroll though the history.</dd>
3076 <dt>Shell</dt>
3077 <dd>The location of the shell on your system.</dd>
3078 <dt>Scroll on keystroke</dt>
3079 <dd>Scroll the terminal to the prompt line when pressing a key.</dd>
3080 <dt>Scroll on output</dt>
3081 <dd>Scroll the output down.</dd>
3082 <dt>Cursor blinks</dt>
3083 <dd>Let the terminal cursor blink.</dd>
3084 <dt>Override Geany keybindings</dt>
3085 <dd>Allow the VTE to receive keyboard shortcuts (apart from focus commands).</dd>
3086 <dt>Disable menu shortcut key (F10 by default)</dt>
3087 <dd>Disable the menu shortcut when you are in the virtual terminal.</dd>
3088 <dt>Follow path of the current file</dt>
3089 <dd>Make the path of the terminal change according to the path of the
3090 current file.</dd>
3091 <dt>Execute programs in VTE</dt>
3092 <dd>Execute programs in the virtual terminal instead of using the external
3093 terminal tool. Note that if you run multiple execute commands at once
3094 the output may become mixed together in the VTE.</dd>
3095 <dt>Don't use run script</dt>
3096 <dd>Don't use the simple run script which is usually used to display
3097 the exit status of the executed program.
3098 This can be useful if you already have a program running in the VTE
3099 like a Python console (e.g. ipython). Use this with care.</dd>
3100 </dl>
3101 </div>
3102 </div>
3103 </div>
3104 <div class="section" id="project-management">
3105 <h2><a class="toc-backref" href="#id132">Project management</a></h2>
3106 <p>Project management is optional in Geany. Currently it can be used for:</p>
3107 <ul class="simple">
3108 <li>Storing and opening session files on a project basis.</li>
3109 <li>Overriding default settings with project equivalents.</li>
3110 <li>Configuring the Build menu on a project basis.</li>
3111 </ul>
3112 <p>A list of session files can be stored and opened with the project
3113 when the <em>Use project-based session files</em> preference is enabled,
3114 in the <em>Project</em> group of the <a class="reference internal" href="#preferences">Preferences</a> dialog.</p>
3115 <p>As long as a project is open, the Build menu will use
3116 the items defined in project's settings, instead of the defaults.
3117 See <a class="reference internal" href="#build-menu-configuration">Build Menu Configuration</a> for information on configuring the menu.</p>
3118 <p>The current project's settings are saved when it is closed, or when
3119 Geany is shutdown. When restarting Geany, the previously opened project
3120 file that was in use at the end of the last session will be reopened.</p>
3121 <p>The project menu items are detailed below.</p>
3122 <div class="section" id="new-project">
3123 <h3><a class="toc-backref" href="#id133">New project</a></h3>
3124 <p>To create a new project, fill in the <em>Name</em> field. By default this
3125 will setup a new project file <tt class="docutils literal">~/projects/name.geany</tt>. Usually it's
3126 best to store all your project files in the same directory (they are
3127 independent of any source directory trees).</p>
3128 <p>The Base path text field is setup to use <tt class="docutils literal">~/projects/name</tt>. This
3129 can safely be set to any existing path -- it will not touch the file
3130 structure contained in it.</p>
3131 </div>
3132 <div class="section" id="project-properties">
3133 <h3><a class="toc-backref" href="#id134">Project properties</a></h3>
3134 <p>You can set an optional description for the project. Currently it's
3135 only used for a template wildcard - see <a class="reference internal" href="#template-wildcards">Template wildcards</a>.</p>
3136 <p>The <em>Base path</em> field is used as the directory to run the Build menu commands.
3137 The specified path can be an absolute path or it is considered to be
3138 relative to the project's file name.</p>
3139 <p>The <em>File patterns</em> field allows to specify a list of file patterns for the
3140 project, which can be used in the <a class="reference internal" href="#find-in-files">Find in files</a> dialog.</p>
3141 <p>The <em>Indentation</em> tab allows you to override the default
3142 <a class="reference internal" href="#indentation">Indentation</a> settings.</p>
3143 </div>
3144 <div class="section" id="open-project">
3145 <h3><a class="toc-backref" href="#id135">Open project</a></h3>
3146 <p>The Open command displays a standard file chooser, starting in
3147 <tt class="docutils literal">~/projects</tt>. Choose a project file named with the <tt class="docutils literal">.geany</tt>
3148 extension.</p>
3149 <p>When project session support is enabled, Geany will close the currently
3150 open files and open the session files associated with the project.</p>
3151 </div>
3152 <div class="section" id="close-project">
3153 <h3><a class="toc-backref" href="#id136">Close project</a></h3>
3154 <p>Project file settings are saved when the project is closed.</p>
3155 <p>When project session support is enabled, Geany will close the project
3156 session files and open any previously closed default session files.</p>
3157 </div>
3158 </div>
3159 <div class="section" id="build-menu">
3160 <h2><a class="toc-backref" href="#id137">Build menu</a></h2>
3161 <p>After editing code with Geany, the next step is to compile, link, build,
3162 interpret, run etc. As Geany supports many languages each with a different
3163 approach to such operations, and as there are also many language independent
3164 software building systems, Geany does not have a built-in build system, nor
3165 does it limit which system you can use. Instead the build menu provides
3166 a configurable and flexible means of running any external commands to
3167 execute your preferred build system.</p>
3168 <p>This section provides a description of the default configuration of the
3169 build menu and then covers how to configure it, and where the defaults fit in.</p>
3170 <p>Running the commands from within Geany has two benefits:</p>
3171 <ul class="simple">
3172 <li>The current file is automatically saved before the command is run.</li>
3173 <li>The output is captured in the Compiler notebook tab and parsed for
3174 warnings or errors.</li>
3175 </ul>
3176 <p>Warnings and errors that can be parsed for line numbers will be shown in
3177 red in the Compiler tab and you can click on them to switch to the relevant
3178 source file (or open it) and mark the line number. Also lines with
3179 warnings or errors are marked in the source, see <a class="reference internal" href="#indicators">Indicators</a> below.</p>
3180 <div class="tip">
3181 <p class="first admonition-title">Tip</p>
3182 <p class="last">If Geany's default error message parsing does not parse errors for
3183 the tool you're using, you can set a custom regex in the Build Commands
3184 Dialog, see <a class="reference internal" href="#build-menu-configuration">Build Menu Configuration</a>.</p>
3185 </div>
3186 <div class="section" id="indicators">
3187 <h3><a class="toc-backref" href="#id138">Indicators</a></h3>
3188 <p>Indicators are red squiggly underlines which are used to highlight
3189 errors which occurred while compiling the current file. So you can
3190 easily see where your code failed to compile. You can remove them by
3191 selecting <em>Remove Error Indicators</em> in the Document menu.</p>
3192 <p>If you do not like this feature, you can disable it - see <a class="reference internal" href="#editor-features-preferences">Editor Features
3193 preferences</a>.</p>
3194 </div>
3195 <div class="section" id="default-build-menu-items">
3196 <h3><a class="toc-backref" href="#id139">Default build menu items</a></h3>
3197 <p>Depending on the current file's filetype, the default Build menu will contain
3198 the following items:</p>
3199 <ul class="simple">
3200 <li>Compile</li>
3201 <li>Build</li>
3202 <li>Make All</li>
3203 <li>Make Custom Target</li>
3204 <li>Make Object</li>
3205 <li>Next Error</li>
3206 <li>Previous Error</li>
3207 <li>Execute</li>
3208 <li>Set Build Menu Commands</li>
3209 </ul>
3210 <div class="section" id="compile">
3211 <h4><a class="toc-backref" href="#id140">Compile</a></h4>
3212 <p>The Compile command has different uses for different kinds of files.</p>
3213 <p>For compilable languages such as C and C++, the Compile command is
3214 set up to compile the current source file into a binary object file.</p>
3215 <p>Java source files will be compiled to class file bytecode.</p>
3216 <p>Interpreted languages such as Perl, Python, Ruby will compile to
3217 bytecode if the language supports it, or will run a syntax check,
3218 or if that is not available will run the file in its language interpreter.</p>
3219 </div>
3220 <div class="section" id="build">
3221 <h4><a class="toc-backref" href="#id141">Build</a></h4>
3222 <p>For compilable languages such as C and C++, the Build command will link
3223 the current source file's equivalent object file into an executable. If
3224 the object file does not exist, the source will be compiled and linked
3225 in one step, producing just the executable binary.</p>
3226 <p>Interpreted languages do not use the Build command.</p>
3227 <div class="note">
3228 <p class="first admonition-title">Note</p>
3229 <p class="last">If you need complex settings for your build system, or several
3230 different settings, then writing a Makefile and using the Make
3231 commands is recommended; this will also make it easier for users to
3232 build your software.</p>
3233 </div>
3234 </div>
3235 <div class="section" id="make">
3236 <h4><a class="toc-backref" href="#id142">Make</a></h4>
3237 <p>This runs &quot;make&quot; in the same directory as the
3238 current file.</p>
3239 </div>
3240 <div class="section" id="make-custom-target">
3241 <h4><a class="toc-backref" href="#id143">Make custom target</a></h4>
3242 <p>This is similar to running 'Make' but you will be prompted for
3243 the make target name to be passed to the Make tool. For example,
3244 typing 'clean' in the dialog prompt will run &quot;make clean&quot;.</p>
3245 </div>
3246 <div class="section" id="make-object">
3247 <h4><a class="toc-backref" href="#id144">Make object</a></h4>
3248 <p>Make object will run &quot;make current_file.o&quot; in the same directory as
3249 the current file, using the filename for 'current_file'. It is useful
3250 for building just the current file without building the whole project.</p>
3251 </div>
3252 <div class="section" id="next-error">
3253 <h4><a class="toc-backref" href="#id145">Next error</a></h4>
3254 <p>The next error item will move to the next detected error in the file.</p>
3255 </div>
3256 <div class="section" id="previous-error">
3257 <h4><a class="toc-backref" href="#id146">Previous error</a></h4>
3258 <p>The previous error item will move to the previous detected error in the file.</p>
3259 </div>
3260 <div class="section" id="execute">
3261 <h4><a class="toc-backref" href="#id147">Execute</a></h4>
3262 <p>Execute will run the corresponding executable file, shell script or
3263 interpreted script in a terminal window. The command set in the
3264 &quot;Set Build Commands&quot; dialog is run in a script to ensure the terminal
3265 stays open after execution completes. Note: see <a class="reference internal" href="#terminal-emulators">Terminal emulators</a>
3266 below for the command format. Alternatively the built-in VTE can be used
3267 if it is available - see <a class="reference internal" href="#virtual-terminal-emulator-widget-vte">Virtual terminal emulator widget (VTE)</a>.</p>
3268 <p>After your program or script has finished executing, the run script will
3269 prompt you to press the return key. This allows you to review any text
3270 output from the program before the terminal window is closed.</p>
3271 <div class="note">
3272 <p class="first admonition-title">Note</p>
3273 <p class="last">The execute command output is not parsed for errors.</p>
3274 </div>
3275 </div>
3276 <div class="section" id="stopping-running-processes">
3277 <h4><a class="toc-backref" href="#id148">Stopping running processes</a></h4>
3278 <p>When there is a running program, the Execute menu item in the menu and
3279 the Run button in the toolbar
3280 each become a stop button so you can stop the current running program (and
3281 any child processes). This works by sending the SIGQUIT signal to the process.</p>
3282 <p>Depending on the process you started it is possible that the process
3283 cannot be stopped. For example this can happen when the process creates
3284 more than one child process.</p>
3285 <div class="section" id="terminal-emulators">
3286 <h5><a class="toc-backref" href="#id149">Terminal emulators</a></h5>
3287 <p>The Terminal field of the tools preferences tab requires a command to
3288 execute the terminal program and to pass it the name of the Geany run
3289 script that it should execute in a Bourne compatible shell (eg /bin/sh).
3290 The marker &quot;%c&quot; is substituted with the name of the Geany run script,
3291 which is created in the working directory set in the Build commands
3292 dialog, see <a class="reference internal" href="#build-menu-commands-dialog">Build menu commands dialog</a> for details.</p>
3293 <p>As an example the default (Linux) command is:</p>
3294 <pre class="literal-block">
3295 xterm -e &quot;/bin/sh %c&quot;
3296 </pre>
3297 </div>
3298 </div>
3299 <div class="section" id="set-build-commands">
3300 <h4><a class="toc-backref" href="#id150">Set build commands</a></h4>
3301 <p>By default Compile, Build and Execute are fairly basic commands. You
3302 may wish to customise them using <em>Set Build Commands</em>.</p>
3303 <p>E.g. for C you can add any include paths and compile flags for the
3304 compiler, any library names and paths for the linker, and any
3305 arguments you want to use when running Execute.</p>
3306 </div>
3307 </div>
3308 <div class="section" id="build-menu-configuration">
3309 <h3><a class="toc-backref" href="#id151">Build menu configuration</a></h3>
3310 <p>The build menu has considerable flexibility and configurability, allowing
3311 both menu labels the commands they execute and the directory they execute
3312 in to be configured.</p>
3313 <p>For example, if you change one of the default make commands to run say 'waf'
3314 you can also change the label to match.</p>
3315 <p>These settings are saved automatically when Geany is shut down.</p>
3316 <p>The build menu is divided into four groups of items each with different
3317 behaviors:</p>
3318 <ul class="simple">
3319 <li>Filetype build commands - are configurable and depend on the filetype of the
3320 current document; they capture output in the compiler tab and parse it for
3321 errors.</li>
3322 <li>Independent build commands - are configurable and mostly don't depend on the
3323 filetype of the current document; they also capture output in the
3324 compiler tab and parse it for errors.</li>
3325 <li>Execute commands - are configurable and intended for executing your
3326 program or other long running programs. The output is not parsed for errors
3327 and is directed to the terminal command selected in preferences.</li>
3328 <li>Fixed commands - these perform built-in actions:<ul>
3329 <li>Go to the next error.</li>
3330 <li>Go to the previous error.</li>
3331 <li>Show the build menu commands dialog.</li>
3332 </ul>
3333 </li>
3334 </ul>
3335 <p>The maximum numbers of items in each of the configurable groups can be
3336 configured in the <a class="reference internal" href="#various-preferences">Various preferences</a>. Even though the maximum number of
3337 items may have been increased, only those menu items that have values
3338 configured are shown in the menu.</p>
3339 <p>The groups of menu items obtain their configuration from four potential
3340 sources. The highest priority source that has the menu item defined will
3341 be used. The sources in decreasing priority are:</p>
3342 <ul class="simple">
3343 <li>A project file if open</li>
3344 <li>The user preferences</li>
3345 <li>The system filetype definitions</li>
3346 <li>The defaults</li>
3347 </ul>
3348 <p>The detailed relationships between sources and the configurable menu item groups
3349 is shown in the following table.</p>
3350 <table border="1" class="docutils">
3351 <colgroup>
3352 <col width="13%" />
3353 <col width="19%" />
3354 <col width="23%" />
3355 <col width="17%" />
3356 <col width="28%" />
3357 </colgroup>
3358 <thead valign="bottom">
3359 <tr><th class="head">Group</th>
3360 <th class="head">Project File</th>
3361 <th class="head">Preferences</th>
3362 <th class="head">System Filetype</th>
3363 <th class="head">Defaults</th>
3364 </tr>
3365 </thead>
3366 <tbody valign="top">
3367 <tr><td>Filetype</td>
3368 <td><p class="first">Loads From: project
3369 file</p>
3370 <p class="last">Saves To: project
3371 file</p>
3372 </td>
3373 <td><p class="first">Loads From:
3374 filetypes.xxx file in
3375 ~/.config/geany/filedefs</p>
3376 <p class="last">Saves to: as above,
3377 creating if needed.</p>
3378 </td>
3379 <td><p class="first">Loads From:
3380 filetypes.xxx in
3381 Geany install</p>
3382 <p class="last">Saves to: as user
3383 preferences left.</p>
3384 </td>
3385 <td>None</td>
3386 </tr>
3387 <tr><td>Filetype
3388 Independent</td>
3389 <td><p class="first">Loads From: project
3390 file</p>
3391 <p class="last">Saves To: project
3392 file</p>
3393 </td>
3394 <td><p class="first">Loads From:
3395 geany.conf file in
3396 ~/.config/geany</p>
3397 <p class="last">Saves to: as above,
3398 creating if needed.</p>
3399 </td>
3400 <td><p class="first">Loads From:
3401 filetypes.xxx in
3402 Geany install</p>
3403 <p class="last">Saves to: as user
3404 preferences left.</p>
3405 </td>
3406 <td><dl class="first last docutils">
3407 <dt>1:</dt>
3408 <dd>Label: _Make
3409 Command: make</dd>
3410 <dt>2:</dt>
3411 <dd>Label: Make Custom _Target
3412 Command: make</dd>
3413 <dt>3:</dt>
3414 <dd>Label: Make _Object
3415 Command: make %e.o</dd>
3416 </dl>
3417 </td>
3418 </tr>
3419 <tr><td>Execute</td>
3420 <td><p class="first">Loads From: project
3421 file or else
3422 filetype defined in
3423 project file</p>
3424 <p class="last">Saves To:
3425 project file</p>
3426 </td>
3427 <td><p class="first">Loads From:
3428 geany.conf file in
3429 ~/.config/geany or else
3430 filetypes.xxx file in
3431 ~/.config/geany/filedefs</p>
3432 <p class="last">Saves To:
3433 filetypes.xxx file in
3434 ~/.config/geany/filedefs</p>
3435 </td>
3436 <td><p class="first">Loads From:
3437 filetypes.xxx in
3438 Geany install</p>
3439 <p class="last">Saves To: as user
3440 preferences left.</p>
3441 </td>
3442 <td>Label: _Execute
3443 Command: ./%e</td>
3444 </tr>
3445 </tbody>
3446 </table>
3447 <p>The following notes on the table reference cells by coordinate as (group,source):</p>
3448 <ul class="simple">
3449 <li>General - for filetypes.xxx substitute the appropriate extension for
3450 the filetype of the current document for xxx - see <a class="reference internal" href="#filenames">filenames</a>.</li>
3451 <li>System Filetypes - Labels loaded from these sources are locale sensitive
3452 and can contain translations.</li>
3453 <li>(Filetype, Project File) and (Filetype, Preferences) - preferences use a full
3454 filetype file so that users can configure all other filetype preferences
3455 as well. Projects can only configure menu items per filetype. Saving
3456 in the project file means that there is only one file per project not
3457 a whole directory.</li>
3458 <li>(Filetype-Independent, System Filetype) - although conceptually strange, defining
3459 filetype-independent commands in a filetype file, this provides the ability to
3460 define filetype dependent default menu items.</li>
3461 <li>(Execute, Project File) and (Execute, Preferences) - the project independent
3462 execute and preferences independent execute commands can only be set by hand
3463 editing the appropriate file, see <a class="reference internal" href="#preferences-file-format">Preferences file format</a> and <a class="reference internal" href="#project-file-format">Project file
3464 format</a>.</li>
3465 </ul>
3466 </div>
3467 <div class="section" id="build-menu-commands-dialog">
3468 <h3><a class="toc-backref" href="#id152">Build menu commands dialog</a></h3>
3469 <p>Most of the configuration of the build menu is done through the Build Menu
3470 Commands Dialog. You edit the configuration sourced from preferences in the
3471 dialog opened from the Build-&gt;Build Menu Commands item and you edit the
3472 configuration from the project in the build tab of the project preferences
3473 dialog. Both use the same form shown below.</p>
3474 <img alt="./images/build_menu_commands_dialog.png" src="./images/build_menu_commands_dialog.png" />
3475 <p>The dialog is divided into three sections:</p>
3476 <ul class="simple">
3477 <li>Filetype build commands (selected based on the current document's filetype).</li>
3478 <li>Independent build commands (available regardless of filetype).</li>
3479 <li>Filetype execute commands.</li>
3480 </ul>
3481 <p>The filetype and independent sections also each contain a field for the regular
3482 expression used for parsing command output for error and warning messages.</p>
3483 <p>The columns in the first three sections allow setting of the label, command,
3484 and working directory to run the command in.</p>
3485 <p>An item with an empty label will not be shown in the menu.</p>
3486 <p>An empty working directory will default to the directory of the current document.
3487 If there is no current document then the command will not run.</p>
3488 <p>The dialog will always show the command selected by priority, not just the
3489 commands configured in this configuration source. This ensures that you always
3490 see what the menu item is going to do if activated.</p>
3491 <p>If the current source of the menu item is higher priority than the
3492 configuration source you are editing then the command will be shown
3493 in the dialog but will be insensitive (greyed out). This can't happen
3494 with the project source but can with the preferences source dialog.</p>
3495 <p>The clear buttons remove the definition from the configuration source you are editing.
3496 When you do this the command from the next lower priority source will be shown.
3497 To hide lower priority menu items without having anything show in the menu
3498 configure with a nothing in the label but at least one character in the command.</p>
3499 <div class="section" id="substitutions-in-commands-and-working-directories">
3500 <h4><a class="toc-backref" href="#id153">Substitutions in commands and working directories</a></h4>
3501 <p>The first occurence of each of the following character sequences in each of the
3502 command and working directory fields is substituted by the items specified below
3503 before the command is run.</p>
3504 <ul class="simple">
3505 <li>%d - substituted by the absolute path to the directory of the current file.</li>
3506 <li>%e - substituted by the name of the current file without the extension or path.</li>
3507 <li>%f - substituted by the name of the current file without the path.</li>
3508 <li>%p - if a project is open, substituted by the base path from the project.</li>
3509 </ul>
3510 <div class="note">
3511 <p class="first admonition-title">Note</p>
3512 <p class="last">If the basepath set in the project preferences is not an absolute path , then it is
3513 taken as relative to the directory of the project file. This allows a project file
3514 stored in the source tree to specify all commands and working directories relative
3515 to the tree itself, so that the whole tree including the project file, can be moved
3516 and even checked into and out of version control without having to re-configure the
3517 build menu.</p>
3518 </div>
3519 </div>
3520 <div class="section" id="build-menu-keyboard-shortcuts">
3521 <h4><a class="toc-backref" href="#id154">Build menu keyboard shortcuts</a></h4>
3522 <p>Keyboard shortcuts can be defined for the first two filetype menu items, the first three
3523 independent menu items, the first two execute menu items and the fixed menu items.
3524 In the keybindings configuration dialog (see <a class="reference internal" href="#keybinding-preferences">Keybinding preferences</a>)
3525 these items are identified by the default labels shown in the <a class="reference internal" href="#build-menu">Build Menu</a> section above.</p>
3526 <p>It is currently not possible to bind keyboard shortcuts to more than these menu items.</p>
3527 <p>You can also use underlines in the labels to set mnemonic characters.</p>
3528 </div>
3529 <div class="section" id="old-settings">
3530 <h4><a class="toc-backref" href="#id155">Old settings</a></h4>
3531 <p>The configurable Build Menu capability was introduced in Geany 0.19 and
3532 required a new section to be added to the configuration files (See
3533 <a class="reference internal" href="#preferences-file-format">Preferences file format</a>). Geany will still load older format project,
3534 preferences and filetype file settings and will attempt to map them into the new
3535 configuration format. There is not a simple clean mapping between the formats.
3536 The mapping used produces the most sensible results for the majority of cases.
3537 However, if they do not map the way you want, you may have to manually
3538 configure some settings using the Build Commands
3539 Dialog or the Build tab of the project preferences dialog.</p>
3540 <p>Any setting configured in either of these dialogs will override settings mapped from
3541 older format configuration files.</p>
3542 </div>
3543 </div>
3544 </div>
3545 <div class="section" id="printing-support">
3546 <h2><a class="toc-backref" href="#id156">Printing support</a></h2>
3547 <p>Since Geany 0.13 there has been printing support using GTK's printing API.
3548 The printed page(s) will look nearly the same as on your screen in Geany.
3549 Additionally, there are some options to modify the printed page(s).</p>
3550 <div class="note">
3551 <p class="first admonition-title">Note</p>
3552 <p class="last">The background text color is set to white, except for text with
3553 a white foreground. This allows dark color schemes to save ink
3554 when printing.</p>
3555 </div>
3556 <p>You can define whether to print line numbers, page numbers at the bottom of
3557 each page and whether to print a page header on each page. This header
3558 contains the filename of the printed document, the current page number and
3559 the date and time of printing. By default, the file name of the document
3560 with full path information is added to the header. If you prefer to add
3561 only the basename of the file(without any path information) you can set it
3562 in the preferences dialog. You can also adjust the format of the date and
3563 time added to the page header. The available conversion specifiers are the
3564 same as the ones which can be used with the ANSI C strftime function.</p>
3565 <p>All of these settings can also be changed in the print dialog just before
3566 actual printing is done.
3567 On Unix-like systems the provided print dialog offers a print preview. The
3568 preview file is opened with a PDF viewer and by default GTK uses <tt class="docutils literal">evince</tt>
3569 for print preview. If you have not installed evince or just want to use
3570 another PDF viewer, you can change the program to use in the file
3571 <tt class="docutils literal"><span class="pre">.gtkrc-2.0</span></tt> (usually found in your home directory). Simply add a line
3572 like:</p>
3573 <pre class="literal-block">
3574 gtk-print-preview-command = &quot;epdfview %f&quot;
3575 </pre>
3576 <p>at the end of the file. Of course, you can also use xpdf, kpdf or whatever
3577 as the print preview command.</p>
3578 <p>Geany also provides an alternative basic printing support using a custom
3579 print command. However, the printed document contains no syntax highlighting.
3580 You can adjust the command to which the filename is passed in the preferences
3581 dialog. The default command is:</p>
3582 <pre class="literal-block">
3583 % lpr %f
3584 </pre>
3585 <p><tt class="docutils literal">%f</tt> will be substituted by the filename of the current file. Geany
3586 will not show errors from the command itself, so you should make
3587 sure that it works before(e.g. by trying to execute it from the
3588 command line).</p>
3589 <p>A nicer example, which many prefer is:</p>
3590 <pre class="literal-block">
3591 % a2ps -1 --medium=A4 -o - %f | xfprint4
3592 </pre>
3593 <p>But this depends on a2ps and xfprint4. As a replacement for xfprint4,
3594 gtklp or similar programs can be used.</p>
3595 </div>
3596 <div class="section" id="plugins">
3597 <h2><a class="toc-backref" href="#id157">Plugins</a></h2>
3598 <p>Plugins are loaded at startup, if the <em>Enable plugin support</em>
3599 general preference is set. There is also a command-line option,
3600 <tt class="docutils literal"><span class="pre">-p</span></tt>, which prevents plugins being loaded. Plugins are scanned in
3601 the following directories:</p>
3602 <ul class="simple">
3603 <li><tt class="docutils literal">$prefix/lib/geany</tt> on Unix-like systems (see <a class="reference internal" href="#installation-prefix">Installation prefix</a>)</li>
3604 <li>The <tt class="docutils literal">lib</tt> subfolder of the installation path on Windows.</li>
3605 <li>The <tt class="docutils literal">plugins</tt> subfolder of the user configuration directory - see
3606 <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>.</li>
3607 <li>The <cite>Extra plugin path</cite> preference (usually blank) - see <a class="reference internal" href="#paths">Paths</a>.</li>
3608 </ul>
3609 <p>Most plugins add menu items to the <em>Tools</em> menu when they are loaded.</p>
3610 <p>See also <a class="reference internal" href="#plugin-documentation">Plugin documentation</a> for information about single plugins
3611 which are included in Geany.</p>
3612 <div class="section" id="plugin-manager">
3613 <h3><a class="toc-backref" href="#id158">Plugin manager</a></h3>
3614 <p>The Plugin Manager dialog lets you choose which plugins
3615 should be loaded at startup. You can also load and unload plugins on the
3616 fly using this dialog. Once you click the checkbox for a specific plugin
3617 in the dialog, it is loaded or unloaded according to its previous state.
3618 By default, no plugins are loaded at startup until you select some.
3619 You can also configure some plugin specific options if the plugin
3620 provides any.</p>
3621 </div>
3622 </div>
3623 <div class="section" id="keybindings">
3624 <h2><a class="toc-backref" href="#id159">Keybindings</a></h2>
3625 <p>Geany supports the default keyboard shortcuts for the Scintilla
3626 editing widget. For a list of these commands, see <a class="reference internal" href="#scintilla-keyboard-commands">Scintilla
3627 keyboard commands</a>. The Scintilla keyboard shortcuts will be overridden
3628 by any custom keybindings with the same keyboard shortcut.</p>
3629 <div class="section" id="switching-documents">
3630 <h3><a class="toc-backref" href="#id160">Switching documents</a></h3>
3631 <p>There are some non-configurable bindings to switch between documents,
3632 listed below. These can also be overridden by custom keybindings.</p>
3633 <table border="1" class="docutils">
3634 <colgroup>
3635 <col width="31%" />
3636 <col width="69%" />
3637 </colgroup>
3638 <thead valign="bottom">
3639 <tr><th class="head">Key</th>
3640 <th class="head">Action</th>
3641 </tr>
3642 </thead>
3643 <tbody valign="top">
3644 <tr><td>Alt-[1-9]</td>
3645 <td>Select left-most tab, from 1 to 9.</td>
3646 </tr>
3647 <tr><td>Alt-0</td>
3648 <td>Select right-most tab.</td>
3649 </tr>
3650 </tbody>
3651 </table>
3652 <p>See also <a class="reference internal" href="#notebook-tab-keybindings">Notebook tab keybindings</a>.</p>
3653 </div>
3654 <div class="section" id="configurable-keybindings">
3655 <h3><a class="toc-backref" href="#id161">Configurable keybindings</a></h3>
3656 <p>For all actions listed below you can define your own keybindings. Open
3657 the Preferences dialog, select the desired action and click on
3658 change. In the resulting dialog you can press the key combination you
3659 want to assign to the action and it will be saved when you press OK.
3660 You can define only one key combination for each action and each key
3661 combination can only be defined for one action.</p>
3662 <p>The following tables list all customizable keyboard shortcuts, those
3663 which are common to many applications are marked with (C) after the
3664 shortcut.</p>
3665 <div class="section" id="file-keybindings">
3666 <h4><a class="toc-backref" href="#id162">File keybindings</a></h4>
3667 <table border="1" class="docutils">
3668 <colgroup>
3669 <col width="29%" />
3670 <col width="24%" />
3671 <col width="47%" />
3672 </colgroup>
3673 <thead valign="bottom">
3674 <tr><th class="head">Action</th>
3675 <th class="head">Default shortcut</th>
3676 <th class="head">Description</th>
3677 </tr>
3678 </thead>
3679 <tbody valign="top">
3680 <tr><td>New</td>
3681 <td>Ctrl-N (C)</td>
3682 <td>Creates a new file.</td>
3683 </tr>
3684 <tr><td>Open</td>
3685 <td>Ctrl-O (C)</td>
3686 <td>Opens a file.</td>
3687 </tr>
3688 <tr><td>Open selected file</td>
3689 <td>Ctrl-Shift-O</td>
3690 <td>Opens the selected filename.</td>
3691 </tr>
3692 <tr><td>Re-open last closed tab</td>
3693 <td>&nbsp;</td>
3694 <td>Re-opens the last closed document tab.</td>
3695 </tr>
3696 <tr><td>Save</td>
3697 <td>Ctrl-S (C)</td>
3698 <td>Saves the current file.</td>
3699 </tr>
3700 <tr><td>Save As</td>
3701 <td>&nbsp;</td>
3702 <td>Saves the current file under a new name.</td>
3703 </tr>
3704 <tr><td>Save all</td>
3705 <td>Ctrl-Shift-S</td>
3706 <td>Saves all open files.</td>
3707 </tr>
3708 <tr><td>Close all</td>
3709 <td>Ctrl-Shift-W</td>
3710 <td>Closes all open files.</td>
3711 </tr>
3712 <tr><td>Close</td>
3713 <td>Ctrl-W (C)</td>
3714 <td>Closes the current file.</td>
3715 </tr>
3716 <tr><td>Reload file</td>
3717 <td>Ctrl-R (C)</td>
3718 <td>Reloads the current file. All unsaved changes
3719 will be lost.</td>
3720 </tr>
3721 <tr><td>Print</td>
3722 <td>Ctrl-P (C)</td>
3723 <td>Prints the current file.</td>
3724 </tr>
3725 <tr><td>Quit</td>
3726 <td>Ctrl-Q (C)</td>
3727 <td>Quits Geany.</td>
3728 </tr>
3729 </tbody>
3730 </table>
3731 </div>
3732 <div class="section" id="editor-keybindings">
3733 <h4><a class="toc-backref" href="#id163">Editor keybindings</a></h4>
3734 <table border="1" class="docutils">
3735 <colgroup>
3736 <col width="29%" />
3737 <col width="24%" />
3738 <col width="47%" />
3739 </colgroup>
3740 <thead valign="bottom">
3741 <tr><th class="head">Action</th>
3742 <th class="head">Default shortcut</th>
3743 <th class="head">Description</th>
3744 </tr>
3745 </thead>
3746 <tbody valign="top">
3747 <tr><td>Undo</td>
3748 <td>Ctrl-Z (C)</td>
3749 <td>Un-does the last action.</td>
3750 </tr>
3751 <tr><td>Redo</td>
3752 <td>Ctrl-Y</td>
3753 <td>Re-does the last action.</td>
3754 </tr>
3755 <tr><td>Delete current line(s)</td>
3756 <td>Ctrl-K</td>
3757 <td>Deletes the current line (and any lines with a
3758 selection).</td>
3759 </tr>
3760 <tr><td>Delete to line end</td>
3761 <td>Ctrl-Shift-Delete</td>
3762 <td>Deletes from the current caret position to the
3763 end of the current line.</td>
3764 </tr>
3765 <tr><td>Duplicate line or selection</td>
3766 <td>Ctrl-D</td>
3767 <td>Duplicates the current line or selection.</td>
3768 </tr>
3769 <tr><td>Transpose current line</td>
3770 <td>&nbsp;</td>
3771 <td>Transposes the current line with the previous one.</td>
3772 </tr>
3773 <tr><td>Scroll to current line</td>
3774 <td>Ctrl-Shift-L</td>
3775 <td>Scrolls the current line into the centre of the
3776 view. The cursor position and or an existing
3777 selection will not be changed.</td>
3778 </tr>
3779 <tr><td>Scroll up by one line</td>
3780 <td>Alt-Up</td>
3781 <td>Scrolls the view.</td>
3782 </tr>
3783 <tr><td>Scroll down by one line</td>
3784 <td>Alt-Down</td>
3785 <td>Scrolls the view.</td>
3786 </tr>
3787 <tr><td>Complete word</td>
3788 <td>Ctrl-Space</td>
3789 <td>Shows the autocompletion list. If already showing
3790 tag completion, it shows document word completion
3791 instead, even if it is not enabled for automatic
3792 completion. Likewise if no tag suggestions are
3793 available, it shows document word completion.</td>
3794 </tr>
3795 <tr><td>Show calltip</td>
3796 <td>Ctrl-Shift-Space</td>
3797 <td>Shows a calltip for the current function or
3798 method.</td>
3799 </tr>
3800 <tr><td>Show macro list</td>
3801 <td>Ctrl-Return</td>
3802 <td>Shows a list of available macros and variables in
3803 the workspace.</td>
3804 </tr>
3805 <tr><td>Complete snippet</td>
3806 <td>Tab</td>
3807 <td>If you type a construct like if or for and press
3808 this key, it will be completed with a matching
3809 template.</td>
3810 </tr>
3811 <tr><td>Suppress snippet completion</td>
3812 <td>&nbsp;</td>
3813 <td>If you type a construct like if or for and press
3814 this key, it will not be completed, and a space or
3815 tab will be inserted, depending on what the
3816 construct completion keybinding is set to. For
3817 example, if you have set the construct completion
3818 keybinding to space, then setting this to
3819 Shift+space will prevent construct completion and
3820 insert a space.</td>
3821 </tr>
3822 <tr><td>Context Action</td>
3823 <td>&nbsp;</td>
3824 <td>Executes a command and passes the current word
3825 (near the cursor position) or selection as an
3826 argument. See the section called <a class="reference internal" href="#context-actions">Context
3827 actions</a>.</td>
3828 </tr>
3829 <tr><td>Move cursor in snippet</td>
3830 <td>&nbsp;</td>
3831 <td>Jumps to the next defined cursor positions in a
3832 completed snippets if multiple cursor positions
3833 where defined.</td>
3834 </tr>
3835 <tr><td>Word part completion</td>
3836 <td>Tab</td>
3837 <td>When the autocompletion list is visible, complete
3838 the currently selected item up to the next word
3839 part.</td>
3840 </tr>
3841 <tr><td>Move line(s) up</td>
3842 <td>Alt-PageUp</td>
3843 <td>Move the current line or selected lines up by
3844 one line.</td>
3845 </tr>
3846 <tr><td>Move line(s) down</td>
3847 <td>Alt-PageDown</td>
3848 <td>Move the current line or selected lines down by
3849 one line.</td>
3850 </tr>
3851 </tbody>
3852 </table>
3853 </div>
3854 <div class="section" id="clipboard-keybindings">
3855 <h4><a class="toc-backref" href="#id164">Clipboard keybindings</a></h4>
3856 <table border="1" class="docutils">
3857 <colgroup>
3858 <col width="29%" />
3859 <col width="23%" />
3860 <col width="48%" />
3861 </colgroup>
3862 <thead valign="bottom">
3863 <tr><th class="head">Action</th>
3864 <th class="head">Default shortcut</th>
3865 <th class="head">Description</th>
3866 </tr>
3867 </thead>
3868 <tbody valign="top">
3869 <tr><td>Cut</td>
3870 <td>Ctrl-X (C)</td>
3871 <td>Cut the current selection to the clipboard.</td>
3872 </tr>
3873 <tr><td>Copy</td>
3874 <td>Ctrl-C (C)</td>
3875 <td>Copy the current selection to the clipboard.</td>
3876 </tr>
3877 <tr><td>Paste</td>
3878 <td>Ctrl-V (C)</td>
3879 <td>Paste the clipboard text into the current document.</td>
3880 </tr>
3881 <tr><td>Cut current line(s)</td>
3882 <td>Ctrl-Shift-X</td>
3883 <td>Cuts the current line (and any lines with a
3884 selection) to the clipboard.</td>
3885 </tr>
3886 <tr><td>Copy current line(s)</td>
3887 <td>Ctrl-Shift-C</td>
3888 <td>Copies the current line (and any lines with a
3889 selection) to the clipboard.</td>
3890 </tr>
3891 </tbody>
3892 </table>
3893 </div>
3894 <div class="section" id="select-keybindings">
3895 <h4><a class="toc-backref" href="#id165">Select keybindings</a></h4>
3896 <table border="1" class="docutils">
3897 <colgroup>
3898 <col width="29%" />
3899 <col width="24%" />
3900 <col width="47%" />
3901 </colgroup>
3902 <thead valign="bottom">
3903 <tr><th class="head">Action</th>
3904 <th class="head">Default shortcut</th>
3905 <th class="head">Description</th>
3906 </tr>
3907 </thead>
3908 <tbody valign="top">
3909 <tr><td>Select all</td>
3910 <td>Ctrl-A (C)</td>
3911 <td>Makes a selection of all text in the current
3912 document.</td>
3913 </tr>
3914 <tr><td>Select current word</td>
3915 <td>Alt-Shift-W</td>
3916 <td>Selects the current word under the cursor.</td>
3917 </tr>
3918 <tr><td>Select current paragraph</td>
3919 <td>Alt-Shift-P</td>
3920 <td>Selects the current paragraph under the cursor
3921 which is defined by two empty lines around it.</td>
3922 </tr>
3923 <tr><td>Select current line(s)</td>
3924 <td>Alt-Shift-L</td>
3925 <td>Selects the current line under the cursor (and any
3926 partially selected lines).</td>
3927 </tr>
3928 <tr><td>Select to previous word part</td>
3929 <td>&nbsp;</td>
3930 <td>(Extend) selection to previous word part boundary.</td>
3931 </tr>
3932 <tr><td>Select to next word part</td>
3933 <td>&nbsp;</td>
3934 <td>(Extend) selection to next word part boundary.</td>
3935 </tr>
3936 </tbody>
3937 </table>
3938 </div>
3939 <div class="section" id="insert-keybindings">
3940 <h4><a class="toc-backref" href="#id166">Insert keybindings</a></h4>
3941 <table border="1" class="docutils">
3942 <colgroup>
3943 <col width="29%" />
3944 <col width="24%" />
3945 <col width="47%" />
3946 </colgroup>
3947 <thead valign="bottom">
3948 <tr><th class="head">Action</th>
3949 <th class="head">Default shortcut</th>
3950 <th class="head">Description</th>
3951 </tr>
3952 </thead>
3953 <tbody valign="top">
3954 <tr><td>Insert date</td>
3955 <td>Shift-Alt-D</td>
3956 <td>Inserts a customisable date.</td>
3957 </tr>
3958 <tr><td>Insert alternative whitespace</td>
3959 <td>&nbsp;</td>
3960 <td>Inserts a tab character when spaces should
3961 be used for indentation and inserts space
3962 characters of the amount of a tab width when
3963 tabs should be used for indentation.</td>
3964 </tr>
3965 <tr><td>Insert New Line Before Current</td>
3966 <td>&nbsp;</td>
3967 <td>Inserts a new line with indentation.</td>
3968 </tr>
3969 <tr><td>Insert New Line After Current</td>
3970 <td>&nbsp;</td>
3971 <td>Inserts a new line with indentation.</td>
3972 </tr>
3973 </tbody>
3974 </table>
3975 </div>
3976 <div class="section" id="format-keybindings">
3977 <h4><a class="toc-backref" href="#id167">Format keybindings</a></h4>
3978 <table border="1" class="docutils">
3979 <colgroup>
3980 <col width="29%" />
3981 <col width="24%" />
3982 <col width="47%" />
3983 </colgroup>
3984 <thead valign="bottom">
3985 <tr><th class="head">Action</th>
3986 <th class="head">Default shortcut</th>
3987 <th class="head">Description</th>
3988 </tr>
3989 </thead>
3990 <tbody valign="top">
3991 <tr><td>Toggle case of selection</td>
3992 <td>Ctrl-Alt-U</td>
3993 <td>Changes the case of the selection. A lowercase
3994 selection will be changed into uppercase and vice
3995 versa. If the selection contains lower- and
3996 uppercase characters, all will be converted to
3997 lowercase.</td>
3998 </tr>
3999 <tr><td>Comment line</td>
4000 <td>&nbsp;</td>
4001 <td>Comments current line or selection.</td>
4002 </tr>
4003 <tr><td>Uncomment line</td>
4004 <td>&nbsp;</td>
4005 <td>Uncomments current line or selection.</td>
4006 </tr>
4007 <tr><td>Toggle line commentation</td>
4008 <td>Ctrl-E</td>
4009 <td>Comments a line if it is not commented or removes
4010 a comment if the line is commented.</td>
4011 </tr>
4012 <tr><td>Increase indent</td>
4013 <td>Ctrl-I</td>
4014 <td>Indents the current line or selection by one tab
4015 or by spaces in the amount of the tab width
4016 setting.</td>
4017 </tr>
4018 <tr><td>Decrease indent</td>
4019 <td>Ctrl-U</td>
4020 <td>Removes one tab or the amount of spaces of
4021 the tab width setting from the indentation of the
4022 current line or selection.</td>
4023 </tr>
4024 <tr><td>Increase indent by one space</td>
4025 <td>&nbsp;</td>
4026 <td>Indents the current line or selection by one
4027 space.</td>
4028 </tr>
4029 <tr><td>Decrease indent by one space</td>
4030 <td>&nbsp;</td>
4031 <td>Deindents the current line or selection by one
4032 space.</td>
4033 </tr>
4034 <tr><td>Smart line indent</td>
4035 <td>&nbsp;</td>
4036 <td>Indents the current line or all selected lines
4037 with the same indentation as the previous line.</td>
4038 </tr>
4039 <tr><td>Send to Custom Command 1 (2,3)</td>
4040 <td>Ctrl-1 (2,3)</td>
4041 <td>Passes the current selection to a configured
4042 external command (available for the first
4043 three configured commands, see
4044 <a class="reference internal" href="#sending-text-through-custom-commands">Sending text through custom commands</a> for
4045 details).</td>
4046 </tr>
4047 <tr><td>Send Selection to Terminal</td>
4048 <td>&nbsp;</td>
4049 <td>Sends the current selection or the current
4050 line (if there is no selection) to the
4051 embedded Terminal (VTE).</td>
4052 </tr>
4053 <tr><td>Reflow lines/block</td>
4054 <td>&nbsp;</td>
4055 <td>Reformat selected lines or current
4056 (indented) text block,
4057 breaking lines at the long line marker or the
4058 line breaking column if line breaking is
4059 enabled for the current document.</td>
4060 </tr>
4061 </tbody>
4062 </table>
4063 </div>
4064 <div class="section" id="settings-keybindings">
4065 <h4><a class="toc-backref" href="#id168">Settings keybindings</a></h4>
4066 <table border="1" class="docutils">
4067 <colgroup>
4068 <col width="29%" />
4069 <col width="24%" />
4070 <col width="47%" />
4071 </colgroup>
4072 <thead valign="bottom">
4073 <tr><th class="head">Action</th>
4074 <th class="head">Default shortcut</th>
4075 <th class="head">Description</th>
4076 </tr>
4077 </thead>
4078 <tbody valign="top">
4079 <tr><td>Preferences</td>
4080 <td>Ctrl-Alt-P</td>
4081 <td>Opens preferences dialog.</td>
4082 </tr>
4083 <tr><td>Plugin Preferences</td>
4084 <td>&nbsp;</td>
4085 <td>Opens plugin preferences dialog.</td>
4086 </tr>
4087 </tbody>
4088 </table>
4089 </div>
4090 <div class="section" id="search-keybindings">
4091 <h4><a class="toc-backref" href="#id169">Search keybindings</a></h4>
4092 <table border="1" class="docutils">
4093 <colgroup>
4094 <col width="29%" />
4095 <col width="24%" />
4096 <col width="47%" />
4097 </colgroup>
4098 <thead valign="bottom">
4099 <tr><th class="head">Action</th>
4100 <th class="head">Default shortcut</th>
4101 <th class="head">Description</th>
4102 </tr>
4103 </thead>
4104 <tbody valign="top">
4105 <tr><td>Find</td>
4106 <td>Ctrl-F (C)</td>
4107 <td>Opens the Find dialog.</td>
4108 </tr>
4109 <tr><td>Find Next</td>
4110 <td>Ctrl-G</td>
4111 <td>Finds next result.</td>
4112 </tr>
4113 <tr><td>Find Previous</td>
4114 <td>Ctrl-Shift-G</td>
4115 <td>Finds previous result.</td>
4116 </tr>
4117 <tr><td>Find Next Selection</td>
4118 <td>&nbsp;</td>
4119 <td>Finds next occurence of selected text.</td>
4120 </tr>
4121 <tr><td>Find Previous Selection</td>
4122 <td>&nbsp;</td>
4123 <td>Finds previous occurence of selected text.</td>
4124 </tr>
4125 <tr><td>Replace</td>
4126 <td>Ctrl-H (C)</td>
4127 <td>Opens the Replace dialog.</td>
4128 </tr>
4129 <tr><td>Find in files</td>
4130 <td>Ctrl-Shift-F</td>
4131 <td>Opens the Find in files dialog.</td>
4132 </tr>
4133 <tr><td>Next message</td>
4134 <td>&nbsp;</td>
4135 <td>Jumps to the line with the next message in
4136 the Messages window.</td>
4137 </tr>
4138 <tr><td>Previous message</td>
4139 <td>&nbsp;</td>
4140 <td>Jumps to the line with the previous message
4141 in the Messages window.</td>
4142 </tr>
4143 <tr><td>Find Usage</td>
4144 <td>Ctrl-Shift-E</td>
4145 <td>Finds all occurrences of the current word (near
4146 the keyboard cursor) or selection in all open
4147 documents and displays them in the messages
4148 window.</td>
4149 </tr>
4150 <tr><td>Find Document Usage</td>
4151 <td>Ctrl-Shift-D</td>
4152 <td>Finds all occurrences of the current word (near
4153 the keyboard cursor) or selection in the current
4154 document and displays them in the messages
4155 window.</td>
4156 </tr>
4157 <tr><td>Mark All</td>
4158 <td>Ctrl-Shift-M</td>
4159 <td>Highlight all matches of the current
4160 word/selection in the current document
4161 with a colored box. If there's nothing to
4162 find, or the cursor is next to an existing match,
4163 the highlighted matches will be cleared.</td>
4164 </tr>
4165 </tbody>
4166 </table>
4167 </div>
4168 <div class="section" id="go-to-keybindings">
4169 <h4><a class="toc-backref" href="#id170">Go to keybindings</a></h4>
4170 <table border="1" class="docutils">
4171 <colgroup>
4172 <col width="29%" />
4173 <col width="24%" />
4174 <col width="47%" />
4175 </colgroup>
4176 <thead valign="bottom">
4177 <tr><th class="head">Action</th>
4178 <th class="head">Default shortcut</th>
4179 <th class="head">Description</th>
4180 </tr>
4181 </thead>
4182 <tbody valign="top">
4183 <tr><td>Navigate forward a location</td>
4184 <td>Alt-Right (C)</td>
4185 <td>Switches to the next location in the navigation
4186 history. See the section called <a class="reference internal" href="#code-navigation-history">Code Navigation
4187 History</a>.</td>
4188 </tr>
4189 <tr><td>Navigate back a location</td>
4190 <td>Alt-Left (C)</td>
4191 <td>Switches to the previous location in the
4192 navigation history. See the section called
4193 <a class="reference internal" href="#code-navigation-history">Code navigation history</a>.</td>
4194 </tr>
4195 <tr><td>Go to line</td>
4196 <td>Ctrl-L</td>
4197 <td>Focuses the Go to Line entry (if visible) or
4198 shows the Go to line dialog.</td>
4199 </tr>
4200 <tr><td>Goto matching brace</td>
4201 <td>Ctrl-B</td>
4202 <td>If the cursor is ahead or behind a brace, then it
4203 is moved to the brace which belongs to the current
4204 one. If this keyboard shortcut is pressed again,
4205 the cursor is moved back to the first brace.</td>
4206 </tr>
4207 <tr><td>Toggle marker</td>
4208 <td>Ctrl-M</td>
4209 <td>Set a marker on the current line, or clear the
4210 marker if there already is one.</td>
4211 </tr>
4212 <tr><td>Goto next marker</td>
4213 <td>Ctrl-.</td>
4214 <td>Goto the next marker in the current document.</td>
4215 </tr>
4216 <tr><td>Goto previous marker</td>
4217 <td>Ctrl-,</td>
4218 <td>Goto the previous marker in the current document.</td>
4219 </tr>
4220 <tr><td>Go to tag definition</td>
4221 <td>Ctrl-T</td>
4222 <td>Jump to the definition of the current word or
4223 selection. See <a class="reference internal" href="#go-to-tag-definition">Go to tag definition</a>.</td>
4224 </tr>
4225 <tr><td>Go to tag declaration</td>
4226 <td>Ctrl-Shift-T</td>
4227 <td>Jump to the declaration of the current word or
4228 selection. See <a class="reference internal" href="#go-to-tag-declaration">Go to tag declaration</a>.</td>
4229 </tr>
4230 <tr><td>Go to Start of Line</td>
4231 <td>Home</td>
4232 <td>Move the caret to the start of the line.
4233 Behaves differently if <a class="reference internal" href="#smart-home-key">smart_home_key</a> is set.</td>
4234 </tr>
4235 <tr><td>Go to End of Line</td>
4236 <td>End</td>
4237 <td>Move the caret to the end of the line.</td>
4238 </tr>
4239 <tr><td>Go to Start of Display Line</td>
4240 <td>Alt-Home</td>
4241 <td>Move the caret to the start of the display line.
4242 This is useful when you use line wrapping and
4243 want to jump to the start of the wrapped, virtual
4244 line, not the real start of the whole line.
4245 If the line is not wrapped, it behaves like
4246 <cite>Go to Start of Line</cite>.</td>
4247 </tr>
4248 <tr><td>Go to End of Display Line</td>
4249 <td>Alt-End</td>
4250 <td>Move the caret to the end of the display line.
4251 If the line is not wrapped, it behaves like
4252 <cite>Go to End of Line</cite>.</td>
4253 </tr>
4254 <tr><td>Go to Previous Word Part</td>
4255 <td>Ctrl-/</td>
4256 <td>Goto the previous part of the current word.</td>
4257 </tr>
4258 <tr><td>Go to Next Word Part</td>
4259 <td>Ctrl-\</td>
4260 <td>Goto the next part of the current word.</td>
4261 </tr>
4262 </tbody>
4263 </table>
4264 </div>
4265 <div class="section" id="view-keybindings">
4266 <h4><a class="toc-backref" href="#id171">View keybindings</a></h4>
4267 <table border="1" class="docutils">
4268 <colgroup>
4269 <col width="29%" />
4270 <col width="24%" />
4271 <col width="47%" />
4272 </colgroup>
4273 <thead valign="bottom">
4274 <tr><th class="head">Action</th>
4275 <th class="head">Default shortcut</th>
4276 <th class="head">Description</th>
4277 </tr>
4278 </thead>
4279 <tbody valign="top">
4280 <tr><td>Fullscreen</td>
4281 <td>F11 (C)</td>
4282 <td>Switches to fullscreen mode.</td>
4283 </tr>
4284 <tr><td>Toggle Messages Window</td>
4285 <td>&nbsp;</td>
4286 <td>Toggles the message window (status and compiler
4287 messages) on and off.</td>
4288 </tr>
4289 <tr><td>Toggle Sidebar</td>
4290 <td>&nbsp;</td>
4291 <td>Shows or hides the sidebar.</td>
4292 </tr>
4293 <tr><td>Toggle all additional widgets</td>
4294 <td>&nbsp;</td>
4295 <td>Hide and show all additional widgets like the
4296 notebook tabs, the toolbar, the messages window
4297 and the status bar.</td>
4298 </tr>
4299 <tr><td>Zoom In</td>
4300 <td>Ctrl-+ (C)</td>
4301 <td>Zooms in the text.</td>
4302 </tr>
4303 <tr><td>Zoom Out</td>
4304 <td>Ctrl-- (C)</td>
4305 <td>Zooms out the text.</td>
4306 </tr>
4307 <tr><td>Zoom Reset</td>
4308 <td>Ctrl-0</td>
4309 <td>Reset any previous zoom on the text.</td>
4310 </tr>
4311 </tbody>
4312 </table>
4313 </div>
4314 <div class="section" id="focus-keybindings">
4315 <h4><a class="toc-backref" href="#id172">Focus keybindings</a></h4>
4316 <table border="1" class="docutils">
4317 <colgroup>
4318 <col width="30%" />
4319 <col width="23%" />
4320 <col width="47%" />
4321 </colgroup>
4322 <thead valign="bottom">
4323 <tr><th class="head">Action</th>
4324 <th class="head">Default shortcut</th>
4325 <th class="head">Description</th>
4326 </tr>
4327 </thead>
4328 <tbody valign="top">
4329 <tr><td>Switch to Editor</td>
4330 <td>F2</td>
4331 <td>Switches to editor widget.
4332 Also reshows the document statistics line
4333 (after a short timeout).</td>
4334 </tr>
4335 <tr><td>Switch to Search Bar</td>
4336 <td>F7</td>
4337 <td>Switches to the search bar in the toolbar (if
4338 visible).</td>
4339 </tr>
4340 <tr><td>Switch to Message Window</td>
4341 <td>&nbsp;</td>
4342 <td>Focus the Message Window's current tab.</td>
4343 </tr>
4344 <tr><td>Switch to Compiler</td>
4345 <td>&nbsp;</td>
4346 <td>Focus the Compiler message window tab.</td>
4347 </tr>
4348 <tr><td>Switch to Messages</td>
4349 <td>&nbsp;</td>
4350 <td>Focus the Messages message window tab.</td>
4351 </tr>
4352 <tr><td>Switch to Scribble</td>
4353 <td>F6</td>
4354 <td>Switches to scribble widget.</td>
4355 </tr>
4356 <tr><td>Switch to VTE</td>
4357 <td>F4</td>
4358 <td>Switches to VTE widget.</td>
4359 </tr>
4360 <tr><td>Switch to Sidebar</td>
4361 <td>&nbsp;</td>
4362 <td>Focus the Sidebar.</td>
4363 </tr>
4364 <tr><td>Switch to Sidebar Symbol List</td>
4365 <td>&nbsp;</td>
4366 <td>Focus the Symbol list tab in the Sidebar
4367 (if visible).</td>
4368 </tr>
4369 <tr><td>Switch to Sidebar Document List</td>
4370 <td>&nbsp;</td>
4371 <td>Focus the Document list tab in the Sidebar
4372 (if visible).</td>
4373 </tr>
4374 </tbody>
4375 </table>
4376 </div>
4377 <div class="section" id="notebook-tab-keybindings">
4378 <h4><a class="toc-backref" href="#id173">Notebook tab keybindings</a></h4>
4379 <table border="1" class="docutils">
4380 <colgroup>
4381 <col width="28%" />
4382 <col width="23%" />
4383 <col width="49%" />
4384 </colgroup>
4385 <thead valign="bottom">
4386 <tr><th class="head">Action</th>
4387 <th class="head">Default shortcut</th>
4388 <th class="head">Description</th>
4389 </tr>
4390 </thead>
4391 <tbody valign="top">
4392 <tr><td>Switch to left document</td>
4393 <td>Ctrl-PageUp (C)</td>
4394 <td>Switches to the previous open document.</td>
4395 </tr>
4396 <tr><td>Switch to right document</td>
4397 <td>Ctrl-PageDown (C)</td>
4398 <td>Switches to the next open document.</td>
4399 </tr>
4400 <tr><td>Switch to last used document</td>
4401 <td>Ctrl-Tab</td>
4402 <td>Switches to the previously shown document (if it's
4403 still open).
4404 Holding Ctrl (or another modifier if the keybinding
4405 has been changed) will show a dialog, then repeated
4406 presses of the keybinding will switch to the 2nd-last
4407 used document, 3rd-last, etc. Also known as
4408 Most-Recently-Used documents switching.</td>
4409 </tr>
4410 <tr><td>Move document left</td>
4411 <td>Ctrl-Shift-PageUp</td>
4412 <td>Changes the current document with the left hand
4413 one.</td>
4414 </tr>
4415 <tr><td>Move document right</td>
4416 <td>Ctrl-Shift-PageDown</td>
4417 <td>Changes the current document with the right hand
4418 one.</td>
4419 </tr>
4420 <tr><td>Move document first</td>
4421 <td>&nbsp;</td>
4422 <td>Moves the current document to the first position.</td>
4423 </tr>
4424 <tr><td>Move document last</td>
4425 <td>&nbsp;</td>
4426 <td>Moves the current document to the last position.</td>
4427 </tr>
4428 </tbody>
4429 </table>
4430 </div>
4431 <div class="section" id="document-keybindings">
4432 <h4><a class="toc-backref" href="#id174">Document keybindings</a></h4>
4433 <table border="1" class="docutils">
4434 <colgroup>
4435 <col width="33%" />
4436 <col width="19%" />
4437 <col width="48%" />
4438 </colgroup>
4439 <thead valign="bottom">
4440 <tr><th class="head">Action</th>
4441 <th class="head">Default shortcut</th>
4442 <th class="head">Description</th>
4443 </tr>
4444 </thead>
4445 <tbody valign="top">
4446 <tr><td>Clone</td>
4447 <td>&nbsp;</td>
4448 <td>See <a class="reference internal" href="#cloning-documents">Cloning documents</a>.</td>
4449 </tr>
4450 <tr><td>Replace tabs by space</td>
4451 <td>&nbsp;</td>
4452 <td>Replaces all tabs with the right amount of spaces.</td>
4453 </tr>
4454 <tr><td>Replace spaces by tabs</td>
4455 <td>&nbsp;</td>
4456 <td>Replaces leading spaces with tab characters.</td>
4457 </tr>
4458 <tr><td>Toggle current fold</td>
4459 <td>&nbsp;</td>
4460 <td>Toggles the folding state of the current code block.</td>
4461 </tr>
4462 <tr><td>Fold all</td>
4463 <td>&nbsp;</td>
4464 <td>Folds all contractible code blocks.</td>
4465 </tr>
4466 <tr><td>Unfold all</td>
4467 <td>&nbsp;</td>
4468 <td>Unfolds all contracted code blocks.</td>
4469 </tr>
4470 <tr><td>Reload symbol list</td>
4471 <td>Ctrl-Shift-R</td>
4472 <td>Reloads the tag/symbol list.</td>
4473 </tr>
4474 <tr><td>Toggle Line wrapping</td>
4475 <td>&nbsp;</td>
4476 <td>Enables or disables wrapping of long lines.</td>
4477 </tr>
4478 <tr><td>Toggle Line breaking</td>
4479 <td>&nbsp;</td>
4480 <td>Enables or disables automatic breaking of long
4481 lines at a configurable column.</td>
4482 </tr>
4483 <tr><td>Remove Markers</td>
4484 <td>&nbsp;</td>
4485 <td>Remove any markers on lines or words which
4486 were set by using 'Mark All' in the
4487 search dialog or by manually marking lines.</td>
4488 </tr>
4489 <tr><td>Remove Error Indicators</td>
4490 <td>&nbsp;</td>
4491 <td>Remove any error indicators in the
4492 current document.</td>
4493 </tr>
4494 <tr><td>Remove Markers and Error Indicators</td>
4495 <td>&nbsp;</td>
4496 <td>Combines <tt class="docutils literal">Remove Markers</tt> and
4497 <tt class="docutils literal">Remove Error Indicators</tt>.</td>
4498 </tr>
4499 </tbody>
4500 </table>
4501 </div>
4502 <div class="section" id="project-keybindings">
4503 <h4><a class="toc-backref" href="#id175">Project keybindings</a></h4>
4504 <table border="1" class="docutils">
4505 <colgroup>
4506 <col width="29%" />
4507 <col width="24%" />
4508 <col width="47%" />
4509 </colgroup>
4510 <thead valign="bottom">
4511 <tr><th class="head">Action</th>
4512 <th class="head">Default shortcut</th>
4513 <th class="head">Description</th>
4514 </tr>
4515 </thead>
4516 <tbody valign="top">
4517 <tr><td>New</td>
4518 <td>&nbsp;</td>
4519 <td>Create a new project.</td>
4520 </tr>
4521 <tr><td>Open</td>
4522 <td>&nbsp;</td>
4523 <td>Opens a project file.</td>
4524 </tr>
4525 <tr><td>Properties</td>
4526 <td>&nbsp;</td>
4527 <td>Shows project properties.</td>
4528 </tr>
4529 <tr><td>Close</td>
4530 <td>&nbsp;</td>
4531 <td>Close the current project.</td>
4532 </tr>
4533 </tbody>
4534 </table>
4535 </div>
4536 <div class="section" id="build-keybindings">
4537 <h4><a class="toc-backref" href="#id176">Build keybindings</a></h4>
4538 <table border="1" class="docutils">
4539 <colgroup>
4540 <col width="29%" />
4541 <col width="24%" />
4542 <col width="47%" />
4543 </colgroup>
4544 <thead valign="bottom">
4545 <tr><th class="head">Action</th>
4546 <th class="head">Default shortcut</th>
4547 <th class="head">Description</th>
4548 </tr>
4549 </thead>
4550 <tbody valign="top">
4551 <tr><td>Compile</td>
4552 <td>F8</td>
4553 <td>Compiles the current file.</td>
4554 </tr>
4555 <tr><td>Build</td>
4556 <td>F9</td>
4557 <td>Builds (compiles if necessary and links) the
4558 current file.</td>
4559 </tr>
4560 <tr><td>Make all</td>
4561 <td>Shift-F9</td>
4562 <td>Builds the current file with the Make tool.</td>
4563 </tr>
4564 <tr><td>Make custom target</td>
4565 <td>Ctrl-Shift-F9</td>
4566 <td>Builds the current file with the Make tool and a
4567 given target.</td>
4568 </tr>
4569 <tr><td>Make object</td>
4570 <td>Shift-F8</td>
4571 <td>Compiles the current file with the Make tool.</td>
4572 </tr>
4573 <tr><td>Next error</td>
4574 <td>&nbsp;</td>
4575 <td>Jumps to the line with the next error from the
4576 last build process.</td>
4577 </tr>
4578 <tr><td>Previous error</td>
4579 <td>&nbsp;</td>
4580 <td>Jumps to the line with the previous error from
4581 the last build process.</td>
4582 </tr>
4583 <tr><td>Run</td>
4584 <td>F5</td>
4585 <td>Executes the current file in a terminal emulation.</td>
4586 </tr>
4587 <tr><td>Set Build Commands</td>
4588 <td>&nbsp;</td>
4589 <td>Opens the build commands dialog.</td>
4590 </tr>
4591 </tbody>
4592 </table>
4593 </div>
4594 <div class="section" id="tools-keybindings">
4595 <h4><a class="toc-backref" href="#id177">Tools keybindings</a></h4>
4596 <table border="1" class="docutils">
4597 <colgroup>
4598 <col width="29%" />
4599 <col width="24%" />
4600 <col width="47%" />
4601 </colgroup>
4602 <thead valign="bottom">
4603 <tr><th class="head">Action</th>
4604 <th class="head">Default shortcut</th>
4605 <th class="head">Description</th>
4606 </tr>
4607 </thead>
4608 <tbody valign="top">
4609 <tr><td>Show Color Chooser</td>
4610 <td>&nbsp;</td>
4611 <td>Opens the Color Chooser dialog.</td>
4612 </tr>
4613 </tbody>
4614 </table>
4615 </div>
4616 <div class="section" id="help-keybindings">
4617 <h4><a class="toc-backref" href="#id178">Help keybindings</a></h4>
4618 <table border="1" class="docutils">
4619 <colgroup>
4620 <col width="29%" />
4621 <col width="24%" />
4622 <col width="47%" />
4623 </colgroup>
4624 <thead valign="bottom">
4625 <tr><th class="head">Action</th>
4626 <th class="head">Default shortcut</th>
4627 <th class="head">Description</th>
4628 </tr>
4629 </thead>
4630 <tbody valign="top">
4631 <tr><td>Help</td>
4632 <td>F1 (C)</td>
4633 <td>Opens the manual.</td>
4634 </tr>
4635 </tbody>
4636 </table>
4637 </div>
4638 </div>
4639 </div>
4640 </div>
4641 <div class="section" id="configuration-files">
4642 <h1><a class="toc-backref" href="#id179">Configuration files</a></h1>
4643 <div class="warning">
4644 <p class="first admonition-title">Warning</p>
4645 <p class="last">You must use UTF-8 encoding <em>without BOM</em> for configuration files.</p>
4646 </div>
4647 <div class="section" id="configuration-file-paths">
4648 <h2><a class="toc-backref" href="#id180">Configuration file paths</a></h2>
4649 <p>Geany has default configuration files installed for the system and
4650 also per-user configuration files.</p>
4651 <p>The system files should not normally be edited because they will be
4652 overwritten when upgrading Geany.</p>
4653 <p>The user configuration directory can be overridden with the <tt class="docutils literal"><span class="pre">-c</span></tt>
4654 switch, but this is not normally done. See <a class="reference internal" href="#command-line-options">Command line options</a>.</p>
4655 <div class="note">
4656 <p class="first admonition-title">Note</p>
4657 <p class="last">Any missing subdirectories in the user configuration directory
4658 will be created when Geany starts.</p>
4659 </div>
4660 <p>You can check the paths Geany is using with <em>Help-&gt;Debug Messages</em>.
4661 Near the top there should be 2 lines with something like:</p>
4662 <pre class="literal-block">
4663 Geany-INFO: System data dir: /usr/share/geany
4664 Geany-INFO: User config dir: /home/username/.config/geany
4665 </pre>
4666 <div class="section" id="paths-on-unix-like-systems">
4667 <h3><a class="toc-backref" href="#id181">Paths on Unix-like systems</a></h3>
4668 <p>The system path is <tt class="docutils literal">$prefix/share/geany</tt>, where <tt class="docutils literal">$prefix</tt> is the
4669 path where Geany is installed (see <a class="reference internal" href="#installation-prefix">Installation prefix</a>).</p>
4670 <p>The user configuration directory is normally:
4671 <tt class="docutils literal"><span class="pre">/home/username/.config/geany</span></tt></p>
4672 </div>
4673 <div class="section" id="paths-on-windows">
4674 <h3><a class="toc-backref" href="#id182">Paths on Windows</a></h3>
4675 <p>The system path is the <tt class="docutils literal">data</tt> subfolder of the installation path
4676 on Windows.</p>
4677 <p>The user configuration directory might vary, but on Windows XP it's:
4678 <tt class="docutils literal"><span class="pre">C:\Documents</span> and Settings\UserName\Application Data\geany</tt></p>
4679 </div>
4680 </div>
4681 <div class="section" id="tools-menu-items">
4682 <h2><a class="toc-backref" href="#id183">Tools menu items</a></h2>
4683 <p>There's a <em>Configuration files</em> submenu in the <em>Tools</em> menu that
4684 contains items for some of the available user configuration files.
4685 Clicking on one opens it in the editor for you to update. Geany will
4686 reload the file after you have saved it.</p>
4687 <div class="note">
4688 <p class="first admonition-title">Note</p>
4689 <p class="last">Other configuration files not shown here will need to be opened
4690 manually, and will not be automatically reloaded when saved.
4691 (see <em>Reload Configuration</em> below).</p>
4692 </div>
4693 <p>There's also a <em>Reload Configuration</em> item which can be used if you
4694 updated one of the other configuration files, or modified or added
4695 template files.</p>
4696 <p><em>Reload Configuration</em> is also necessary to update syntax highlighting colors.</p>
4697 <div class="note">
4698 <p class="first admonition-title">Note</p>
4699 <p class="last">Syntax highlighting colors aren't updated in open documents after
4700 saving filetypes.common as this may take a significant
4701 amount of time.</p>
4702 </div>
4703 </div>
4704 <div class="section" id="global-configuration-file">
4705 <h2><a class="toc-backref" href="#id184">Global configuration file</a></h2>
4706 <p>System administrators can add a global configuration file for Geany
4707 which will be used when starting Geany and a user configuration file
4708 does not exist.</p>
4709 <p>The global configuration file is read from <tt class="docutils literal">geany.conf</tt> in the
4710 system configuration path - see <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>. It can
4711 contain any settings which are found in the usual configuration file
4712 created by Geany, but does not have to contain all settings.</p>
4713 <div class="note">
4714 <p class="first admonition-title">Note</p>
4715 <p class="last">This feature is mainly intended for package maintainers or system
4716 admins who want to set up Geany in a multi user environment and
4717 set some sane default values for this environment. Usually users won't
4718 need to do that.</p>
4719 </div>
4720 </div>
4721 <div class="section" id="filetype-definition-files">
4722 <h2><a class="toc-backref" href="#id185">Filetype definition files</a></h2>
4723 <p>All color definitions and other filetype specific settings are
4724 stored in the filetype definition files. Those settings are colors
4725 for syntax highlighting, general settings like comment characters or
4726 word delimiter characters as well as compiler and linker settings.</p>
4727 <p>See also <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>.</p>
4728 <div class="section" id="filenames">
4729 <h3><a class="toc-backref" href="#id186">Filenames</a></h3>
4730 <p>Each filetype has a corresponding filetype definition file. The format
4731 for built-in filetype <cite>Foo</cite> is:</p>
4732 <pre class="literal-block">
4733 filetypes.foo
4734 </pre>
4735 <p>The extension is normally just the filetype name in lower case.</p>
4736 <p>However there are some exceptions:</p>
4737 <table border="1" class="docutils">
4738 <colgroup>
4739 <col width="63%" />
4740 <col width="38%" />
4741 </colgroup>
4742 <thead valign="bottom">
4743 <tr><th class="head">Filetype</th>
4744 <th class="head">Extension</th>
4745 </tr>
4746 </thead>
4747 <tbody valign="top">
4748 <tr><td>C++</td>
4749 <td>cpp</td>
4750 </tr>
4751 <tr><td>C#</td>
4752 <td>cs</td>
4753 </tr>
4754 <tr><td>Make</td>
4755 <td>makefile</td>
4756 </tr>
4757 <tr><td>Matlab/Octave</td>
4758 <td>matlab</td>
4759 </tr>
4760 </tbody>
4761 </table>
4762 <p>There is also the <a class="reference internal" href="#special-file-filetypes-common">special file filetypes.common</a>.</p>
4763 <p>For <a class="reference internal" href="#custom-filetypes">custom filetypes</a>, the filename for <cite>Foo</cite> is different:</p>
4764 <pre class="literal-block">
4765 filetypes.Foo.conf
4766 </pre>
4767 <p>See the link for details.</p>
4768 </div>
4769 <div class="section" id="system-files">
4770 <h3><a class="toc-backref" href="#id187">System files</a></h3>
4771 <p>The system-wide filetype configuration files can be found in the
4772 system configuration path and are called <tt class="docutils literal"><span class="pre">filetypes.$ext</span></tt>,
4773 where $ext is the name of the filetype. For every
4774 filetype there is a corresponding definition file. There is one
4775 exception: <tt class="docutils literal">filetypes.common</tt> -- this file is for general settings,
4776 which are not specific to a certain filetype.</p>
4777 <div class="warning">
4778 <p class="first admonition-title">Warning</p>
4779 <p class="last">It is not recommended that users edit the system-wide files,
4780 because they will be overridden when Geany is updated.</p>
4781 </div>
4782 </div>
4783 <div class="section" id="user-files">
4784 <h3><a class="toc-backref" href="#id188">User files</a></h3>
4785 <p>To change the settings, copy a file from the system configuration
4786 path to the subdirectory <tt class="docutils literal">filedefs</tt> in your user configuration
4787 directory. Then you can edit the file and the changes will still be
4788 available after an update of Geany.</p>
4789 <p>Alternatively, you can create the file yourself and add only the
4790 settings you want to change. All missing settings will be read from
4791 the corresponding system configuration file.</p>
4792 </div>
4793 <div class="section" id="custom-filetypes">
4794 <h3><a class="toc-backref" href="#id189">Custom filetypes</a></h3>
4795 <p>At startup Geany looks for <tt class="docutils literal"><span class="pre">filetypes.*.conf</span></tt> files in the system and
4796 user filetype paths, adding any filetypes found with the name matching
4797 the '<tt class="docutils literal">*</tt>' wildcard - e.g. <tt class="docutils literal">filetypes.Bar.conf</tt>.</p>
4798 <p>Custom filetypes are not as powerful as built-in filetypes, but
4799 support for the following has been implemented:</p>
4800 <ul>
4801 <li><p class="first">Recognizing and setting the filetype (after the user has manually edited
4802 <tt class="docutils literal">filetype_extensions.conf</tt>).</p>
4803 </li>
4804 <li><dl class="first docutils">
4805 <dt>Reading filetype settings in the <tt class="docutils literal">[settings]</tt> section, including:</dt>
4806 <dd><ul class="first last simple">
4807 <li>Using an existing syntax highlighting lexer (<a class="reference internal" href="#lexer-filetype">lexer_filetype</a> key).</li>
4808 <li>Using an existing tag parser (<tt class="docutils literal">tag_parser</tt> key).</li>
4809 </ul>
4810 </dd>
4811 </dl>
4812 </li>
4813 <li><p class="first">Build commands (<tt class="docutils literal"><span class="pre">[build-menu]</span></tt> section).</p>
4814 </li>
4815 <li><p class="first">Loading global tags files (sharing the <tt class="docutils literal">tag_parser</tt> namespace).</p>
4816 </li>
4817 </ul>
4818 <p>See <a class="reference internal" href="#filetype-configuration">Filetype configuration</a> for details on each setting.</p>
4819 <div class="section" id="creating-a-custom-filetype-from-an-existing-filetype">
4820 <h4><a class="toc-backref" href="#id190">Creating a custom filetype from an existing filetype</a></h4>
4821 <p>Because most filetype settings will relate to the syntax
4822 highlighting (e.g. styling, keywords, <tt class="docutils literal">lexer_properties</tt>
4823 sections), it is best to copy an existing filetype file that uses
4824 the lexer you wish to use as the basis of a custom filetype, using
4825 the correct filename extension format shown above, e.g.:</p>
4826 <pre class="literal-block">
4827 cp filetypes.foo filetypes.Bar.conf
4828 </pre>
4829 <p>Then add the <tt class="docutils literal">lexer_filetype=Foo</tt> setting (if not already present)
4830 and add/adjust other settings.</p>
4831 <div class="warning">
4832 <p class="first admonition-title">Warning</p>
4833 <p class="last">The <tt class="docutils literal">[styling]</tt> and <tt class="docutils literal">[keywords]</tt> sections have key names
4834 specific to each filetype/lexer. You must follow the same
4835 names - in particular, some lexers only support one keyword
4836 list, or none.</p>
4837 </div>
4838 </div>
4839 </div>
4840 <div class="section" id="filetype-configuration">
4841 <h3><a class="toc-backref" href="#id191">Filetype configuration</a></h3>
4842 <p>As well as the sections listed below, each filetype file can contain
4843 a [build-menu] section as described in <a class="reference internal" href="#build-menu-section">[build-menu] section</a>.</p>
4844 <div class="section" id="styling-section">
4845 <h4><a class="toc-backref" href="#id192">[styling] section</a></h4>
4846 <p>In this section the colors for syntax highlighting are defined. The
4847 manual format is:</p>
4848 <ul class="simple">
4849 <li><tt class="docutils literal">key=foreground_color;background_color;bold_flag;italic_flag</tt></li>
4850 </ul>
4851 <p>Colors have to be specified as RGB hex values prefixed by
4852 0x or # similar to HTML/CSS hex triplets. For example, all of the following
4853 are valid values for pure red; 0xff0000, 0xf00, #ff0000, or #f00. The
4854 values are case-insensitive but it is a good idea to use lower-case.
4855 Note that you can also use <em>named colors</em> as well by substituting the
4856 color value with the name of a color as defined in the <tt class="docutils literal">[named_colors]</tt>
4857 section, see the <a class="reference internal" href="#named-colors-section">[named_colors] Section</a> for more information.</p>
4858 <p>Bold and italic are flags and should only be &quot;true&quot; or &quot;false&quot;. If their
4859 value is something other than &quot;true&quot; or &quot;false&quot;, &quot;false&quot; is assumed.</p>
4860 <p>You can omit fields to use the values from the style named <tt class="docutils literal">&quot;default&quot;</tt>.</p>
4861 <p>E.g. <tt class="docutils literal"><span class="pre">key=0xff0000;;true</span></tt></p>
4862 <p>This makes the key style have red foreground text, default background
4863 color text and bold emphasis.</p>
4864 <div class="section" id="using-a-named-style">
4865 <h5><a class="toc-backref" href="#id193">Using a named style</a></h5>
4866 <p>The second format uses a <em>named style</em> name to reference a style
4867 defined in filetypes.common.</p>
4868 <ul class="simple">
4869 <li><tt class="docutils literal">key=named_style</tt></li>
4870 <li><tt class="docutils literal">key2=named_style2,bold,italic</tt></li>
4871 </ul>
4872 <p>The bold and italic parts are optional, and if present are used to
4873 toggle the bold or italic flags to the opposite of the named style's
4874 flags. In contrast to style definition booleans, they are a literal
4875 &quot;,bold,italic&quot; and commas are used instead of semi-colons.</p>
4876 <p>E.g. <tt class="docutils literal">key=comment,italic</tt></p>
4877 <p>This makes the key style match the <tt class="docutils literal">&quot;comment&quot;</tt> named style, but with
4878 italic emphasis.</p>
4879 <p>To define named styles, see the filetypes.common <a class="reference internal" href="#named-styles-section">[named_styles]
4880 Section</a>.</p>
4881 </div>
4882 <div class="section" id="reading-styles-from-another-filetype">
4883 <h5><a class="toc-backref" href="#id194">Reading styles from another filetype</a></h5>
4884 <p>You can automatically copy all of the styles from another filetype
4885 definition file by using the following syntax for the <tt class="docutils literal">[styling]</tt>
4886 group:</p>
4887 <pre class="literal-block">
4888 [styling=Foo]
4889 </pre>
4890 <p>Where Foo is a filetype name. The corresponding <tt class="docutils literal">[styling]</tt>
4891 section from <tt class="docutils literal">filetypes.foo</tt> will be read.</p>
4892 <p>This is useful when the same lexer is being used for multiple
4893 filetypes (e.g. C/C++/C#/Java/etc). For example, to make the C++
4894 styling the same as the C styling, you would put the following in
4895 <tt class="docutils literal">filetypes.cpp</tt>:</p>
4896 <pre class="literal-block">
4897 [styling=C]
4898 </pre>
4899 </div>
4900 </div>
4901 <div class="section" id="keywords-section">
4902 <h4><a class="toc-backref" href="#id195">[keywords] section</a></h4>
4903 <p>This section contains keys for different keyword lists specific to
4904 the filetype. Some filetypes do not support keywords, so adding a
4905 new key will not work. You can only add or remove keywords to/from
4906 an existing list.</p>
4907 <div class="important">
4908 <p class="first admonition-title">Important</p>
4909 <p class="last">The keywords list must be in one line without line ending characters.</p>
4910 </div>
4911 </div>
4912 <div class="section" id="lexer-properties-section">
4913 <h4><a class="toc-backref" href="#id196">[lexer_properties] section</a></h4>
4914 <p>Here any special properties for the Scintilla lexer can be set in the
4915 format <tt class="docutils literal">key.name.field=some.value</tt>.</p>
4916 <p>Properties Geany uses are listed in the system filetype files. To find
4917 other properties you need Geany's source code:</p>
4918 <pre class="literal-block">
4919 egrep -o 'GetProperty\w*\(&quot;([^&quot;]+)&quot;[^)]+\)' scintilla/Lex*.cxx
4920 </pre>
4921 </div>
4922 <div class="section" id="settings-section">
4923 <h4><a class="toc-backref" href="#id197">[settings] section</a></h4>
4924 <dl class="docutils">
4925 <dt>extension</dt>
4926 <dd><p class="first">This is the default file extension used when saving files, not
4927 including the period character (<tt class="docutils literal">.</tt>). The extension used should
4928 match one of the patterns associated with that filetype (see
4929 <a class="reference internal" href="#filetype-extensions">Filetype extensions</a>).</p>
4930 <p class="last"><em>Example:</em> <tt class="docutils literal">extension=cxx</tt></p>
4931 </dd>
4932 <dt>wordchars</dt>
4933 <dd><p class="first">These characters define word boundaries when making selections
4934 and searching using word matching options.</p>
4935 <p><em>Example:</em> (look at system filetypes.* files)</p>
4936 <div class="note last">
4937 <p class="first admonition-title">Note</p>
4938 <p class="last">This overrides the <em>whitespace_chars</em> filetypes.common setting.</p>
4939 </div>
4940 </dd>
4941 <dt>comment_single</dt>
4942 <dd><p class="first">A character or string which is used to comment code. If you want to use
4943 multiline comments only, don't set this but rather comment_open and
4944 comment_close.</p>
4945 <p>Single-line comments are used in priority over multiline comments to
4946 comment a line, e.g. with the <cite>Comment/Uncomment line</cite> command.</p>
4947 <p class="last"><em>Example:</em> <tt class="docutils literal"><span class="pre">comment_single=//</span></tt></p>
4948 </dd>
4949 <dt>comment_open</dt>
4950 <dd><p class="first">A character or string which is used to comment code. You need to also
4951 set comment_close to really use multiline comments. If you want to use
4952 single-line comments, prefer setting comment_single.</p>
4953 <p>Multiline comments are used in priority over single-line comments to
4954 comment a block, e.g. template comments.</p>
4955 <p class="last"><em>Example:</em> <tt class="docutils literal"><span class="pre">comment_open=/*</span></tt></p>
4956 </dd>
4957 <dt>comment_close</dt>
4958 <dd><p class="first">If multiline comments are used, this is the character or string to
4959 close the comment.</p>
4960 <p class="last"><em>Example:</em> <tt class="docutils literal"><span class="pre">comment_close=*/</span></tt></p>
4961 </dd>
4962 <dt>comment_use_indent</dt>
4963 <dd><p class="first">Set this to false if a comment character or string should start at
4964 column 0 of a line. If set to true it uses any indentation of the
4965 line.</p>
4966 <p>Note: Comment indentation</p>
4967 <p><tt class="docutils literal">comment_use_indent=true</tt> would generate this if a line is
4968 commented (e.g. with Ctrl-D):</p>
4969 <pre class="literal-block">
4970 #command_example();
4971 </pre>
4972 <p><tt class="docutils literal">comment_use_indent=false</tt> would generate this if a line is
4973 commented (e.g. with Ctrl-D):</p>
4974 <pre class="literal-block">
4975 # command_example();
4976 </pre>
4977 <p>Note: This setting only works for single line comments (like '//',
4978 '#' or ';').</p>
4979 <p class="last"><em>Example:</em> <tt class="docutils literal">comment_use_indent=true</tt></p>
4980 </dd>
4981 <dt>context_action_cmd</dt>
4982 <dd><p class="first">A command which can be executed on the current word or the current
4983 selection.</p>
4984 <p>Example usage: Open the API documentation for the
4985 current function call at the cursor position.</p>
4986 <p>The command can
4987 be set for every filetype or if not set, a global command will
4988 be used. The command itself can be specified without the full
4989 path, then it is searched in $PATH. But for security reasons,
4990 it is recommended to specify the full path to the command. The
4991 wildcard %s will be replaced by the current word at the cursor
4992 position or by the current selection.</p>
4993 <p>Hint: for PHP files the following could be quite useful:
4994 context_action_cmd=firefox &quot;<a class="reference external" href="http://www.php.net/%s">http://www.php.net/%s</a>&quot;</p>
4995 <p class="last"><em>Example:</em> <tt class="docutils literal">context_action_cmd=devhelp <span class="pre">-s</span> &quot;%s&quot;</tt></p>
4996 </dd>
4997 <dt>tag_parser</dt>
4998 <dd>The TagManager language name, e.g. &quot;C&quot;. Usually the same as the
4999 filetype name.</dd>
5000 </dl>
5001 <dl class="docutils" id="lexer-filetype">
5002 <dt>lexer_filetype</dt>
5003 <dd><p class="first">A filetype name to setup syntax highlighting from another filetype.
5004 This must not be recursive, i.e. it should be a filetype name that
5005 doesn't use the <em>lexer_filetype</em> key itself, e.g.:</p>
5006 <pre class="literal-block">
5007 lexer_filetype=C
5008 #lexer_filetype=C++
5009 </pre>
5010 <p class="last">The second line is wrong, because <tt class="docutils literal">filetypes.cpp</tt> itself uses
5011 <tt class="docutils literal">lexer_filetype=C</tt>, which would be recursive.</p>
5012 </dd>
5013 <dt>symbol_list_sort_mode</dt>
5014 <dd><p class="first">What the default symbol list sort order should be.</p>
5015 <table border="1" class="last docutils">
5016 <colgroup>
5017 <col width="12%" />
5018 <col width="88%" />
5019 </colgroup>
5020 <thead valign="bottom">
5021 <tr><th class="head">Value</th>
5022 <th class="head">Meaning</th>
5023 </tr>
5024 </thead>
5025 <tbody valign="top">
5026 <tr><td>0</td>
5027 <td>Sort tags by name</td>
5028 </tr>
5029 <tr><td>1</td>
5030 <td>Sort tags by appearance (line number)</td>
5031 </tr>
5032 </tbody>
5033 </table>
5034 </dd>
5035 </dl>
5036 <dl class="docutils" id="xml-indent-tags">
5037 <dt>xml_indent_tags</dt>
5038 <dd>If this setting is set to <em>true</em>, a new line after a line ending with an
5039 unclosed XML/HTML tag will be automatically indented. This only applies
5040 to filetypes for which the HTML or XML lexer is used. Such filetypes have
5041 this setting in their system configuration files.</dd>
5042 </dl>
5043 </div>
5044 <div class="section" id="indentation-section">
5045 <h4><a class="toc-backref" href="#id198">[indentation] section</a></h4>
5046 <p>This section allows definition of default indentation settings specific to
5047 the file type, overriding the ones configured in the preferences. This can
5048 be useful for file types requiring specific indentation settings (e.g. tabs
5049 only for Makefile). These settings don't override auto-detection if activated.</p>
5050 <dl class="docutils">
5051 <dt>width</dt>
5052 <dd>The forced indentation width.</dd>
5053 <dt>type</dt>
5054 <dd><p class="first">The forced indentation type.</p>
5055 <table border="1" class="last docutils">
5056 <colgroup>
5057 <col width="18%" />
5058 <col width="82%" />
5059 </colgroup>
5060 <thead valign="bottom">
5061 <tr><th class="head">Value</th>
5062 <th class="head">Indentation type</th>
5063 </tr>
5064 </thead>
5065 <tbody valign="top">
5066 <tr><td>0</td>
5067 <td>Spaces only</td>
5068 </tr>
5069 <tr><td>1</td>
5070 <td>Tabs only</td>
5071 </tr>
5072 <tr><td>2</td>
5073 <td>Mixed (tabs and spaces)</td>
5074 </tr>
5075 </tbody>
5076 </table>
5077 </dd>
5078 </dl>
5079 </div>
5080 <div class="section" id="build-settings-section">
5081 <h4><a class="toc-backref" href="#id199">[build_settings] section</a></h4>
5082 <p>As of Geany 0.19 this section is supplemented by the <a class="reference internal" href="#build-menu-section">[build-menu] section</a>.
5083 Values that are set in the [build-menu] section will override those in this section.</p>
5084 <dl class="docutils">
5085 <dt>error_regex</dt>
5086 <dd><p class="first">This is a regular expression to parse a filename
5087 and line number from build output. If undefined, Geany will fall
5088 back to its default error message parsing.</p>
5089 <p>Only the first two matches will be read by Geany. Geany will look for
5090 a match that is purely digits, and use this for the line number. The
5091 remaining match will be used as the filename.</p>
5092 <p><em>Example:</em> <tt class="docutils literal"><span class="pre">error_regex=(.+):([0-9]+):[0-9]+</span></tt></p>
5093 <p class="last">This will parse a message such as:
5094 <tt class="docutils literal">test.py:7:24: E202 whitespace before ']'</tt></p>
5095 </dd>
5096 </dl>
5097 <p><strong>Build commands</strong></p>
5098 <p>If any build menu item settings have been configured in the Build Menu Commands
5099 dialog or the Build tab of the project preferences dialog then these
5100 settings are stored in the [build-menu] section and override the settings in
5101 this section for that item.</p>
5102 <dl class="docutils">
5103 <dt>compiler</dt>
5104 <dd><p class="first">This item specifies the command to compile source code files. But
5105 it is also possible to use it with interpreted languages like Perl
5106 or Python. With these filetypes you can use this option as a kind of
5107 syntax parser, which sends output to the compiler message window.</p>
5108 <p>You should quote the filename to also support filenames with
5109 spaces. The following wildcards for filenames are available:</p>
5110 <ul class="simple">
5111 <li>%f -- complete filename without path</li>
5112 <li>%e -- filename without path and without extension</li>
5113 </ul>
5114 <p class="last"><em>Example:</em> <tt class="docutils literal">compiler=gcc <span class="pre">-Wall</span> <span class="pre">-c</span> &quot;%f&quot;</tt></p>
5115 </dd>
5116 <dt>linker</dt>
5117 <dd><p class="first">This item specifies the command to link the file. If the file is not
5118 already compiled, it will be compiled while linking. The -o option
5119 is automatically added by Geany. This item works well with GNU gcc,
5120 but may be problematic with other compilers (esp. with the linker).</p>
5121 <p class="last"><em>Example:</em> <tt class="docutils literal">linker=gcc <span class="pre">-Wall</span> &quot;%f&quot;</tt></p>
5122 </dd>
5123 <dt>run_cmd</dt>
5124 <dd><p class="first">Use this item to execute your file. It has to have been built
5125 already. Use the %e wildcard to have only the name of the executable
5126 (i.e. without extension) or use the %f wildcard if you need the
5127 complete filename, e.g. for shell scripts.</p>
5128 <p class="last"><em>Example:</em> <tt class="docutils literal"><span class="pre">run_cmd=&quot;./%e&quot;</span></tt></p>
5129 </dd>
5130 </dl>
5131 </div>
5132 </div>
5133 <div class="section" id="special-file-filetypes-common">
5134 <h3><a class="toc-backref" href="#id200">Special file filetypes.common</a></h3>
5135 <p>There is a special filetype definition file called
5136 filetypes.common. This file defines some general non-filetype-specific
5137 settings.</p>
5138 <p>You can open the user filetypes.common with the
5139 <em>Tools-&gt;Configuration Files-&gt;filetypes.common</em> menu item. This adds
5140 the default settings to the user file if the file doesn't exist.
5141 Alternatively the file can be created manually, adding only the
5142 settings you want to change. All missing settings will be read from
5143 the system file.</p>
5144 <div class="note">
5145 <p class="first admonition-title">Note</p>
5146 <p class="last">See the <a class="reference internal" href="#filetype-configuration">Filetype configuration</a> section for how to define styles.</p>
5147 </div>
5148 <div class="section" id="named-styles-section">
5149 <h4><a class="toc-backref" href="#id201">[named_styles] section</a></h4>
5150 <p>Named styles declared here can be used in the [styling] section of any
5151 filetypes.* file.</p>
5152 <p>For example:</p>
5153 <p><em>In filetypes.common</em>:</p>
5154 <pre class="literal-block">
5155 [named_styles]
5156 foo=0xc00000;0xffffff;false;true
5157 bar=foo
5158 </pre>
5159 <p><em>In filetypes.c</em>:</p>
5160 <pre class="literal-block">
5161 [styling]
5162 comment=foo
5163 </pre>
5164 <p>This saves copying and pasting the whole style definition into several
5165 different files.</p>
5166 <div class="note">
5167 <p class="first admonition-title">Note</p>
5168 <p class="last">You can define aliases for named styles, as shown with the <tt class="docutils literal">bar</tt>
5169 entry in the above example, but they must be declared after the
5170 original style.</p>
5171 </div>
5172 </div>
5173 <div class="section" id="named-colors-section">
5174 <h4><a class="toc-backref" href="#id202">[named_colors] section</a></h4>
5175 <p>Named colors declared here can be used in the <tt class="docutils literal">[styling]</tt> or
5176 <tt class="docutils literal">[named_styles]</tt> section of any filetypes.* file or color scheme.</p>
5177 <p>For example:</p>
5178 <pre class="literal-block">
5179 [named_colors]
5180 my_red_color=#FF0000
5181 my_blue_color=#0000FF
5183 [named_styles]
5184 foo=my_red_color;my_blue_color;false;true
5185 </pre>
5186 <p>This allows to define a color pallete by name so that to change a color
5187 scheme-wide only involves changing the hex value in a single location.</p>
5188 </div>
5189 <div class="section" id="id4">
5190 <h4><a class="toc-backref" href="#id203">[styling] section</a></h4>
5191 <dl class="docutils">
5192 <dt>default</dt>
5193 <dd><p class="first">This is the default style. It is used for styling files without a
5194 filetype set.</p>
5195 <p class="last"><em>Example:</em> <tt class="docutils literal">default=0x000000;0xffffff;false;false</tt></p>
5196 </dd>
5197 <dt>selection</dt>
5198 <dd><p class="first">The style for coloring selected text. The format is:</p>
5199 <ul class="simple">
5200 <li>Foreground color</li>
5201 <li>Background color</li>
5202 <li>Use foreground color</li>
5203 <li>Use background color</li>
5204 </ul>
5205 <p>The colors are only set if the 3rd or 4th argument is true. When
5206 the colors are not overridden, the default is a dark grey
5207 background with syntax highlighted foreground text.</p>
5208 <p class="last"><em>Example:</em> <tt class="docutils literal">selection=0xc0c0c0;0x00007F;true;true</tt></p>
5209 </dd>
5210 <dt>brace_good</dt>
5211 <dd><p class="first">The style for brace highlighting when a matching brace was found.</p>
5212 <p class="last"><em>Example:</em> <tt class="docutils literal">brace_good=0xff0000;0xFFFFFF;true;false</tt></p>
5213 </dd>
5214 <dt>brace_bad</dt>
5215 <dd><p class="first">The style for brace highlighting when no matching brace was found.</p>
5216 <p class="last"><em>Example:</em> <tt class="docutils literal">brace_bad=0x0000ff;0xFFFFFF;true;false</tt></p>
5217 </dd>
5218 <dt>caret</dt>
5219 <dd><p class="first">The style for coloring the caret(the blinking cursor). Only first
5220 and third argument is interpreted.
5221 Set the third argument to true to change the caret into a block caret.</p>
5222 <p class="last"><em>Example:</em> <tt class="docutils literal">caret=0x000000;0x0;false;false</tt></p>
5223 </dd>
5224 <dt>caret_width</dt>
5225 <dd><p class="first">The width for the caret(the blinking cursor). Only the first
5226 argument is interpreted. The width is specified in pixels with
5227 a maximum of three pixel. Use the width 0 to make the caret
5228 invisible.</p>
5229 <p class="last"><em>Example:</em> <tt class="docutils literal">caret=1;0;false;false</tt></p>
5230 </dd>
5231 <dt>current_line</dt>
5232 <dd><p class="first">The style for coloring the background of the current line. Only
5233 the second and third arguments are interpreted. The second argument
5234 is the background color. Use the third argument to enable or
5235 disable background highlighting for the current line (has to be
5236 true/false).</p>
5237 <p class="last"><em>Example:</em> <tt class="docutils literal">current_line=0x0;0xe5e5e5;true;false</tt></p>
5238 </dd>
5239 <dt>indent_guide</dt>
5240 <dd><p class="first">The style for coloring the indentation guides. Only the first and
5241 second arguments are interpreted.</p>
5242 <p class="last"><em>Example:</em> <tt class="docutils literal">indent_guide=0xc0c0c0;0xffffff;false;false</tt></p>
5243 </dd>
5244 <dt>white_space</dt>
5245 <dd><p class="first">The style for coloring the white space if it is shown. The first
5246 both arguments define the foreground and background colors, the
5247 third argument sets whether to use the defined foreground color
5248 or to use the color defined by each filetype for the white space.
5249 The fourth argument defines whether to use the background color.</p>
5250 <p class="last"><em>Example:</em> <tt class="docutils literal">white_space=0xc0c0c0;0xffffff;true;true</tt></p>
5251 </dd>
5252 <dt>margin_linenumber</dt>
5253 <dd>Line number margin foreground and background colors.</dd>
5254 </dl>
5255 <dl class="docutils" id="folding-settings">
5256 <dt>margin_folding</dt>
5257 <dd>Fold margin foreground and background colors.</dd>
5258 <dt>fold_symbol_highlight</dt>
5259 <dd>Highlight color of folding symbols.</dd>
5260 <dt>folding_style</dt>
5261 <dd><p class="first">The style of folding icons. Only first and second arguments are
5262 used.</p>
5263 <p>Valid values for the first argument are:</p>
5264 <ul class="simple">
5265 <li>1 -- for boxes</li>
5266 <li>2 -- for circles</li>
5267 <li>3 -- for arrows</li>
5268 <li>4 -- for +/-</li>
5269 </ul>
5270 <p>Valid values for the second argument are:</p>
5271 <ul class="simple">
5272 <li>0 -- for no lines</li>
5273 <li>1 -- for straight lines</li>
5274 <li>2 -- for curved lines</li>
5275 </ul>
5276 <p><em>Default:</em> <tt class="docutils literal">folding_style=1;1;</tt></p>
5277 <p class="last"><em>Arrows:</em> <tt class="docutils literal">folding_style=3;0;</tt></p>
5278 </dd>
5279 <dt>folding_horiz_line</dt>
5280 <dd><p class="first">Draw a thin horizontal line at the line where text is folded. Only
5281 first argument is used.</p>
5282 <p>Valid values for the first argument are:</p>
5283 <ul class="simple">
5284 <li>0 -- disable, do not draw a line</li>
5285 <li>1 -- draw the line above folded text</li>
5286 <li>2 -- draw the line below folded text</li>
5287 </ul>
5288 <p class="last"><em>Example:</em> <tt class="docutils literal">folding_horiz_line=0;0;false;false</tt></p>
5289 </dd>
5290 <dt>line_wrap_visuals</dt>
5291 <dd><p class="first">First argument: drawing of visual flags to indicate a line is wrapped.
5292 This is a bitmask of the values:</p>
5293 <ul class="simple">
5294 <li>0 -- No visual flags</li>
5295 <li>1 -- Visual flag at end of subline of a wrapped line</li>
5296 <li>2 -- Visual flag at begin of subline of a wrapped line. Subline is
5297 indented by at least 1 to make room for the flag.</li>
5298 </ul>
5299 <p>Second argument: wether the visual flags to indicate a line is wrapped
5300 are drawn near the border or near the text. This is a bitmask of the values:</p>
5301 <ul class="simple">
5302 <li>0 -- Visual flags drawn near border</li>
5303 <li>1 -- Visual flag at end of subline drawn near text</li>
5304 <li>2 -- Visual flag at begin of subline drawn near text</li>
5305 </ul>
5306 <p>Only first and second arguments are interpreted.</p>
5307 <p class="last"><em>Example:</em> <tt class="docutils literal">line_wrap_visuals=3;0;false;false</tt></p>
5308 </dd>
5309 <dt>line_wrap_indent</dt>
5310 <dd><p class="first">First argument: sets the size of indentation of sublines for wrapped lines
5311 in terms of the width of a space, only used when the second argument is <tt class="docutils literal">0</tt>.</p>
5312 <p>Second argument: wrapped sublines can be indented to the position of their
5313 first subline or one more indent level. Possible values:</p>
5314 <ul class="simple">
5315 <li>0 - Wrapped sublines aligned to left of window plus amount set by the first argument</li>
5316 <li>1 - Wrapped sublines are aligned to first subline indent (use the same indentation)</li>
5317 <li>2 - Wrapped sublines are aligned to first subline indent plus one more level of indentation</li>
5318 </ul>
5319 <p>Only first and second arguments are interpreted.</p>
5320 <p class="last"><em>Example:</em> <tt class="docutils literal">line_wrap_indent=0;1;false;false</tt></p>
5321 </dd>
5322 <dt>translucency</dt>
5323 <dd><p class="first">Translucency for the current line (first argument) and the selection
5324 (second argument). Values between 0 and 256 are accepted.</p>
5325 <p>Note for Windows 95, 98 and ME users:
5326 keep this value at 256 to disable translucency otherwise Geany might crash.</p>
5327 <p>Only the first and second arguments are interpreted.</p>
5328 <p class="last"><em>Example:</em> <tt class="docutils literal">translucency=256;256;false;false</tt></p>
5329 </dd>
5330 <dt>marker_line</dt>
5331 <dd><p class="first">The style for a highlighted line (e.g when using Goto line or goto tag).
5332 The foreground color (first argument) is only used when the Markers margin
5333 is enabled (see View menu).</p>
5334 <p>Only the first and second arguments are interpreted.</p>
5335 <p class="last"><em>Example:</em> <tt class="docutils literal">marker_line=0x000000;0xffff00;false;false</tt></p>
5336 </dd>
5337 <dt>marker_search</dt>
5338 <dd><p class="first">The style for a marked search results (when using &quot;Mark&quot; in Search dialogs).
5339 The second argument sets the background color for the drawn rectangle.</p>
5340 <p>Only the second argument is interpreted.</p>
5341 <p class="last"><em>Example:</em> <tt class="docutils literal">marker_search=0x000000;0xb8f4b8;false;false</tt></p>
5342 </dd>
5343 <dt>marker_mark</dt>
5344 <dd><p class="first">The style for a marked line (e.g when using the &quot;Toggle Marker&quot; keybinding
5345 (Ctrl-M)). The foreground color (first argument) is only used
5346 when the Markers margin is enabled (see View menu).</p>
5347 <p>Only the first and second arguments are interpreted.</p>
5348 <p class="last"><em>Example:</em> <tt class="docutils literal">marker_mark=0x000000;0xb8f4b8;false;false</tt></p>
5349 </dd>
5350 <dt>marker_translucency</dt>
5351 <dd><p class="first">Translucency for the line marker (first argument) and the search marker
5352 (second argument). Values between 0 and 256 are accepted.</p>
5353 <p>Note for Windows 95, 98 and ME users:
5354 keep this value at 256 to disable translucency otherwise Geany might crash.</p>
5355 <p>Only the first and second arguments are interpreted.</p>
5356 <p class="last"><em>Example:</em> <tt class="docutils literal">marker_translucency=256;256;false;false</tt></p>
5357 </dd>
5358 <dt>line_height</dt>
5359 <dd><p class="first">Amount of space to be drawn above and below the line's baseline.
5360 The first argument defines the amount of space to be drawn above the line, the second
5361 argument defines the amount of space to be drawn below.</p>
5362 <p>Only the first and second arguments are interpreted.</p>
5363 <p class="last"><em>Example:</em> <tt class="docutils literal">line_height=0;0;false;false</tt></p>
5364 </dd>
5365 <dt>calltips</dt>
5366 <dd><p class="first">The style for coloring the calltips. The first two arguments
5367 define the foreground and background colors, the third and fourth
5368 arguments set whether to use the defined colors.</p>
5369 <p class="last"><em>Example:</em> <tt class="docutils literal">calltips=0xc0c0c0;0xffffff;false;false</tt></p>
5370 </dd>
5371 </dl>
5372 </div>
5373 <div class="section" id="id5">
5374 <h4><a class="toc-backref" href="#id204">[settings] section</a></h4>
5375 <dl class="docutils">
5376 <dt>whitespace_chars</dt>
5377 <dd><p class="first">Characters to treat as whitespace. These characters are ignored
5378 when moving, selecting and deleting across word boundaries
5379 (see <a class="reference internal" href="#scintilla-keyboard-commands">Scintilla keyboard commands</a>).</p>
5380 <p>This should include space (\s) and tab (\t).</p>
5381 <p class="last"><em>Example:</em> <tt class="docutils literal"><span class="pre">whitespace_chars=\s\t!\&quot;#$%&amp;'()*+,-./:;&lt;=&gt;?&#64;[\\]^`{|}~</span></tt></p>
5382 </dd>
5383 </dl>
5384 </div>
5385 </div>
5386 </div>
5387 <div class="section" id="filetype-extensions">
5388 <h2><a class="toc-backref" href="#id205">Filetype extensions</a></h2>
5389 <p>To change the default filetype extension used when saving a new file,
5390 see <a class="reference internal" href="#filetype-definition-files">Filetype definition files</a>.</p>
5391 <p>You can override the list of file extensions that Geany uses to detect
5392 filetypes using the user <tt class="docutils literal">filetype_extensions.conf</tt> file. Use the
5393 <em>Tools-&gt;Configuration Files-&gt;filetype_extensions.conf</em> menu item. See
5394 also <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>.</p>
5395 <p>You should only list lines for filetype extensions that you want to
5396 override in the user configuration file and remove or comment out
5397 others. The patterns are listed after the <tt class="docutils literal">=</tt> sign, using a
5398 semi-colon separated list of patterns which should be matched for
5399 that filetype.</p>
5400 <p>For example, to override the filetype extensions for Make, the file
5401 should look like:</p>
5402 <pre class="literal-block">
5403 [Extensions]
5404 Make=Makefile*;*.mk;Buildfile;
5405 </pre>
5406 </div>
5407 <div class="section" id="filetype-group-membership">
5408 <h2><a class="toc-backref" href="#id206">Filetype group membership</a></h2>
5409 <p>Group membership is also stored in <tt class="docutils literal">filetype_extensions.conf</tt>. This
5410 file is used to store information Geany needs at startup, whereas the
5411 separate filetype definition files hold information only needed when
5412 a document with their filetype is used.</p>
5413 <p>The format looks like:</p>
5414 <pre class="literal-block">
5415 [Groups]
5416 Programming=C;C++;
5417 Script=Perl;Python;
5418 Markup=HTML;XML;
5419 Misc=Diff;Conf;
5420 None=None;
5421 </pre>
5422 <p>The key names cannot be configured.</p>
5423 <div class="note">
5424 <p class="first admonition-title">Note</p>
5425 <p class="last">Group membership is only read at startup.</p>
5426 </div>
5427 </div>
5428 <div class="section" id="preferences-file-format">
5429 <h2><a class="toc-backref" href="#id207">Preferences file format</a></h2>
5430 <p>The user preferences file <tt class="docutils literal">geany.conf</tt> holds settings for all the items configured
5431 in the preferences dialog. This file should not be edited while Geany is running
5432 as the file will be overwritten when the preferences in Geany are changed or Geany
5433 is quit.</p>
5434 <div class="section" id="build-menu-section">
5435 <h3><a class="toc-backref" href="#id208">[build-menu] section</a></h3>
5436 <p>The [build-menu] section contains the configuration of the build menu.
5437 This section can occur in filetype, preferences and project files and
5438 always has the format described here. Different menu items are loaded
5439 from different files, see the table in the <a class="reference internal" href="#build-menu-configuration">Build Menu Configuration</a>
5440 section for details. All the settings can be configured from the dialogs
5441 except the execute command in filetype files and filetype definitions in
5442 the project file, so these are the only ones which need hand editing.</p>
5443 <p>The build-menu section stores one entry for each setting for each menu item that
5444 is configured. The keys for these settings have the format:</p>
5445 <blockquote>
5446 <tt class="docutils literal">GG_NN_FF</tt></blockquote>
5447 <p>where:</p>
5448 <ul class="simple">
5449 <li>GG - is the menu item group,<ul>
5450 <li>FT for filetype</li>
5451 <li>NF for independent (non-filetype)</li>
5452 <li>EX for execute</li>
5453 </ul>
5454 </li>
5455 <li>NN - is a two decimal digit number of the item within the group,
5456 starting at 00</li>
5457 <li>FF - is the field,<ul>
5458 <li>LB for label</li>
5459 <li>CM for command</li>
5460 <li>WD for working directory</li>
5461 </ul>
5462 </li>
5463 </ul>
5464 </div>
5465 </div>
5466 <div class="section" id="project-file-format">
5467 <h2><a class="toc-backref" href="#id209">Project file format</a></h2>
5468 <p>The project file contains project related settings and possibly a
5469 record of the current session files.</p>
5470 <div class="section" id="build-menu-additions">
5471 <h3><a class="toc-backref" href="#id210">[build-menu] additions</a></h3>
5472 <p>The project file also can have extra fields in the [build-menu] section
5473 in addition to those listed in <a class="reference internal" href="#build-menu-section">[build-menu] section</a> above.</p>
5474 <p>When filetype menu items are configured for the project they are stored
5475 in the project file.</p>
5476 <p>The <tt class="docutils literal">filetypes</tt> entry is a list of the filetypes which exist in the
5477 project file.</p>
5478 <p>For each filetype the entries for that filetype have the format defined in
5479 <a class="reference internal" href="#build-menu-section">[build-menu] section</a> but the key is prefixed by the name of the filetype
5480 as it appears in the <tt class="docutils literal">filetypes</tt> entry, eg the entry for the label of
5481 filetype menu item 0 for the C filetype would be</p>
5482 <blockquote>
5483 <tt class="docutils literal">CFT_00_LB=Label</tt></blockquote>
5484 </div>
5485 </div>
5486 <div class="section" id="templates">
5487 <h2><a class="toc-backref" href="#id211">Templates</a></h2>
5488 <p>Geany supports the following templates:</p>
5489 <ul class="simple">
5490 <li>ChangeLog entry</li>
5491 <li>File header</li>
5492 <li>Function description</li>
5493 <li>Short GPL notice</li>
5494 <li>Short BSD notice</li>
5495 <li>File templates</li>
5496 </ul>
5497 <p>To use these templates, just open the Edit menu or open the popup menu
5498 by right-clicking in the editor widget, and choose &quot;Insert Comments&quot;
5499 and insert templates as you want.</p>
5500 <p>Some templates (like File header or ChangeLog entry) will always be
5501 inserted at the top of the file.</p>
5502 <p>To insert a function description, the cursor must be inside
5503 of the function, so that the function name can be determined
5504 automatically. The description will be positioned correctly one line
5505 above the function, just check it out. If the cursor is not inside
5506 of a function or the function name cannot be determined, the inserted
5507 function description won't contain the correct function name but &quot;unknown&quot;
5508 instead.</p>
5509 <div class="note">
5510 <p class="first admonition-title">Note</p>
5511 <p class="last">Geany automatically reloads template information when it notices you
5512 save a file in the user's template configuration directory. You can
5513 also force this by selecting <em>Tools-&gt;Reload Configuration</em>.</p>
5514 </div>
5515 <div class="section" id="template-meta-data">
5516 <h3><a class="toc-backref" href="#id212">Template meta data</a></h3>
5517 <p>Meta data can be used with all templates, but by default user set
5518 meta data is only used for the ChangeLog and File header templates.</p>
5519 <p>In the configuration dialog you can find a tab &quot;Templates&quot; (see
5520 <a class="reference internal" href="#template-preferences">Template preferences</a>). You can define the default values
5521 which will be inserted in the templates.</p>
5522 </div>
5523 <div class="section" id="file-templates">
5524 <h3><a class="toc-backref" href="#id213">File templates</a></h3>
5525 <p>File templates are templates used as the basis of a new file. To
5526 use them, choose the <em>New (with Template)</em> menu item from the <em>File</em>
5527 menu.</p>
5528 <p>By default, file templates are installed for some filetypes. Custom
5529 file templates can be added by creating the appropriate template file. You can
5530 also edit the default file templates.</p>
5531 <p>The file's contents are just the text to place in the document, with
5532 optional template wildcards like <tt class="docutils literal">{fileheader}</tt>. The fileheader
5533 wildcard can be placed anywhere, but it's usually put on the first
5534 line of the file, followed by a blank line.</p>
5535 <div class="section" id="adding-file-templates">
5536 <h4><a class="toc-backref" href="#id214">Adding file templates</a></h4>
5537 <p>File templates are read from <tt class="docutils literal">templates/files</tt> under the
5538 <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>.</p>
5539 <p>The filetype to use is detected from the template file's extension, if
5540 any. For example, creating a file <tt class="docutils literal">module.c</tt> would add a menu item
5541 which created a new document with the filetype set to 'C'.</p>
5542 <p>The template file is read from disk when the corresponding menu item is
5543 clicked.</p>
5544 </div>
5545 </div>
5546 <div class="section" id="customizing-templates">
5547 <h3><a class="toc-backref" href="#id215">Customizing templates</a></h3>
5548 <p>Each template can be customized to your needs. The templates are
5549 stored in the <tt class="docutils literal"><span class="pre">~/.config/geany/templates/</span></tt> directory (see the section called
5550 <a class="reference internal" href="#command-line-options">Command line options</a> for further information about the configuration
5551 directory). Just open the desired template with an editor (ideally,
5552 Geany ;-) ) and edit the template to your needs. There are some
5553 wildcards which will be automatically replaced by Geany at startup.</p>
5554 <div class="section" id="template-wildcards">
5555 <h4><a class="toc-backref" href="#id216">Template wildcards</a></h4>
5556 <p>All wildcards must be enclosed by &quot;{&quot; and &quot;}&quot;, e.g. {date}.</p>
5557 <p><strong>Wildcards for character escaping</strong></p>
5558 <table border="1" class="docutils">
5559 <colgroup>
5560 <col width="14%" />
5561 <col width="46%" />
5562 <col width="40%" />
5563 </colgroup>
5564 <thead valign="bottom">
5565 <tr><th class="head">Wildcard</th>
5566 <th class="head">Description</th>
5567 <th class="head">Available in</th>
5568 </tr>
5569 </thead>
5570 <tbody valign="top">
5571 <tr><td>ob</td>
5572 <td>{ Opening Brace (used to prevent other
5573 wildcards being expanded).</td>
5574 <td>file templates, file header, snippets.</td>
5575 </tr>
5576 <tr><td>cb</td>
5577 <td>} Closing Brace.</td>
5578 <td>file templates, file header, snippets.</td>
5579 </tr>
5580 <tr><td>pc</td>
5581 <td>% Percent (used to escape e.g. %block% in
5582 snippets).</td>
5583 <td>snippets.</td>
5584 </tr>
5585 </tbody>
5586 </table>
5587 <p><strong>Global wildcards</strong></p>
5588 <p>These are configurable, see <a class="reference internal" href="#template-preferences">Template preferences</a>.</p>
5589 <table border="1" class="docutils">
5590 <colgroup>
5591 <col width="14%" />
5592 <col width="46%" />
5593 <col width="40%" />
5594 </colgroup>
5595 <thead valign="bottom">
5596 <tr><th class="head">Wildcard</th>
5597 <th class="head">Description</th>
5598 <th class="head">Available in</th>
5599 </tr>
5600 </thead>
5601 <tbody valign="top">
5602 <tr><td>developer</td>
5603 <td>The name of the developer.</td>
5604 <td>file templates, file header,
5605 function description, ChangeLog entry,
5606 bsd, gpl, snippets.</td>
5607 </tr>
5608 <tr><td>initial</td>
5609 <td>The developer's initials, e.g. &quot;ET&quot; for
5610 Enrico Tröger or &quot;JFD&quot; for John Foobar Doe.</td>
5611 <td>file templates, file header,
5612 function description, ChangeLog entry,
5613 bsd, gpl, snippets.</td>
5614 </tr>
5615 <tr><td>mail</td>
5616 <td>The email address of the developer.</td>
5617 <td>file templates, file header,
5618 function description, ChangeLog entry,
5619 bsd, gpl, snippets.</td>
5620 </tr>
5621 <tr><td>company</td>
5622 <td>The company the developer is working for.</td>
5623 <td>file templates, file header,
5624 function description, ChangeLog entry,
5625 bsd, gpl, snippets.</td>
5626 </tr>
5627 <tr><td>version</td>
5628 <td>The initial version of a new file.</td>
5629 <td>file templates, file header,
5630 function description, ChangeLog entry,
5631 bsd, gpl, snippets.</td>
5632 </tr>
5633 </tbody>
5634 </table>
5635 <p><strong>Date &amp; time wildcards</strong></p>
5636 <p>The format for these wildcards can be changed in the preferences
5637 dialog, see <a class="reference internal" href="#template-preferences">Template preferences</a>. You can use any conversion
5638 specifiers which can be used with the ANSI C strftime function.
5639 For details please see <a class="reference external" href="http://man.cx/strftime">http://man.cx/strftime</a>.</p>
5640 <table border="1" class="docutils">
5641 <colgroup>
5642 <col width="14%" />
5643 <col width="46%" />
5644 <col width="40%" />
5645 </colgroup>
5646 <thead valign="bottom">
5647 <tr><th class="head">Wildcard</th>
5648 <th class="head">Description</th>
5649 <th class="head">Available in</th>
5650 </tr>
5651 </thead>
5652 <tbody valign="top">
5653 <tr><td>year</td>
5654 <td>The current year. Default format is: YYYY.</td>
5655 <td>file templates, file header,
5656 function description, ChangeLog entry,
5657 bsd, gpl, snippets.</td>
5658 </tr>
5659 <tr><td>date</td>
5660 <td>The current date. Default format:
5661 YYYY-MM-DD.</td>
5662 <td>file templates, file header,
5663 function description, ChangeLog entry,
5664 bsd, gpl, snippets.</td>
5665 </tr>
5666 <tr><td>datetime</td>
5667 <td>The current date and time. Default format:
5668 DD.MM.YYYY HH:mm:ss ZZZZ.</td>
5669 <td>file templates, file header,
5670 function description, ChangeLog entry,
5671 bsd, gpl, snippets.</td>
5672 </tr>
5673 </tbody>
5674 </table>
5675 <p><strong>Dynamic wildcards</strong></p>
5676 <table border="1" class="docutils">
5677 <colgroup>
5678 <col width="14%" />
5679 <col width="46%" />
5680 <col width="40%" />
5681 </colgroup>
5682 <thead valign="bottom">
5683 <tr><th class="head">Wildcard</th>
5684 <th class="head">Description</th>
5685 <th class="head">Available in</th>
5686 </tr>
5687 </thead>
5688 <tbody valign="top">
5689 <tr><td>untitled</td>
5690 <td>The string &quot;untitled&quot; (this will be
5691 translated to your locale), used in
5692 file templates.</td>
5693 <td>file templates, file header,
5694 function description, ChangeLog entry,
5695 bsd, gpl, snippets.</td>
5696 </tr>
5697 <tr><td>geanyversion</td>
5698 <td>The actual Geany version, e.g.
5699 &quot;Geany 1.23&quot;.</td>
5700 <td>file templates, file header,
5701 function description, ChangeLog entry,
5702 bsd, gpl, snippets.</td>
5703 </tr>
5704 <tr><td>filename</td>
5705 <td>The filename of the current file.
5706 For new files, it's only replaced when
5707 first saving if found on the first 4 lines
5708 of the file.</td>
5709 <td>file header, snippets, file
5710 templates.</td>
5711 </tr>
5712 <tr><td>project</td>
5713 <td>The current project's name, if any.</td>
5714 <td>file header, snippets, file templates.</td>
5715 </tr>
5716 <tr><td>description</td>
5717 <td>The current project's description, if any.</td>
5718 <td>file header, snippets, file templates.</td>
5719 </tr>
5720 <tr><td>functionname</td>
5721 <td>The function name of the function at the
5722 cursor position. This wildcard will only be
5723 replaced in the function description
5724 template.</td>
5725 <td>function description.</td>
5726 </tr>
5727 <tr><td>command:path</td>
5728 <td>Executes the specified command and replace
5729 the wildcard with the command's standard
5730 output. See <a class="reference internal" href="#special-command-wildcard">Special {command:} wildcard</a>
5731 for details.</td>
5732 <td>file templates, file header,
5733 function description, ChangeLog entry,
5734 bsd, gpl, snippets.</td>
5735 </tr>
5736 </tbody>
5737 </table>
5738 <p><strong>Template insertion wildcards</strong></p>
5739 <table border="1" class="docutils">
5740 <colgroup>
5741 <col width="14%" />
5742 <col width="46%" />
5743 <col width="40%" />
5744 </colgroup>
5745 <thead valign="bottom">
5746 <tr><th class="head">Wildcard</th>
5747 <th class="head">Description</th>
5748 <th class="head">Available in</th>
5749 </tr>
5750 </thead>
5751 <tbody valign="top">
5752 <tr><td>gpl</td>
5753 <td>This wildcard inserts a short GPL notice.</td>
5754 <td>file header.</td>
5755 </tr>
5756 <tr><td>bsd</td>
5757 <td>This wildcard inserts a BSD licence notice.</td>
5758 <td>file header.</td>
5759 </tr>
5760 <tr><td>fileheader</td>
5761 <td>The file header template. This wildcard
5762 will only be replaced in file templates.</td>
5763 <td>snippets, file templates.</td>
5764 </tr>
5765 </tbody>
5766 </table>
5767 <div class="section" id="special-command-wildcard">
5768 <h5><a class="toc-backref" href="#id217">Special {command:} wildcard</a></h5>
5769 <p>The {command:} wildcard is a special one because it can execute
5770 a specified command and put the command's output (stdout) into
5771 the template.</p>
5772 <p>Example:</p>
5773 <pre class="literal-block">
5774 {command:uname -a}
5775 </pre>
5776 <p>will result in:</p>
5777 <pre class="literal-block">
5778 Linux localhost 2.6.9-023stab046.2-smp #1 SMP Mon Dec 10 15:04:55 MSK 2007 x86_64 GNU/Linux
5779 </pre>
5780 <p>Using this wildcard you can insert nearly any arbitrary text into the
5781 template.</p>
5782 <p>In the environment of the executed command the variables
5783 <tt class="docutils literal">GEANY_FILENAME</tt>, <tt class="docutils literal">GEANY_FILETYPE</tt> and <tt class="docutils literal">GEANY_FUNCNAME</tt> are set.
5784 The value of these variables is filled in only if Geany knows about it.
5785 For example, <tt class="docutils literal">GEANY_FUNCNAME</tt> is only filled within the function
5786 description template. However, these variables are <tt class="docutils literal">always</tt> set,
5787 just maybe with an empty value.
5788 You can easily access them e.g. within an executed shell script using:</p>
5789 <pre class="literal-block">
5790 $GEANY_FILENAME
5791 </pre>
5792 <div class="note">
5793 <p class="first admonition-title">Note</p>
5794 <p class="last">If the specified command could not be found or not executed, the wildcard is substituted
5795 by an empty string. In such cases, you can find the occurred error message on Geany's
5796 standard error and in the Help-&gt;Debug Messages dialog.</p>
5797 </div>
5798 </div>
5799 </div>
5800 </div>
5801 </div>
5802 <div class="section" id="customizing-the-toolbar">
5803 <h2><a class="toc-backref" href="#id218">Customizing the toolbar</a></h2>
5804 <p>You can add, remove and reorder the elements in the toolbar by using
5805 the toolbar editor, or by manually editing the configuration file
5806 <tt class="docutils literal">ui_toolbar.xml</tt>.</p>
5807 <p>The toolbar editor can be opened from the preferences editor on the Toolbar tab or
5808 by right-clicking on the toolbar itself and choosing it from the menu.</p>
5809 <div class="section" id="manually-editing-the-toolbar-layout">
5810 <h3><a class="toc-backref" href="#id219">Manually editing the toolbar layout</a></h3>
5811 <p>To override the system-wide configuration file, copy it to your user
5812 configuration directory (see <a class="reference internal" href="#configuration-file-paths">Configuration file paths</a>).</p>
5813 <p>For example:</p>
5814 <pre class="literal-block">
5815 % cp /usr/local/share/geany/ui_toolbar.xml /home/username/.config/geany/
5816 </pre>
5817 <p>Then edit it and add any of the available elements listed in the file or remove
5818 any of the existing elements. Of course, you can also reorder the elements as
5819 you wish and add or remove additional separators.
5820 This file must be valid XML, otherwise the global toolbar UI definition
5821 will be used instead.</p>
5822 <p>Your changes are applied once you save the file.</p>
5823 <div class="note">
5824 <p class="first admonition-title">Note</p>
5825 <ol class="last arabic simple">
5826 <li>You cannot add new actions which are not listed below.</li>
5827 <li>Everything you add or change must be inside the /ui/toolbar/ path.</li>
5828 </ol>
5829 </div>
5830 </div>
5831 <div class="section" id="available-toolbar-elements">
5832 <h3><a class="toc-backref" href="#id220">Available toolbar elements</a></h3>
5833 <table border="1" class="docutils">
5834 <colgroup>
5835 <col width="19%" />
5836 <col width="81%" />
5837 </colgroup>
5838 <thead valign="bottom">
5839 <tr><th class="head">Element name</th>
5840 <th class="head">Description</th>
5841 </tr>
5842 </thead>
5843 <tbody valign="top">
5844 <tr><td>New</td>
5845 <td>Create a new file</td>
5846 </tr>
5847 <tr><td>Open</td>
5848 <td>Open an existing file</td>
5849 </tr>
5850 <tr><td>Save</td>
5851 <td>Save the current file</td>
5852 </tr>
5853 <tr><td>SaveAll</td>
5854 <td>Save all open files</td>
5855 </tr>
5856 <tr><td>Reload</td>
5857 <td>Reload the current file from disk</td>
5858 </tr>
5859 <tr><td>Close</td>
5860 <td>Close the current file</td>
5861 </tr>
5862 <tr><td>CloseAll</td>
5863 <td>Close all open files</td>
5864 </tr>
5865 <tr><td>Print</td>
5866 <td>Print the current file</td>
5867 </tr>
5868 <tr><td>Cut</td>
5869 <td>Cut the current selection</td>
5870 </tr>
5871 <tr><td>Copy</td>
5872 <td>Copy the current selection</td>
5873 </tr>
5874 <tr><td>Paste</td>
5875 <td>Paste the contents of the clipboard</td>
5876 </tr>
5877 <tr><td>Delete</td>
5878 <td>Delete the current selection</td>
5879 </tr>
5880 <tr><td>Undo</td>
5881 <td>Undo the last modification</td>
5882 </tr>
5883 <tr><td>Redo</td>
5884 <td>Redo the last modification</td>
5885 </tr>
5886 <tr><td>NavBack</td>
5887 <td>Navigate back a location</td>
5888 </tr>
5889 <tr><td>NavFor</td>
5890 <td>Navigate forward a location</td>
5891 </tr>
5892 <tr><td>Compile</td>
5893 <td>Compile the current file</td>
5894 </tr>
5895 <tr><td>Build</td>
5896 <td>Build the current file, includes a submenu for Make commands. Geany
5897 remembers the last chosen action from the submenu and uses this as default
5898 action when the button itself is clicked.</td>
5899 </tr>
5900 <tr><td>Run</td>
5901 <td>Run or view the current file</td>
5902 </tr>
5903 <tr><td>Color</td>
5904 <td>Open a color chooser dialog, to interactively pick colors from a palette</td>
5905 </tr>
5906 <tr><td>ZoomIn</td>
5907 <td>Zoom in the text</td>
5908 </tr>
5909 <tr><td>ZoomOut</td>
5910 <td>Zoom out the text</td>
5911 </tr>
5912 <tr><td>UnIndent</td>
5913 <td>Decrease indentation</td>
5914 </tr>
5915 <tr><td>Indent</td>
5916 <td>Increase indentation</td>
5917 </tr>
5918 <tr><td>Replace</td>
5919 <td>Replace text in the current document</td>
5920 </tr>
5921 <tr><td>SearchEntry</td>
5922 <td>The search field belonging to the 'Search' element (can be used alone)</td>
5923 </tr>
5924 <tr><td>Search</td>
5925 <td>Find the entered text in the current file (only useful if you also
5926 use 'SearchEntry')</td>
5927 </tr>
5928 <tr><td>GotoEntry</td>
5929 <td>The goto field belonging to the 'Goto' element (can be used alone)</td>
5930 </tr>
5931 <tr><td>Goto</td>
5932 <td>Jump to the entered line number (only useful if you also use 'GotoEntry')</td>
5933 </tr>
5934 <tr><td>Preferences</td>
5935 <td>Show the preferences dialog</td>
5936 </tr>
5937 <tr><td>Quit</td>
5938 <td>Quit Geany</td>
5939 </tr>
5940 </tbody>
5941 </table>
5942 </div>
5943 </div>
5944 </div>
5945 <div class="section" id="plugin-documentation">
5946 <h1><a class="toc-backref" href="#id221">Plugin documentation</a></h1>
5947 <div class="section" id="html-characters">
5948 <h2><a class="toc-backref" href="#id222">HTML Characters</a></h2>
5949 <p>The HTML Characters plugin helps when working with special
5950 characters in XML/HTML, e.g. German Umlauts ü and ä.</p>
5951 <div class="section" id="insert-entity-dialog">
5952 <h3><a class="toc-backref" href="#id223">Insert entity dialog</a></h3>
5953 <p>When the plugin is enabled, you can insert special character
5954 entities using <em>Tools-&gt;Insert Special HTML Characters</em>.</p>
5955 <p>This opens up a dialog where you can find a huge amount of special
5956 characters sorted by category that you might like to use inside your
5957 document. You can expand and collapse the categories by clicking on
5958 the little arrow on the left hand side. Once you have found the
5959 desired character click on it and choose &quot;Insert&quot;. This will insert
5960 the entity for the character at the current cursor position. You
5961 might also like to double click the chosen entity instead.</p>
5962 </div>
5963 <div class="section" id="replace-special-chars-by-its-entity">
5964 <h3><a class="toc-backref" href="#id224">Replace special chars by its entity</a></h3>
5965 <p>To help make a XML/HTML document valid the plugin supports
5966 replacement of special chars known by the plugin. Both bulk
5967 replacement and immediate replacement during typing are supported.</p>
5968 <dl class="docutils">
5969 <dt>A few characters will not be replaced. These are</dt>
5970 <dd><ul class="first last simple">
5971 <li>&quot;</li>
5972 <li>&amp;</li>
5973 <li>&lt;</li>
5974 <li>&gt;</li>
5975 <li>(<cite>&amp;nbsp;</cite>)</li>
5976 </ul>
5977 </dd>
5978 </dl>
5979 <div class="section" id="at-typing-time">
5980 <h4><a class="toc-backref" href="#id225">At typing time</a></h4>
5981 <p>You can activate/deactivate this feature using the <em>Tools-&gt;HTML
5982 Replacement-&gt;Auto-replace Special Characters</em> menu item. If it's
5983 activated, all special characters (beside the given exceptions from
5984 above) known by the plugin will be replaced by their entities.</p>
5985 <p>You could also set a keybinding for the plugin to toggle the status
5986 of this feature.</p>
5987 </div>
5988 <div class="section" id="bulk-replacement">
5989 <h4><a class="toc-backref" href="#id226">Bulk replacement</a></h4>
5990 <p>After inserting a huge amount of text, e.g. by using copy &amp; paste, the
5991 plugin allows bulk replacement of all known characters (beside the
5992 mentioned exceptions). You can find the function under the same
5993 menu at <em>Tools-&gt;HTML Replacement-&gt;Replace Characters in Selection</em>, or
5994 configure a keybinding for the plugin.</p>
5995 </div>
5996 </div>
5997 </div>
5998 <div class="section" id="save-actions">
5999 <h2><a class="toc-backref" href="#id227">Save Actions</a></h2>
6000 <div class="section" id="instant-save">
6001 <h3><a class="toc-backref" href="#id228">Instant Save</a></h3>
6002 <p>This plugin sets on every new file (<em>File-&gt;New</em> or <em>File-&gt;New (with template)</em>)
6003 a randomly chosen filename and set its filetype appropriate to the used template
6004 or when no template was used, to a configurable default filetype.
6005 This enables you to quickly compile, build and/or run the new file without the
6006 need to give it an explicit filename using the Save As dialog. This might be
6007 useful when you often create new files just for testing some code or something
6008 similar.</p>
6009 </div>
6010 <div class="section" id="backup-copy">
6011 <h3><a class="toc-backref" href="#id229">Backup Copy</a></h3>
6012 <p>This plugin creates a backup copy of the current file in Geany when it is
6013 saved. You can specify the directory where the backup copy is saved and
6014 you can configure the automatically added extension in the configure dialog
6015 in Geany's plugin manager.</p>
6016 <p>After the plugin was loaded in Geany's plugin manager, every file is
6017 copied into the configured backup directory when the file is saved in Geany.</p>
6018 </div>
6019 </div>
6020 </div>
6021 <div class="section" id="contributing-to-this-document">
6022 <h1><a class="toc-backref" href="#id230">Contributing to this document</a></h1>
6023 <p>This document (<tt class="docutils literal">geany.txt</tt>) is written in <a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a>
6024 (or &quot;reST&quot;). The source file for it is located in Geany's <tt class="docutils literal">doc</tt>
6025 subdirectory. If you intend on making changes, you should grab the
6026 source right from Git to make sure you've got the newest version. After
6027 editing the file, to build the HTML document to see how your changes
6028 look, run &quot;<tt class="docutils literal">make doc</tt>&quot; in the subdirectory <tt class="docutils literal">doc</tt> of Geany's source
6029 directory. This regenerates the <tt class="docutils literal">geany.html</tt> file. To generate a PDF
6030 file, use the command &quot;<tt class="docutils literal">make pdf</tt>&quot; which should generate a file called
6031 geany-1.23.pdf.</p>
6032 <p>After you are happy with your changes, create a patch e.g. by using:</p>
6033 <pre class="literal-block">
6034 % git diff geany.txt &gt; foo.patch
6035 </pre>
6036 <p>or even better, by creating a Git-formatted patch which will keep authoring
6037 and description data, by first committing your changes (doing so in a fresh
6038 new branch is recommended for <cite>matser</cite> not to diverge from upstream) and then
6039 using git format-patch:</p>
6040 <pre class="literal-block">
6041 % git checkout -b my-documentation-changes # create a fresh branch
6042 % git commit geany.txt
6043 Write a good commit message...
6044 % git format-patch HEAD^
6045 % git checkout master # go back to master
6046 </pre>
6047 <p>and then submit that file to the mailing list for review.</p>
6048 <p>Also you can clone the Geany repository at GitHub and send a pull request.</p>
6049 <p>Note, you will need the Python docutils software package installed
6050 to build the docs. The package is named <tt class="docutils literal"><span class="pre">python-docutils</span></tt> on Debian
6051 and Fedora systems.</p>
6052 </div>
6053 <div class="section" id="scintilla-keyboard-commands">
6054 <h1><a class="toc-backref" href="#id231">Scintilla keyboard commands</a></h1>
6055 <p>Copyright © 1998, 2006 Neil Hodgson &lt;neilh(at)scintilla(dot)org&gt;</p>
6056 <p>This appendix is distributed under the terms of the License for
6057 Scintilla and SciTE. A copy of this license can be found in the file
6058 <tt class="docutils literal">scintilla/License.txt</tt> included with the source code of this
6059 program and in the appendix of this document. See <a class="reference internal" href="#license-for-scintilla-and-scite">License for
6060 Scintilla and SciTE</a>.</p>
6061 <p>20 June 2006</p>
6062 <div class="section" id="keyboard-commands">
6063 <h2><a class="toc-backref" href="#id232">Keyboard commands</a></h2>
6064 <p>Keyboard commands for Scintilla mostly follow common Windows and GTK+
6065 conventions. All move keys (arrows, page up/down, home and end)
6066 allows to extend or reduce the stream selection when holding the
6067 Shift key, and the rectangular selection when holding the
6068 appropriate keys (see <a class="reference internal" href="#column-mode-editing-rectangular-selections">Column mode editing (rectangular selections)</a>).</p>
6069 <p>Some keys may not be available with some national keyboards
6070 or because they are taken by the system such as by a window manager
6071 or GTK. Keyboard equivalents of menu commands are listed in the
6072 menus. Some less common commands with no menu equivalent are:</p>
6073 <table border="1" class="docutils">
6074 <colgroup>
6075 <col width="67%" />
6076 <col width="33%" />
6077 </colgroup>
6078 <thead valign="bottom">
6079 <tr><th class="head">Action</th>
6080 <th class="head">Shortcut key</th>
6081 </tr>
6082 </thead>
6083 <tbody valign="top">
6084 <tr><td>Magnify text size.</td>
6085 <td>Ctrl-Keypad+</td>
6086 </tr>
6087 <tr><td>Reduce text size.</td>
6088 <td>Ctrl-Keypad-</td>
6089 </tr>
6090 <tr><td>Restore text size to normal.</td>
6091 <td>Ctrl-Keypad/</td>
6092 </tr>
6093 <tr><td>Indent block.</td>
6094 <td>Tab</td>
6095 </tr>
6096 <tr><td>Dedent block.</td>
6097 <td>Shift-Tab</td>
6098 </tr>
6099 <tr><td>Delete to start of word.</td>
6100 <td>Ctrl-BackSpace</td>
6101 </tr>
6102 <tr><td>Delete to end of word.</td>
6103 <td>Ctrl-Delete</td>
6104 </tr>
6105 <tr><td>Delete to start of line.</td>
6106 <td>Ctrl-Shift-BackSpace</td>
6107 </tr>
6108 <tr><td>Go to start of document.</td>
6109 <td>Ctrl-Home</td>
6110 </tr>
6111 <tr><td>Extend selection to start of document.</td>
6112 <td>Ctrl-Shift-Home</td>
6113 </tr>
6114 <tr><td>Go to start of display line.</td>
6115 <td>Alt-Home</td>
6116 </tr>
6117 <tr><td>Extend selection to start of display line.</td>
6118 <td>Alt-Shift-Home</td>
6119 </tr>
6120 <tr><td>Go to end of document.</td>
6121 <td>Ctrl-End</td>
6122 </tr>
6123 <tr><td>Extend selection to end of document.</td>
6124 <td>Ctrl-Shift-End</td>
6125 </tr>
6126 <tr><td>Extend selection to end of display line.</td>
6127 <td>Alt-Shift-End</td>
6128 </tr>
6129 <tr><td>Previous paragraph. Shift extends selection.</td>
6130 <td>Ctrl-Up</td>
6131 </tr>
6132 <tr><td>Next paragraph. Shift extends selection.</td>
6133 <td>Ctrl-Down</td>
6134 </tr>
6135 <tr><td>Previous word. Shift extends selection.</td>
6136 <td>Ctrl-Left</td>
6137 </tr>
6138 <tr><td>Next word. Shift extends selection.</td>
6139 <td>Ctrl-Right</td>
6140 </tr>
6141 </tbody>
6142 </table>
6143 </div>
6144 </div>
6145 <div class="section" id="tips-and-tricks">
6146 <h1><a class="toc-backref" href="#id233">Tips and tricks</a></h1>
6147 <div class="section" id="document-notebook">
6148 <h2><a class="toc-backref" href="#id234">Document notebook</a></h2>
6149 <ul class="simple">
6150 <li>Double-click on empty space in the notebook tab bar to open a
6151 new document.</li>
6152 <li>Middle-click on a document's notebook tab to close the document.</li>
6153 <li>Hold <cite>Ctrl</cite> and click on any notebook tab to switch to the last used
6154 document.</li>
6155 <li>Double-click on a document's notebook tab to toggle all additional
6156 widgets (to show them again use the View menu or the keyboard
6157 shortcut). The interface pref must be enabled for this to work.</li>
6158 </ul>
6159 </div>
6160 <div class="section" id="editor">
6161 <h2><a class="toc-backref" href="#id235">Editor</a></h2>
6162 <ul class="simple">
6163 <li>Alt-scroll wheel moves up/down a page.</li>
6164 <li>Ctrl-scroll wheel zooms in/out.</li>
6165 <li>Shift-scroll wheel scrolls 8 characters right/left.</li>
6166 <li>Ctrl-click on a word in a document to perform <em>Go to Tag Definition</em>.</li>
6167 <li>Ctrl-click on a bracket/brace to perform <em>Go to Matching Brace</em>.</li>
6168 </ul>
6169 </div>
6170 <div class="section" id="interface">
6171 <h2><a class="toc-backref" href="#id236">Interface</a></h2>
6172 <ul class="simple">
6173 <li>Double-click on a symbol-list group to expand or compact it.</li>
6174 </ul>
6175 </div>
6176 <div class="section" id="gtk-related">
6177 <h2><a class="toc-backref" href="#id237">GTK-related</a></h2>
6178 <ul class="simple">
6179 <li>Scrolling the mouse wheel over a notebook tab bar will switch
6180 notebook pages.</li>
6181 </ul>
6182 <p>The following are derived from X-Windows features (but GTK still supports
6183 them on Windows):</p>
6184 <ul class="simple">
6185 <li>Middle-click pastes the last selected text.</li>
6186 <li>Middle-click on a scrollbar moves the scrollbar to that
6187 position without having to drag it.</li>
6188 </ul>
6189 </div>
6190 </div>
6191 <div class="section" id="compile-time-options">
6192 <h1><a class="toc-backref" href="#id238">Compile-time options</a></h1>
6193 <p>There are some options which can only be changed at compile time,
6194 and some options which are used as the default for configurable
6195 options. To change these options, edit the appropriate source file
6196 in the <tt class="docutils literal">src</tt> subdirectory. Look for a block of lines starting with
6197 <tt class="docutils literal">#define GEANY_*</tt>. Any definitions which are not listed here should
6198 not be changed.</p>
6199 <div class="note">
6200 <p class="first admonition-title">Note</p>
6201 <p class="last">Most users should not need to change these options.</p>
6202 </div>
6203 <div class="section" id="src-geany-h">
6204 <h2><a class="toc-backref" href="#id239">src/geany.h</a></h2>
6205 <table border="1" class="docutils">
6206 <colgroup>
6207 <col width="33%" />
6208 <col width="48%" />
6209 <col width="20%" />
6210 </colgroup>
6211 <thead valign="bottom">
6212 <tr><th class="head">Option</th>
6213 <th class="head">Description</th>
6214 <th class="head">Default</th>
6215 </tr>
6216 </thead>
6217 <tbody valign="top">
6218 <tr><td>GEANY_STRING_UNTITLED</td>
6219 <td>A string used as the default name for new
6220 files. Be aware that the string can be
6221 translated, so change it only if you know
6222 what you are doing.</td>
6223 <td>untitled</td>
6224 </tr>
6225 <tr><td>GEANY_WINDOW_MINIMAL_WIDTH</td>
6226 <td>The minimal width of the main window.</td>
6227 <td>620</td>
6228 </tr>
6229 <tr><td>GEANY_WINDOW_MINIMAL_HEIGHT</td>
6230 <td>The minimal height of the main window.</td>
6231 <td>440</td>
6232 </tr>
6233 <tr><td>GEANY_WINDOW_DEFAULT_WIDTH</td>
6234 <td>The default width of the main window at the
6235 first start.</td>
6236 <td>900</td>
6237 </tr>
6238 <tr><td>GEANY_WINDOW_DEFAULT_HEIGHT</td>
6239 <td>The default height of the main window at the
6240 first start.</td>
6241 <td>600</td>
6242 </tr>
6243 <tr><td><strong>Windows specific</strong></td>
6244 <td>&nbsp;</td>
6245 <td>&nbsp;</td>
6246 </tr>
6247 <tr><td>GEANY_USE_WIN32_DIALOG</td>
6248 <td>Set this to 1 if you want to use the default
6249 Windows file open and save dialogs instead
6250 GTK's file open and save dialogs. The
6251 default Windows file dialogs are missing
6252 some nice features like choosing a filetype
6253 or an encoding. <em>Do not touch this setting
6254 when building on a non-Win32 system.</em></td>
6255 <td>0</td>
6256 </tr>
6257 </tbody>
6258 </table>
6259 </div>
6260 <div class="section" id="project-h">
6261 <h2><a class="toc-backref" href="#id240">project.h</a></h2>
6262 <table border="1" class="docutils">
6263 <colgroup>
6264 <col width="33%" />
6265 <col width="48%" />
6266 <col width="20%" />
6267 </colgroup>
6268 <thead valign="bottom">
6269 <tr><th class="head">Option</th>
6270 <th class="head">Description</th>
6271 <th class="head">Default</th>
6272 </tr>
6273 </thead>
6274 <tbody valign="top">
6275 <tr><td>GEANY_PROJECT_EXT</td>
6276 <td>The default filename extension for Geany
6277 project files. It is used when creating new
6278 projects and as filter mask for the project
6279 open dialog.</td>
6280 <td>geany</td>
6281 </tr>
6282 </tbody>
6283 </table>
6284 </div>
6285 <div class="section" id="filetypes-c">
6286 <h2><a class="toc-backref" href="#id241">filetypes.c</a></h2>
6287 <table border="1" class="docutils">
6288 <colgroup>
6289 <col width="33%" />
6290 <col width="48%" />
6291 <col width="20%" />
6292 </colgroup>
6293 <thead valign="bottom">
6294 <tr><th class="head">Option</th>
6295 <th class="head">Description</th>
6296 <th class="head">Default</th>
6297 </tr>
6298 </thead>
6299 <tbody valign="top">
6300 <tr><td>GEANY_FILETYPE_SEARCH_LINES</td>
6301 <td>The number of lines to search for the
6302 filetype with the extract filetype regex.</td>
6303 <td>2</td>
6304 </tr>
6305 </tbody>
6306 </table>
6307 </div>
6308 <div class="section" id="editor-h">
6309 <h2><a class="toc-backref" href="#id242">editor.h</a></h2>
6310 <table border="1" class="docutils">
6311 <colgroup>
6312 <col width="33%" />
6313 <col width="48%" />
6314 <col width="20%" />
6315 </colgroup>
6316 <thead valign="bottom">
6317 <tr><th class="head">Option</th>
6318 <th class="head">Description</th>
6319 <th class="head">Default</th>
6320 </tr>
6321 </thead>
6322 <tbody valign="top">
6323 <tr><td>GEANY_WORDCHARS</td>
6324 <td>These characters define word boundaries when
6325 making selections and searching using word
6326 matching options.</td>
6327 <td>a string with:
6328 a-z, A-Z, 0-9 and
6329 underscore.</td>
6330 </tr>
6331 </tbody>
6332 </table>
6333 </div>
6334 <div class="section" id="keyfile-c">
6335 <h2><a class="toc-backref" href="#id243">keyfile.c</a></h2>
6336 <p>These are default settings that can be overridden in the <a class="reference internal" href="#preferences">Preferences</a> dialog.</p>
6337 <table border="1" class="docutils">
6338 <colgroup>
6339 <col width="33%" />
6340 <col width="48%" />
6341 <col width="20%" />
6342 </colgroup>
6343 <thead valign="bottom">
6344 <tr><th class="head">Option</th>
6345 <th class="head">Description</th>
6346 <th class="head">Default</th>
6347 </tr>
6348 </thead>
6349 <tbody valign="top">
6350 <tr><td>GEANY_MIN_SYMBOLLIST_CHARS</td>
6351 <td>How many characters you need to type to
6352 trigger the autocompletion list.</td>
6353 <td>4</td>
6354 </tr>
6355 <tr><td>GEANY_DISK_CHECK_TIMEOUT</td>
6356 <td>Time in seconds between checking a file for
6357 external changes.</td>
6358 <td>30</td>
6359 </tr>
6360 <tr><td>GEANY_DEFAULT_TOOLS_MAKE</td>
6361 <td>The make tool. This can also include a path.</td>
6362 <td>&quot;make&quot;</td>
6363 </tr>
6364 <tr><td>GEANY_DEFAULT_TOOLS_TERMINAL</td>
6365 <td>A terminal emulator command, see
6366 <a class="reference internal" href="#terminal-emulators">Terminal emulators</a>.</td>
6367 <td>See below.</td>
6368 </tr>
6369 <tr><td>GEANY_DEFAULT_TOOLS_BROWSER</td>
6370 <td>A web browser. This can also include a path.</td>
6371 <td>&quot;firefox&quot;</td>
6372 </tr>
6373 <tr><td>GEANY_DEFAULT_TOOLS_PRINTCMD</td>
6374 <td>A printing tool. It should be able to accept
6375 and process plain text files. This can also
6376 include a path.</td>
6377 <td>&quot;lpr&quot;</td>
6378 </tr>
6379 <tr><td>GEANY_DEFAULT_TOOLS_GREP</td>
6380 <td>A grep tool. It should be compatible with
6381 GNU grep. This can also include a path.</td>
6382 <td>&quot;grep&quot;</td>
6383 </tr>
6384 <tr><td>GEANY_DEFAULT_MRU_LENGTH</td>
6385 <td>The length of the &quot;Recent files&quot; list.</td>
6386 <td>10</td>
6387 </tr>
6388 <tr><td>GEANY_DEFAULT_FONT_SYMBOL_LIST</td>
6389 <td>The font used in sidebar to show symbols and
6390 open files.</td>
6391 <td>&quot;Sans 9&quot;</td>
6392 </tr>
6393 <tr><td>GEANY_DEFAULT_FONT_MSG_WINDOW</td>
6394 <td>The font used in the messages window.</td>
6395 <td>&quot;Sans 9&quot;</td>
6396 </tr>
6397 <tr><td>GEANY_DEFAULT_FONT_EDITOR</td>
6398 <td>The font used in the editor window.</td>
6399 <td>&quot;Monospace 10&quot;</td>
6400 </tr>
6401 <tr><td>GEANY_TOGGLE_MARK</td>
6402 <td>A string which is used to mark a toggled
6403 comment.</td>
6404 <td>&quot;~ &quot;</td>
6405 </tr>
6406 <tr><td>GEANY_MAX_AUTOCOMPLETE_WORDS</td>
6407 <td>How many autocompletion suggestions should
6408 Geany provide.</td>
6409 <td>30</td>
6410 </tr>
6411 <tr><td>GEANY_DEFAULT_FILETYPE_REGEX</td>
6412 <td>The default regex to extract filetypes from
6413 files.</td>
6414 <td>See below.</td>
6415 </tr>
6416 </tbody>
6417 </table>
6418 <p>The GEANY_DEFAULT_FILETYPE_REGEX default value is -\*-\s*([^\s]+)\s*-\*- which finds Emacs filetypes.</p>
6419 <p>The GEANY_DEFAULT_TOOLS_TERMINAL default value on Windows is:</p>
6420 <pre class="literal-block">
6421 cmd.exe /Q /C %c
6422 </pre>
6423 <p>and on any non-Windows system is:</p>
6424 <pre class="literal-block">
6425 xterm -e &quot;/bin/sh %c&quot;
6426 </pre>
6427 </div>
6428 <div class="section" id="build-c">
6429 <h2><a class="toc-backref" href="#id244">build.c</a></h2>
6430 <table border="1" class="docutils">
6431 <colgroup>
6432 <col width="33%" />
6433 <col width="48%" />
6434 <col width="20%" />
6435 </colgroup>
6436 <thead valign="bottom">
6437 <tr><th class="head">Option</th>
6438 <th class="head">Description</th>
6439 <th class="head">Default</th>
6440 </tr>
6441 </thead>
6442 <tbody valign="top">
6443 <tr><td>GEANY_BUILD_ERR_HIGHLIGHT_MAX</td>
6444 <td>Amount of build error indicators to
6445 be shown in the editor window.
6446 This affects the special coloring
6447 when Geany detects a compiler output line as
6448 an error message and then highlights the
6449 corresponding line in the source code.
6450 Usually only the first few messages are
6451 interesting because following errors are
6452 just after-effects.
6453 All errors in the Compiler window are parsed
6454 and unaffected by this value.</td>
6455 <td>50</td>
6456 </tr>
6457 <tr><td>PRINTBUILDCMDS</td>
6458 <td>Every time a build menu item priority
6459 calculation is run, print the state of the
6460 menu item table in the form of the table
6461 in <a class="reference internal" href="#build-menu-configuration">Build Menu Configuration</a>. May be
6462 useful to debug configuration file
6463 overloading. Warning produces a lot of
6464 output. Can also be enabled/disabled by the
6465 debugger by setting printbuildcmds to 1/0
6466 overriding the compile setting.</td>
6467 <td>FALSE</td>
6468 </tr>
6469 </tbody>
6470 </table>
6471 </div>
6472 </div>
6473 <div class="section" id="gnu-general-public-license">
6474 <h1><a class="toc-backref" href="#id245">GNU General Public License</a></h1>
6475 <pre class="literal-block">
6476 GNU GENERAL PUBLIC LICENSE
6477 Version 2, June 1991
6479 Copyright (C) 1989, 1991 Free Software Foundation, Inc.
6480 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
6481 Everyone is permitted to copy and distribute verbatim copies
6482 of this license document, but changing it is not allowed.
6484 Preamble
6486 The licenses for most software are designed to take away your
6487 freedom to share and change it. By contrast, the GNU General Public
6488 License is intended to guarantee your freedom to share and change free
6489 software--to make sure the software is free for all its users. This
6490 General Public License applies to most of the Free Software
6491 Foundation's software and to any other program whose authors commit to
6492 using it. (Some other Free Software Foundation software is covered by
6493 the GNU Library General Public License instead.) You can apply it to
6494 your programs, too.
6496 When we speak of free software, we are referring to freedom, not
6497 price. Our General Public Licenses are designed to make sure that you
6498 have the freedom to distribute copies of free software (and charge for
6499 this service if you wish), that you receive source code or can get it
6500 if you want it, that you can change the software or use pieces of it
6501 in new free programs; and that you know you can do these things.
6503 To protect your rights, we need to make restrictions that forbid
6504 anyone to deny you these rights or to ask you to surrender the rights.
6505 These restrictions translate to certain responsibilities for you if you
6506 distribute copies of the software, or if you modify it.
6508 For example, if you distribute copies of such a program, whether
6509 gratis or for a fee, you must give the recipients all the rights that
6510 you have. You must make sure that they, too, receive or can get the
6511 source code. And you must show them these terms so they know their
6512 rights.
6514 We protect your rights with two steps: (1) copyright the software, and
6515 (2) offer you this license which gives you legal permission to copy,
6516 distribute and/or modify the software.
6518 Also, for each author's protection and ours, we want to make certain
6519 that everyone understands that there is no warranty for this free
6520 software. If the software is modified by someone else and passed on, we
6521 want its recipients to know that what they have is not the original, so
6522 that any problems introduced by others will not reflect on the original
6523 authors' reputations.
6525 Finally, any free program is threatened constantly by software
6526 patents. We wish to avoid the danger that redistributors of a free
6527 program will individually obtain patent licenses, in effect making the
6528 program proprietary. To prevent this, we have made it clear that any
6529 patent must be licensed for everyone's free use or not licensed at all.
6531 The precise terms and conditions for copying, distribution and
6532 modification follow.
6534 GNU GENERAL PUBLIC LICENSE
6535 TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
6537 0. This License applies to any program or other work which contains
6538 a notice placed by the copyright holder saying it may be distributed
6539 under the terms of this General Public License. The &quot;Program&quot;, below,
6540 refers to any such program or work, and a &quot;work based on the Program&quot;
6541 means either the Program or any derivative work under copyright law:
6542 that is to say, a work containing the Program or a portion of it,
6543 either verbatim or with modifications and/or translated into another
6544 language. (Hereinafter, translation is included without limitation in
6545 the term &quot;modification&quot;.) Each licensee is addressed as &quot;you&quot;.
6547 Activities other than copying, distribution and modification are not
6548 covered by this License; they are outside its scope. The act of
6549 running the Program is not restricted, and the output from the Program
6550 is covered only if its contents constitute a work based on the
6551 Program (independent of having been made by running the Program).
6552 Whether that is true depends on what the Program does.
6554 1. You may copy and distribute verbatim copies of the Program's
6555 source code as you receive it, in any medium, provided that you
6556 conspicuously and appropriately publish on each copy an appropriate
6557 copyright notice and disclaimer of warranty; keep intact all the
6558 notices that refer to this License and to the absence of any warranty;
6559 and give any other recipients of the Program a copy of this License
6560 along with the Program.
6562 You may charge a fee for the physical act of transferring a copy, and
6563 you may at your option offer warranty protection in exchange for a fee.
6565 2. You may modify your copy or copies of the Program or any portion
6566 of it, thus forming a work based on the Program, and copy and
6567 distribute such modifications or work under the terms of Section 1
6568 above, provided that you also meet all of these conditions:
6570 a) You must cause the modified files to carry prominent notices
6571 stating that you changed the files and the date of any change.
6573 b) You must cause any work that you distribute or publish, that in
6574 whole or in part contains or is derived from the Program or any
6575 part thereof, to be licensed as a whole at no charge to all third
6576 parties under the terms of this License.
6578 c) If the modified program normally reads commands interactively
6579 when run, you must cause it, when started running for such
6580 interactive use in the most ordinary way, to print or display an
6581 announcement including an appropriate copyright notice and a
6582 notice that there is no warranty (or else, saying that you provide
6583 a warranty) and that users may redistribute the program under
6584 these conditions, and telling the user how to view a copy of this
6585 License. (Exception: if the Program itself is interactive but
6586 does not normally print such an announcement, your work based on
6587 the Program is not required to print an announcement.)
6589 These requirements apply to the modified work as a whole. If
6590 identifiable sections of that work are not derived from the Program,
6591 and can be reasonably considered independent and separate works in
6592 themselves, then this License, and its terms, do not apply to those
6593 sections when you distribute them as separate works. But when you
6594 distribute the same sections as part of a whole which is a work based
6595 on the Program, the distribution of the whole must be on the terms of
6596 this License, whose permissions for other licensees extend to the
6597 entire whole, and thus to each and every part regardless of who wrote it.
6599 Thus, it is not the intent of this section to claim rights or contest
6600 your rights to work written entirely by you; rather, the intent is to
6601 exercise the right to control the distribution of derivative or
6602 collective works based on the Program.
6604 In addition, mere aggregation of another work not based on the Program
6605 with the Program (or with a work based on the Program) on a volume of
6606 a storage or distribution medium does not bring the other work under
6607 the scope of this License.
6609 3. You may copy and distribute the Program (or a work based on it,
6610 under Section 2) in object code or executable form under the terms of
6611 Sections 1 and 2 above provided that you also do one of the following:
6613 a) Accompany it with the complete corresponding machine-readable
6614 source code, which must be distributed under the terms of Sections
6615 1 and 2 above on a medium customarily used for software interchange; or,
6617 b) Accompany it with a written offer, valid for at least three
6618 years, to give any third party, for a charge no more than your
6619 cost of physically performing source distribution, a complete
6620 machine-readable copy of the corresponding source code, to be
6621 distributed under the terms of Sections 1 and 2 above on a medium
6622 customarily used for software interchange; or,
6624 c) Accompany it with the information you received as to the offer
6625 to distribute corresponding source code. (This alternative is
6626 allowed only for noncommercial distribution and only if you
6627 received the program in object code or executable form with such
6628 an offer, in accord with Subsection b above.)
6630 The source code for a work means the preferred form of the work for
6631 making modifications to it. For an executable work, complete source
6632 code means all the source code for all modules it contains, plus any
6633 associated interface definition files, plus the scripts used to
6634 control compilation and installation of the executable. However, as a
6635 special exception, the source code distributed need not include
6636 anything that is normally distributed (in either source or binary
6637 form) with the major components (compiler, kernel, and so on) of the
6638 operating system on which the executable runs, unless that component
6639 itself accompanies the executable.
6641 If distribution of executable or object code is made by offering
6642 access to copy from a designated place, then offering equivalent
6643 access to copy the source code from the same place counts as
6644 distribution of the source code, even though third parties are not
6645 compelled to copy the source along with the object code.
6647 4. You may not copy, modify, sublicense, or distribute the Program
6648 except as expressly provided under this License. Any attempt
6649 otherwise to copy, modify, sublicense or distribute the Program is
6650 void, and will automatically terminate your rights under this License.
6651 However, parties who have received copies, or rights, from you under
6652 this License will not have their licenses terminated so long as such
6653 parties remain in full compliance.
6655 5. You are not required to accept this License, since you have not
6656 signed it. However, nothing else grants you permission to modify or
6657 distribute the Program or its derivative works. These actions are
6658 prohibited by law if you do not accept this License. Therefore, by
6659 modifying or distributing the Program (or any work based on the
6660 Program), you indicate your acceptance of this License to do so, and
6661 all its terms and conditions for copying, distributing or modifying
6662 the Program or works based on it.
6664 6. Each time you redistribute the Program (or any work based on the
6665 Program), the recipient automatically receives a license from the
6666 original licensor to copy, distribute or modify the Program subject to
6667 these terms and conditions. You may not impose any further
6668 restrictions on the recipients' exercise of the rights granted herein.
6669 You are not responsible for enforcing compliance by third parties to
6670 this License.
6672 7. If, as a consequence of a court judgment or allegation of patent
6673 infringement or for any other reason (not limited to patent issues),
6674 conditions are imposed on you (whether by court order, agreement or
6675 otherwise) that contradict the conditions of this License, they do not
6676 excuse you from the conditions of this License. If you cannot
6677 distribute so as to satisfy simultaneously your obligations under this
6678 License and any other pertinent obligations, then as a consequence you
6679 may not distribute the Program at all. For example, if a patent
6680 license would not permit royalty-free redistribution of the Program by
6681 all those who receive copies directly or indirectly through you, then
6682 the only way you could satisfy both it and this License would be to
6683 refrain entirely from distribution of the Program.
6685 If any portion of this section is held invalid or unenforceable under
6686 any particular circumstance, the balance of the section is intended to
6687 apply and the section as a whole is intended to apply in other
6688 circumstances.
6690 It is not the purpose of this section to induce you to infringe any
6691 patents or other property right claims or to contest validity of any
6692 such claims; this section has the sole purpose of protecting the
6693 integrity of the free software distribution system, which is
6694 implemented by public license practices. Many people have made
6695 generous contributions to the wide range of software distributed
6696 through that system in reliance on consistent application of that
6697 system; it is up to the author/donor to decide if he or she is willing
6698 to distribute software through any other system and a licensee cannot
6699 impose that choice.
6701 This section is intended to make thoroughly clear what is believed to
6702 be a consequence of the rest of this License.
6704 8. If the distribution and/or use of the Program is restricted in
6705 certain countries either by patents or by copyrighted interfaces, the
6706 original copyright holder who places the Program under this License
6707 may add an explicit geographical distribution limitation excluding
6708 those countries, so that distribution is permitted only in or among
6709 countries not thus excluded. In such case, this License incorporates
6710 the limitation as if written in the body of this License.
6712 9. The Free Software Foundation may publish revised and/or new versions
6713 of the General Public License from time to time. Such new versions will
6714 be similar in spirit to the present version, but may differ in detail to
6715 address new problems or concerns.
6717 Each version is given a distinguishing version number. If the Program
6718 specifies a version number of this License which applies to it and &quot;any
6719 later version&quot;, you have the option of following the terms and conditions
6720 either of that version or of any later version published by the Free
6721 Software Foundation. If the Program does not specify a version number of
6722 this License, you may choose any version ever published by the Free Software
6723 Foundation.
6725 10. If you wish to incorporate parts of the Program into other free
6726 programs whose distribution conditions are different, write to the author
6727 to ask for permission. For software which is copyrighted by the Free
6728 Software Foundation, write to the Free Software Foundation; we sometimes
6729 make exceptions for this. Our decision will be guided by the two goals
6730 of preserving the free status of all derivatives of our free software and
6731 of promoting the sharing and reuse of software generally.
6733 NO WARRANTY
6735 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
6736 FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
6737 OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
6738 PROVIDE THE PROGRAM &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
6739 OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
6740 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
6741 TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
6742 PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
6743 REPAIR OR CORRECTION.
6745 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
6746 WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
6747 REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
6748 INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
6749 OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
6750 TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
6751 YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
6752 PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
6753 POSSIBILITY OF SUCH DAMAGES.
6755 END OF TERMS AND CONDITIONS
6757 How to Apply These Terms to Your New Programs
6759 If you develop a new program, and you want it to be of the greatest
6760 possible use to the public, the best way to achieve this is to make it
6761 free software which everyone can redistribute and change under these terms.
6763 To do so, attach the following notices to the program. It is safest
6764 to attach them to the start of each source file to most effectively
6765 convey the exclusion of warranty; and each file should have at least
6766 the &quot;copyright&quot; line and a pointer to where the full notice is found.
6768 &lt;one line to give the program's name and a brief idea of what it does.&gt;
6769 Copyright (C) &lt;year&gt; &lt;name of author&gt;
6771 This program is free software; you can redistribute it and/or modify
6772 it under the terms of the GNU General Public License as published by
6773 the Free Software Foundation; either version 2 of the License, or
6774 (at your option) any later version.
6776 This program is distributed in the hope that it will be useful,
6777 but WITHOUT ANY WARRANTY; without even the implied warranty of
6778 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
6779 GNU General Public License for more details.
6781 You should have received a copy of the GNU General Public License along
6782 with this program; if not, write to the Free Software Foundation, Inc.,
6783 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
6786 Also add information on how to contact you by electronic and paper mail.
6788 If the program is interactive, make it output a short notice like this
6789 when it starts in an interactive mode:
6791 Gnomovision version 69, Copyright (C) year name of author
6792 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
6793 This is free software, and you are welcome to redistribute it
6794 under certain conditions; type `show c' for details.
6796 The hypothetical commands `show w' and `show c' should show the appropriate
6797 parts of the General Public License. Of course, the commands you use may
6798 be called something other than `show w' and `show c'; they could even be
6799 mouse-clicks or menu items--whatever suits your program.
6801 You should also get your employer (if you work as a programmer) or your
6802 school, if any, to sign a &quot;copyright disclaimer&quot; for the program, if
6803 necessary. Here is a sample; alter the names:
6805 Yoyodyne, Inc., hereby disclaims all copyright interest in the program
6806 `Gnomovision' (which makes passes at compilers) written by James Hacker.
6808 &lt;signature of Ty Coon&gt;, 1 April 1989
6809 Ty Coon, President of Vice
6811 This General Public License does not permit incorporating your program into
6812 proprietary programs. If your program is a subroutine library, you may
6813 consider it more useful to permit linking proprietary applications with the
6814 library. If this is what you want to do, use the GNU Library General
6815 Public License instead of this License.
6816 </pre>
6817 </div>
6818 <div class="section" id="license-for-scintilla-and-scite">
6819 <h1><a class="toc-backref" href="#id246">License for Scintilla and SciTE</a></h1>
6820 <p>Copyright 1998-2003 by Neil Hodgson &lt;neilh(at)scintilla(dot)org&gt;</p>
6821 <p>All Rights Reserved</p>
6822 <p>Permission to use, copy, modify, and distribute this software and
6823 its documentation for any purpose and without fee is hereby granted,
6824 provided that the above copyright notice appear in all copies and
6825 that both that copyright notice and this permission notice appear in
6826 supporting documentation.</p>
6827 <p>NEIL HODGSON DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
6828 INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
6829 NO EVENT SHALL NEIL HODGSON BE LIABLE FOR ANY SPECIAL, INDIRECT OR
6830 CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
6831 OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
6832 OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE
6833 USE OR PERFORMANCE OF THIS SOFTWARE.</p>
6834 </div>
6835 </div>
6836 <div class="footer">
6837 <hr class="footer" />
6838 <a class="reference external" href="geany.txt">View document source</a>.
6839 Generated on: 2013-03-10 12:45 UTC.
6840 Generated by <a class="reference external" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference external" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
6842 </div>
6843 </body>
6844 </html>