4669 Commits

Author SHA1 Message Date
Colomban Wendling
3996ae9268 Update Scintilla to version 3.5.3
Closes [bugs:#1041].
2015-01-20 15:56:38 +01:00
Colomban Wendling
91d5079c8d Merge pull request #378 from b4n/remove-macro-list
Remove "Show macro list" keybinding and feature
2015-01-11 17:33:40 +01:00
Colomban Wendling
740c12c0ca Remove "Show macro list" keybinding and feature
This feature looks like a poorly implemented subset of "Complete word",
but lacks some important features like prefix filtering.  It is also
misnamed as it shows not only macros, but also variables and enums.

It also only shows `editor_prefs.autocompletion_max_entries`, but does
so from *each* file, not as a whole.

So drop it altogether, as this feature doesn't really look useful and
the current implementation seem to suffer of too many shortcomings for
it to realistically be actually used.
2015-01-11 17:30:27 +01:00
Colomban Wendling
e06f47d774 Merge pull request #289 from mspacek/build_line_num
Add %l current line number substitution to build commands
2015-01-05 16:26:03 +01:00
Colomban Wendling
d80ee82072 Select the default scheme in the Color Scheme dialog by default
Always select the default scheme by default in the Color Scheme dialog
not to end up selecting none in case of broken or nonexistent
configuration.  This matches which scheme is actually used, and fixes
use of an uninitialized iter when no scheme would be selected.
2014-12-18 02:42:05 +01:00
Colomban Wendling
87331093a9 Merge pull request #361 from techee/prj_write
Add project_write_config() to force project file rewrite
2014-12-11 00:07:41 +01:00
Colomban Wendling
0184083a7e Fix an assertion failure when trying to scope-complete in a 2-characters C++ file 2014-12-04 14:38:57 +01:00
Colomban Wendling
94aa892c81 Merge pull request #373 from techee/go_ctags
Add a Go ctags parser.
2014-11-30 02:03:00 +01:00
Jiří Techet
ccb15a31be Add the go ctags parser
Make go one of the builtin filetypes, add the parser and update the related
source and config files. While there, remove Rust from [Groups] in
filetype_extensions.conf because it's already a builtin filetype as well.

The parser itself is stolen from the fishman/ctags repo.
2014-11-30 01:35:00 +01:00
Colomban Wendling
af7d63cdf2 Merge pull request #319 from b4n/better-txt2tags-parser
Better txt2tags parser
2014-11-29 23:40:58 +01:00
Colomban Wendling
6e1c2787c1 Merge branch 'recent-list-cleanup' 2014-11-29 22:49:57 +01:00
Colomban Wendling
4074843b42 coffeescript: Recognize string and comment styles 2014-11-26 19:52:20 +01:00
Mark Dresselhaus
07002d252a Add coffescript syntax highlighting
imported lexer from Scintilla and added coffeescript filetype
2014-11-26 19:52:20 +01:00
Colomban Wendling
8da955ec94 Make the currently open project insensitive in the recent menu 2014-11-11 17:46:31 +01:00
Colomban Wendling
3fa41cc0da Cleanup code for updating recent file menus 2014-11-11 17:14:21 +01:00
Colomban Wendling
67cc8faf4b Fix closing of the "missing file" infobar
The issue was introduced in b646424ddb715382a937d233a75bc684c22e18ec as
it removed the default handler that used to destroy the infobar.

Now, the infobar is properly closed, but only if the action succeeded.

Closes #375.
2014-11-09 22:14:12 +01:00
Colomban Wendling
1dc09597b2 Fix check for fnmatch and remove strict dependency on it for Windows
Strict dependency on fnmatch was removed in 52076d19e8fe7ab41ebc92928e.

We still have an optional dependency on it from CTags, but I don't
think we use this code, and anyways the checks we had for the optional
path to be taken were incorrect, so it was never actually used.

So, drop the dependency on libibrety for Windows builds, and fix the
remaining checks for an optional fnmatch so if it is found it can
actually be used.
2014-11-09 17:40:03 +01:00
Colomban Wendling
aa06427c71 Merge branch 'plugin-symbols-protoypes' 2014-11-09 00:19:14 +01:00
Colomban Wendling
8c77accfd0 Merge PR#356 from 'b4n/techee/tm'
Huge TagManager improvements
2014-11-08 19:37:20 +01:00
Colomban Wendling
fd4f31cc07 Bump Geany API and ABI for TagManager API changes 2014-11-08 18:34:15 +01:00
Colomban Wendling
6a0673f4ae TM: Don't allow passing NULL to tm_workspace API 2014-11-08 18:32:41 +01:00
Thomas Martitz
53101dd5fa project: Remove unecessary calls after loading project files
document_new_file_if_non_open() and ui_focus_current_document() only make sense
when files where actually opened, but the preceeding
configuration_load_session_files() only loads the file names into the global
session_files variable, from which the files are actually opened by a later
call to configuration_open_files(). These two calls should be done after that
one and the callers generally do this already.
2014-11-08 17:59:05 +01:00
Jiří Techet
a95fc1a994 Don't expose the source file update function to plugins 2014-11-05 21:50:07 +01:00
Jiří Techet
71cc1ecb20 Cleaner and safer TMWorkspace API
With the previous TMWorkspace API it was possible to make the workspace
inconsistent by e.g. removing source files and forgetting to update
workspace. This could lead to non-obvious and not immediately visible
crashes.

The new set of the public (but also Geany private) API calls always
updates the workspace accordingly and neither of the calls can lead
to an inconsistent state of the workspace.

In addition, perform some minor cleanups and simplifications - unify
parsing from buffer and from file, support "parsing" of 0-sized buffers
and improve documentation.
2014-11-02 11:39:57 +01:00
Colomban Wendling
42a9603f4a Use TMTagType everywhere to hold tag types 2014-10-31 20:07:27 +01:00
Jiří Techet
bdee1336aa Keep a separate list of typenames for Scintilla syntax highlighting
Manage the list the same way as workspace tags_array by the fast tag removal
and merge. Thanks to this, typename tags don't have to be extracted from
tags_array periodically, which speeds up editing.
2014-10-30 22:08:17 +01:00
Jiří Techet
be131b00f9 Extend dedup() and merge() to unref the duplicate tag when needed 2014-10-30 22:08:17 +01:00
Jiří Techet
15c90b63c9 Get rid of lazy initialization in TM
Lazy initializing various member pointers doesn't bring any real performance
improvement but it requires lots of additional NULL checks - get rid of
this.

Make some more cleanups on the way.

In addition, remove success/failure return values from tm_workspace_add_source_file()
and tm_workspace_remove_source_file() which have no real use.
2014-10-30 22:08:17 +01:00
Jiří Techet
43b8ab8d23 Only keep the minimal set of parameter in the TM API calls
Avoid "utility" parameters like do_free for which we already have API calls
and which actually don't perform any free if the source file isn't
in TM. Clarify when to set the update_workspace parameter.
2014-10-30 22:08:17 +01:00
Jiří Techet
0285ec28a5 Move tm_source_file_update() to tm_workspace.c
The placement of this function in tm_source_file is not right - by moving
it to the workspace we can make the source file unaware of the existence
of the workspace (no inclusion of tm_workspace.h in tm_source_file any
more). Also change tm_source_file_new() so it doesn't offer the source file
update.

After this change
* TMWorkspace knows TMSourceFile and TMTag
* TMSourceFile knows TMTag
* TMTag knows TMSourceFile
2014-10-30 22:08:17 +01:00
Nick Treleaven
cfcbc6a205 Make Next/Previous Message keybindings work without a document open 2014-10-30 16:34:00 +00:00
Jiří Techet
41dcde623d Always set project description and file patterns in the dialog
Set them also when they are NULL in the project (which happens when new
project is created) because otherwise there are left-over values from
the previous project.
2014-10-27 20:58:59 +01:00
Jiří Techet
233ca08e88 Add project_write_config() to force project file rewrite
Since plugins don't have direct access to the project file,
only through the project-save signal, they need some way to emit this
signal when saving their preferences outside the project dialog,
which is what this function does.
2014-10-25 22:30:54 +02:00
Colomban Wendling
d4135c9842 Add prototypes for all plugin symbols
This allows the compilers to check that the plugin's symbols have the
proper prototype.  Doing so can avoid subtle and hard-to-find bugs in
case a plugin's symbol has incorrect signature as dlsym() can't check
if the signature is actually the one we expect.

As a bonus, it helps when using -Wmissing-prototypes as it provides the
prototypes.
2014-10-20 17:55:32 +02:00
Colomban Wendling
c35dedf35f Rename internal plugin_init() to avoid confusion with plugins entry point 2014-10-20 16:18:05 +02:00
Jiří Techet
62332e19aa Since lang is now always part of TMTag, always set its value
This makes it less confusing for code accessing TMTag so it can always
find the language in tag->lang and there is no need to access it through
tag->file.lang.
2014-10-18 21:40:11 +02:00
Jiří Techet
54a9fd83ea Get rid of the nested members in TMTag
The only real change is the removal of struct and union in TMTag, the
rest is purely mechanical removal of "atts.entry." everywhere.
2014-10-18 21:40:11 +02:00
Jiří Techet
48725e4188 Get rid of the file struct in TMTag, preparation for the union removal
The union on TMTag is very confusing and rather dangerous. The fields
file/timestamp and line/lang overlap. Some implicit assumptions are made
in the code - timestamp is never set so when file is NULL, the file
struct should be used to get the lang member. Rather avoid using unions
and move the lang member to the entry struct together with the other
attributes.
2014-10-18 21:40:10 +02:00
Jiří Techet
8c25ff871c Make tm_workspace_update() public 2014-10-18 21:40:10 +02:00
Jiří Techet
26587454b0 Remove TmWorkObject and all the OO related stuff
In addition, rename all functions, parameters, comments etc. mentioning
work_object and remove unnecessary parameters of various functions.
Delete dead code paths.

Also move common functions like tm_get_real_path() from tm_work_object to
tm_source_file.
2014-10-18 21:40:10 +02:00
Colomban Wendling
d42837f021 Merge pull request #351 from techee/guards
Protect private definitions by the GEANY_PRIVATE macro in headers
2014-10-18 18:13:45 +02:00
Colomban Wendling
608ab0f60c Document the fact utils_spawn_sync() accepts NULL for all output arguments 2014-10-14 23:23:13 +02:00
Jiří Techet
6d6dd7444b Fix doxygen warnings
Make documents_array public and accessible by doxygen and describe all
parameters of tm_source_file_new().
2014-10-12 23:33:51 +02:00
Colomban Wendling
f5230f334e Fix moving editor tabs through keybindings 2014-10-12 18:00:12 +02:00
Enrico Tröger
3966ba8c4b Query GdkWindow reference only if available
On startup, the Geany main window doesn't have a GdkWindow yet
(probably because it is not yet mapped). This causes many
'gdkdrawable-win32.c:2013 drawable is not a pixmap or window'
warnings when resolving shortcuts on Windows.
Since we pass the SLR_NO_UI to the Windows API, we probably
don't need the parent hWnd reference at all.
2014-10-12 16:35:46 +02:00
Colomban Wendling
75ab7103f1 Merge pull request #353 from b4n/tm-no-update-on-quit
Don't rebuild TagManager workspace tags when quitting
2014-10-12 16:02:40 +02:00
Nick Treleaven
2d59f110df Merge pull request #350 from ntrel/reload-prompt
Don't prompt for reload from infobar when there are no unsaved changes
2014-10-12 13:27:00 +01:00
Colomban Wendling
eb7fd066b1 Don't alter GeanyEditor internal state in editor_create_widget()
When editor_create_widget() is used on an editor with already existing
widget, don't reset the internal indentation settings of that editor.
2014-10-11 14:53:21 +02:00
Matthew Brush
41c66e0eb0 Change "replace_and_find_by_default" default to true 2014-10-10 18:40:54 -07:00
Matthew Brush
bae420a768 Merge branch 'rpalli/replace1'
Closes #189
2014-10-10 18:02:29 -07:00