247 Commits

Author SHA1 Message Date
Nick Treleaven
398efbd373 Note: this commit breaks the plugin API.
Split widget fields out of GeanyApp into GeanyMainWidgets, so other
data items can be added without breaking the plugin ABI.
Add GeanyData::main_widgets, and macro.
Rename treeview_notebook sidebar_notebook in GeanyMainWidgets.
Move tools_menu from GeanyData to GeanyMainWidgets.
Move statusbar out of GeanyApp (shouldn't be used directly).
Move ignore_callback out of GeanyApp.
Rename sci_goto_line() argument unfold, like sci_goto_pos().
Make utils_goto_file_pos(), utils_goto_line(),
utils_switch_document() into static functions (they are UI-related,
so shouldn't be in utils.c).
Move utils_goto_pos() to editor.c, add mark argument.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2609 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-22 14:41:28 +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
Nick Treleaven
bd92df27f5 Add support for custom file templates found at startup in the
~/.geany/templates/files directory. These are currently shown
underneath filetype templates in the New with Template menu.
Add ui_menu_item_get_text().
Make utils_string_replace_all() ignore empty haystacks.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2575 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-13 17:18:14 +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
00c722966c Rename GEANY_FILETYPES_ALL GEANY_FILETYPES_NONE.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/branches/custom-filetypes@2556 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-05-07 13:54:21 +00:00
Enrico Tröger
02ea9a08d8 Revert the translatable filetype name of filetype All, add a workaround in ui_update_statusbar() instead.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2472 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-11 15:39:44 +00:00
Frank Lanitz
38bc3a1916 Make some more strings translateable
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2463 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-04-09 22:08:23 +00:00
Nick Treleaven
91e8ffdbce Fix comparison always true warning, use doc_array->len instead of number of notebook tabs.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2393 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-24 13:23:01 +00:00
Enrico Tröger
dd684a529f Small improvement in counting changed documents for Save All update.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2391 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-03-23 16:43:01 +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
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
Enrico Tröger
e4edda0fa2 Allow using Find In Files dialog even if no files are open (closes #1891818).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2250 ea778897-0a13-0410-b9d1-a72fbfd435f5
2008-02-12 12:04:21 +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
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
Enrico Tröger
47c7c69214 Add Move document first/last keybindings (patch by Catalin Marinas, thank you).
Add toolbar items to increase/decrease indentation (closes #1850697).	     


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2104 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-12-16 16:54:47 +00:00
Enrico Tröger
0573e49653 Fix wrong file filters in project-related file dialogs on Windows.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2094 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-12-07 16:31:38 +00:00
Enrico Tröger
e4d11212cf Deny "(Un)Fold All" actions when folding is disabled.
Hide "(Un)Fold All" menu items instead of just disabling them.
Add dialogs_show_msgbox_with_secondary().
Add line and column number in charset conversion error dialog when saving a file and improve display of the failed character.		


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2075 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-11-29 18:08:20 +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
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
db17d897b6 Add recent files also to GTK's recent files buffer.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1943 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-10-13 10:41:38 +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
Nick Treleaven
928e2f032e Use G_N_ELEMENTS(arr) instead of sizeof(arr) / sizeof(arr[0]).
Correct prev_translators email address.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1878 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-12 16:25: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
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
7be0947ff1 Sort list of files to build on Windows. Add geanyobject.c to the list of files to build on Windows. Fix some warnings and build errors on Windows.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1850 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-09-03 18:19:27 +00:00
Nick Treleaven
b401b698ea Move file-related fields from EditorPrefs -> GeanyPrefs.
Rename line_breaking -> line_wrapping for EditorPrefs and document.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1823 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-08-24 16:20:33 +00:00
Nick Treleaven
ef1399e000 Rename MyApp -> GeanyApp.
Move most GeanyApp fields into:
GeanyPrefs for (most) Preferences dialog fields;
UIPrefs for non-Prefs dialog visual settings;
UIWidgets for less commonly used widgets such as menuitems and
dialogs;
GeanyStatus for various states the application can be in.
Move some GeanyApp fields into EditorPrefs (and one into each of
CommandLineOptions and SidebarTreeviews).
Add plugin API prefs field.
Move disabling build widgets on Windows to build_init().
Make build callbacks static.
Add treeviews_init() to prepare popup menus and open files treeview.
Replace treeviews_find_node() with treeviews_select_openfiles_item().
Make utils_isbrace() and utils_is_opening_brace() take an
'include_angles' argument (to separate from editor_prefs).
Make 'Goto matching brace' keybinding include <> angle brackets.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1815 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-08-23 11:34:06 +00:00
Nick Treleaven
9f46d083c5 Move #define PLAT_GTK to geany.h.
Move filetype typedef to geany.h.
Don't #include any src/*.h files from headers.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1800 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-08-15 15:37:21 +00:00
Enrico Tröger
64f13d4104 Add option to suppress messages in the status bar.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1771 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-08-05 11:03:44 +00:00
Nick Treleaven
109a7aee67 Convert 'Insert Special HTML Characters' tool into a plugin;
keybinding support will be added later.
Add plugin functions for inserting text into the current document.
Add plugin support for disabling a menu item when no documents are
open.
Destroy plugin_fields->menu_item on unloading if set by a plugin.
Use G_MODULE_BIND_LOCAL for plugins to prevent symbol shadowing by
other modules, and to help detect unresolved symbols at loading time.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1734 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-07-23 15:41:08 +00:00
Nick Treleaven
2178c7c887 Rename ui_close_buttons_toggle() ui_document_buttons_update().
Move app->sensitive_buttons to ui_utils.c for easier maintenance,
rename to document_buttons.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1727 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-07-20 12:06:51 +00:00
Enrico Tröger
ba0fb3e73f Fix warnings about shadowing local variables.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1709 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-07-17 08:10:29 +00:00
Nick Treleaven
3ecd31d9fd Add ui_table_add_row() for easily adding widgets to a GtkTable, and
use it in project_new().
Group 'generic' functions related to GTK+ together at the top of
ui_utils.h.
Make sure G_GNUC_NULL_TERMINATED is defined in geany.h.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1702 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-07-13 15:54:16 +00:00
Nick Treleaven
05cbc77bab Rename some menubar widget names.
Use indentation spelling in variable names.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1611 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-06-12 15:16:17 +00:00
Enrico Tröger
3f30a4cc96 Applied patch from Dave Moore to add simple code navigation (thank you).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1590 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-06-02 16:14:07 +00:00
Nick Treleaven
4193196248 Move MyApp::pref_editor_* to editor.h, using editor_prefs struct.
Move INDENT_* enums to editor.h.
Move utils_get_whitespace() to editor.c.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1587 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-29 16:30:54 +00:00
Nick Treleaven
b4dc6feabc Show current project name in window title.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1582 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-28 15:24:21 +00:00
Enrico Tröger
d1b6ff0830 Add missing header file.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1575 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-26 09:02:37 +00:00
Enrico Tröger
39dbad8829 Improve sensitivity of recent files sub menus.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1572 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-25 14:42:43 +00:00
Enrico Tröger
b5f8992a5d Added many widget names to different dialogs for use with custom styles. Menu items still don't work.
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1535 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-15 15:16:16 +00:00
Nick Treleaven
9570443c7b Use open folder dialog for project base path instead of create folder
dialog (better for choosing existing directories, and can still
create new folders).
Add optional title parameter for open dialog with ui_path_box_new()
and ui_setup_open_button_callback().
Use Windows folder dialog in ui_path_box_open_clicked().


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1526 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-11 16:34:18 +00:00
Enrico Tröger
0514bba3d3 Added keybinding to show and hide all additional widgets(statusbar, toolbar, sidebar and messages window).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1505 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-05-04 16:59:00 +00:00
Nick Treleaven
98f64da8f6 Add ui_path_box_new() for creating a path text entry with an open
button, which runs a file chooser to set the text entry.
Add ui_setup_open_button_callback() for setting up a button callback
that behaves like the open button in ui_path_box_new().
Use ui_path_box_new() in FIF dialog setup.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1485 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-04-29 12:03:25 +00:00
Enrico Tröger
c84d9b2803 Added options to show or hide the statusbar as well as the editor scrollbars.
Added sci_set_scrollbar_mode() to easily show or hide the scrollbars.	  


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1444 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-04-10 17:06:57 +00:00
Nick Treleaven
4b03559bd7 Use tab stops for status bar line, column and selection data to stop
the other fields being moved so often when browsing code or typing.
Rearrange status bar statistics to be clearer/more concise.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1388 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-03-13 11:32:57 +00:00
Enrico Tröger
90b01daf35 Fixed several compiler warnings (mainly shadowing local variables and unreachable code).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1376 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-03-09 13:52:26 +00:00
Enrico Tröger
9dc61832fc Added different auto indention modes to select who should Geany indent new lines (closes #1615605).
git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@1373 ea778897-0a13-0410-b9d1-a72fbfd435f5
2007-03-08 18:02:08 +00:00