319 Commits

Author SHA1 Message Date
Enrico Tröger
311b82ebb2 Rename document struct to GeanyDocument.
Rename filetype struct to GeanyFiletype.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2594 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-16 14:17:54 +00:00
Nick Treleaven
3a12da9daf Note: this commit breaks the plugin API (but is necessary so that in
future the ABI can stay stable when adding preferences).
Split up prefs into interface_prefs, toolbar_prefs, file_prefs,
search_prefs, tool_prefs, template_prefs, and add these to the
plugin API.
Move suppress_search_dialogs and search_use_current_word to
search_prefs, and rename accordingly.
Rename switch_msgwin_pages pref to switch_to_status.
Remove toolbar_ prefix for toolbar_prefs items.
Remove tool_ prefix for tool_prefs items.
Remove template_ prefix for template_prefs items.
Add Geany prefix for EditorPrefs.
Add Geany prefix for SearchPrefs.
Initialize search_prefs to zero in main.c.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2591 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-16 12:08:39 +00:00
Enrico Tröger
beb68832b3 Move several editing related functions from document.c to editor.c.
Fix two compiler warnings about non-literal format strings.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2588 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-15 13:43:29 +00:00
Enrico Tröger
b2cddc87a0 Move indicator functions from document.c into editor.c.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2587 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-14 17:58:56 +00:00
Nick Treleaven
f700baa906 Rename old uses of line breaking -> line wrapping. This includes the
keyfile pref, so any users with this enabled will have to reset it.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2563 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-09 14:17:25 +00:00
Nick Treleaven
d131023fe7 Add basic Line Breaking option in the Document menu. Line breaking
only works when typing characters past the line breaking column
number.
Add 'Line breaking column' editor pref.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2562 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-09 12:13:29 +00:00
Nick Treleaven
3afebc701c Move Close All functions to document.c.
Add document_account_for_unsaved().


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2526 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-24 14:33:12 +00:00
Nick Treleaven
7e244e784a Fix geany_debug() warnings with Close All.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2490 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-16 12:00:27 +00:00
Nick Treleaven
dc6e52f41c Make pressing escape in the sidebar focus the editor.
Group toolbar GtkEntry escape key checks into a common callback.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2488 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-16 11:34:34 +00:00
Enrico Tröger
f98b8967ad Fix wrong return value for on_close_all1_activate() callback.
Fix broken Close All command by not double checking for validity of a document.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2476 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-13 17:33:51 +00:00
Nick Treleaven
9a67c39a70 Make Close All check for unsaved documents first before closing any,
so that clicking cancel keeps all documents open.
This also prevents the UI from not being updated after cancelling
Close All.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2443 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-03 15:45:23 +00:00
Enrico Tröger
9602b91e0f Ignore notebook_switch_page signal handler when closing projects to speed it up a little bit with many session files.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2437 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-02 13:48:39 +00:00
Enrico Tröger
07b666d0a9 Fix usage of wrong pointer when showing the toolbar popup menu.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2429 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-28 17:06:41 +00:00
Enrico Tröger
99a3d8e3c3 Add preference for not using the current word under the cursor when opening Find dialogs.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2389 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-23 16:29:43 +00:00
Enrico Tröger
a0b1e7a692 When opening the manual on the website, include version string to ensure the appropriate manual version is shown.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2376 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-21 13:42:31 +00:00
Enrico Tröger
6ad9240601 Fix compiler warnings about uninitialized variables.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2338 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-13 15:18:42 +00:00
Nick Treleaven
2c0316a296 Merge plugin-keybindings branch:
Change keybindings code to use keybinding groups, each with a
separate enum set, which will make the plugin ABI more stable, and
lay the groundwork for plugin keybindings support.
Note: this breaks the plugin API.
Rename keybindings_cmd() to keybindings_send_command(), which now
takes a group_id argument.
Add keybindings_lookup_item().
Add documentation for keybindings structs.
Add support for plugin keybindings using the PLUGIN_KEY_GROUP()
macro.
Add a plugin keybinding for 'Insert Special HTML Characters'.
Rename KBCallback, cmd_id, cb_func with clearer names.
Add KeyBinding::menu_item field for setting accelerators (currently
does nothing).
Load keybindings keyfile after plugins have loaded at startup, so
their shortcuts are also loaded. Still to do: loading individual
plugin keybindings after startup.
Group most keybinding callbacks together according to keybinding
group.
Add keybindings_set_item() and add it to the plugin API.
Set main menu widget accels with keybindings_set_item() - they are
ignored for now. Popup menu accels are set separately.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2324 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-12 17:07:43 +00:00
Nick Treleaven
2c19fe8e14 Break down Edit, Editing, Tags, Other keybinding groups into Editor,
Clipboard, Select, Format, Insert groups and rename GEANY_KEYS_*
accordingly.
Group most keybinding callbacks together according to keybinding
group.
Add underscore for GEANY_KEYGROUP_*.
Set main menu widget with keybindings_set_item() - this is still
ignored for now. Popup menu accels are set separately.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/branches/plugin-keybindings@2323 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-12 13:37:39 +00:00
Enrico Tröger
eba6d2c91e Apply patch from Jeff Pohlmeyer (thanks) to fix toggle case with rectangular selections (works only for Ascii characters).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2309 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-06 15:47:43 +00:00
Nick Treleaven
ee26ac9254 Change keybindings code to use keybinding groups, each with a
separate enum set, which will make the plugin ABI more stable,
and lay the groundwork for plugin keybindings support.
Note: this breaks the plugin API.
Disable setting menu accelerators (temporary).
Disable Keyboard Shortcuts dialog (temporary).
Disable snippets completion (temporary).
Disable focus commands in the VTE (temporary).
Make Tags group use separate cb_func_tags callback.
Rename keybindings_cmd() to keybindings_send_command().
Add keybindings_lookup_item().


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/branches/plugin-keybindings@2297 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-02-29 19:30:28 +00:00
Enrico Tröger
b7bfb2743a Replace all C++-style comments with usual C-like multi-line comments.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2287 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-02-27 13:17:29 +00:00
Nick Treleaven
3714cf498f Don't scroll the editor view if it is unnecessary when using Find
Next/Previous, Find Selected and when searching from the search bar.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2274 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-02-22 13:30:16 +00:00
Enrico Tröger
85f73129c0 Apply patch from Daniel Richard G. to fix to fix several compiler warnings, C89 violations and minor code problems (thanks).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2267 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-02-20 11:24:23 +00:00
Nick Treleaven
28ee2d71f0 Close any project before closing all documents so the project
session files are saved.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2190 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-01-25 13:14:38 +00:00
Enrico Tröger
a377002f4e Rename ui_treeviews_show_hide() in ui_sidebar_show_hide().
Don't hide sidebar when symbol and document lists are hidden but other notebook tabs are still there.	 


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2186 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-01-23 14:12:08 +00:00
Nick Treleaven
6eceb83d41 Make 'Open Selected File' first try the current file's directory,
falling back to the project base path if no file was found.
Add editor_get_default_selection() from get_default_text() in
search.c, to get the current selection or current word.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2172 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-01-14 17:30:59 +00:00
Enrico Tröger
e3201062c6 Update copyright information and change format of email addresses in source files.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2150 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-01-06 18:11:57 +00:00
Nick Treleaven
559ca62705 Add combo box input history for Make Custom Target dialog.
Make dialogs_show_input() automatically activate on pressing enter in
the GtkEntry, use a callback for input text, and have a 'persistent'
option to hide the dialog instead of deleting it, using a combo box
for input text history.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2120 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-12-21 13:09:09 +00:00
Enrico Tröger
80532b616d Store more document-related settings session-based in the configuration file(including the file encoding).
Detect in-file specified file encoding by scanning the file using regular expressions.	    


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2093 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-12-07 14:13:05 +00:00
Enrico Tröger
c27e9b54c6 Add search_show_find_in_files_dialog() to the plugin API.
Make path entry of filebrowser plugin editable.
Add "Open with" and "Find in Files" popup menu items to filebrowser  plugin and add configuration dialog.	    


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2085 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-12-02 10:52:19 +00:00
Enrico Tröger
2b07283739 Add plugin manager dialog to select plugins to load at startup and to call a plugin configure dialog.
Add configure symbol for plugins which is called by Geany when a configure dialog for the plugin is requested, optionally.
Add author field to plugin info struct.
Add sample configure dialog to the demo plugin.
Fix cleanup code in filebrowser plugin to remove it completely when unloaded.			


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2060 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-11-20 18:15:46 +00:00
Enrico Tröger
26f6490c41 Apply patch from Bo Lorentsen to improve support for project session files (thank you).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2057 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-11-18 18:24:23 +00:00
Enrico Tröger
fff66178da Add native GTK printing support.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2050 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-11-17 14:04:27 +00:00
Nick Treleaven
92a00f1f8e Add 'Strip Trailing Spaces' document menu item.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2025 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-11-06 13:24:39 +00:00
Nick Treleaven
601dfd69f7 Make msgwin_status_add() only log a message, not display it on the
status bar.
Make ui_set_statusbar() take a log argument for whether to record the
message in the Status window.
(Plugin API functions already do this).


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1971 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-24 10:52:48 +00:00
Nick Treleaven
a2589f87fa Add Indent Type option in the Document menu.
Add 'Detect from file' Editor indentation pref.
Show TAB or SP for current document's indent type.
Minor editing of Document menu and editor Indentation prefs group.
Use GString for statusbar statistics.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1953 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-17 12:27:07 +00:00
Enrico Tröger
97def873e4 Oops ;-).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1949 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-16 08:58:43 +00:00
Enrico Tröger
0dc540e053 Suppress selection changed signal when switching between open files and symbol list.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1948 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-16 08:54:54 +00:00
Enrico Tröger
16147c48fe Add menu accelerators to the custom date menu items.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1942 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-13 09:35:34 +00:00
Enrico Tröger
2eaa1d8dcf Fix wrong insert position of Insert Date function when using keyboard shortcut and place the cursor behind the inserted date.
Enable horizontal scrollbar for the Open Files list.       


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1932 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-08 12:10:03 +00:00
Enrico Tröger
960a535798 Fix scrolling bugs when searching text and the cursor is outside of the current visible area.
Unfold search result.
Also print version of Geany together with GTK/GLib version information.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1923 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-01 12:22:44 +00:00
Nick Treleaven
8d193436de Remove pos argument from sci_get_current_line(), because
sci_get_line_from_position() can be used instead and it's clearer.
Remove unused sci_get_line_end_styled() - it's also the same as
sci_get_line_from_position().


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1904 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-25 16:44:33 +00:00
Nick Treleaven
852a4dbb50 Fix bug when using Navigate backwards after using the keyboard to
set the cursor position on the current word.
Add symbols_goto_tag().
Replace navqueue_append() with navqueue_goto_line().


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1900 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-25 12:39:41 +00:00
Nick Treleaven
6e90725f5d Make 'Duplicate lines' work for whole lines when more than one line
has a selection.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1892 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-21 16:39:21 +00:00
Nick Treleaven
6556066f24 Speed up Save All for C-like files by avoiding unnecessary
recolourising after user typenames have changed.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1879 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-13 11:31:19 +00:00
Nick Treleaven
a76adc4354 Make Toggle Case use the current word if there's no selection.
Make Toggle Case keep an existing selection.
Rename ui_widgets.popup_items to popup_copy_items.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1876 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-12 16:01:23 +00:00
Enrico Tröger
568e5987e8 HTML manual is called Manual.html on Windows, so open this file.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1870 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-11 18:18:09 +00:00
Nick Treleaven
274058eb7a Neaten up the plugin API:
Make document_open_file() now wrap document_open_file_full(),
without the idx for reloading or pos arguments.
Replace str_replace() with string_replace_all() in the plugin API.
Add utils_string_replace_all(), taking a GString argument.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1868 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-11 15:21:11 +00:00
Enrico Tröger
ac7e6acee5 Change quotes in some error messages to be more consistent (thanks Frank).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1863 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-09 16:13:30 +00:00
Enrico Tröger
d390522727 Remove convert to lower-/upper-case keybindings.
Add toggle case keybinding and change shortcut to Ctrl-Alt-U.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1860 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-07 19:01:55 +00:00