Hi!
I saw this code in src/symbols.c at line 1917:
while (sci_get_style_at(sci, start) != fn_style
&& start < max_pos) start++;
If start >= max_pos then sci_get_style_at will be called (with out of
bounds value?) and then the loop will bail out.
I suggest that the condition is reordered as:
while (start < max_pos
&& sci_get_style_at(sci, start) != fn_style)
start++;
Then sci_get_style_at will only be called if start is less than max_pos.
It is just my humble suggestion.
Best regards,
Daniel
Hi,
I'm sending my stack of patches against geany again, this time as individual patches. Here's the full list:
[PATCH 01/19] Prevent -Wmissing-prototypes report warning when compiling a plugin
[PATCH 02/19] Add signals for project options dialog opening and closing
[PATCH 03/19] Make the project menu accessible by plugins
[PATCH 04/19] Make it possible to change project patterns by plugins
[PATCH 05/19] Don't be annoying when not necessary
[PATCH 06/19] Make it possible for plugins to change the base directory of msgwindow
[PATCH 07/19] Open the file in the msgwindow even if no linenumber is specified
[PATCH 08/19] When closing tab, return to the document at the top of the MRU list
[PATCH 09/19] Use wider entry for project file path
[PATCH 10/19] New utils function to get relative path from one directory to another
[PATCH 11/19] File name in the project settings dialog shouldn't look it is editable
[PATCH 12/19] Use relative paths in the project files
[PATCH 13/19] Remove the "set" button from the project properties dialog
[PATCH 14/19] Rewrite tab switching queue
[PATCH 15/19] Do not insert --include= when the search pattern entry is empty
[PATCH 16/19] Use project patterns in the FIF dialog
[PATCH 17/19] Make the tab switching dialog a bit more useful
[PATCH 18/19] Use standard include paths for "open selected file"
[PATCH 19/19] Use per document indent sizes
Only some of them are required by gproject - others are just suggestions for improvements. I didn't explicitly distinguish between these two types of patches but it should be pretty clear from the description. There have been some minor changes since my last post - mainly the change of the FIF dialog to contain combo box for pattern selection and there are also some new patches - the detailed description is in the individual emails. Of course many of the patches are suggestions only so further discussion is welcome.
Cheers,
Jiri
Dear Geany Devs,
I recently switched from GeanyPRJ to Gproject. Since Gproject doesn't
support multiple open projects I have to switch between projects, but
it takes up to 4 minutes to close one project and open another. A
project consists of roughly 1000-2000 php-related files.
The "Generate tags for all project files" causes this massive delay,
but I really need that feature.
At work I have a 2-core CPU, where 1 is completely idle and on my
desktop at home there are 5 cores are doing nothing while generating
tags. Can't they be utilized to speed up the tag generation?
Cheers!
Harold
Hello all.
I have several suggestions and questions about certain line operations
implemented in Geany.
1) Recently I found that "move lines up/down" command does not work
properly for the last line not ending with a newline. You can easily
check it yourself. Couple of minutes ago I made a pull request [1]
with an implementation of `editor.c:move_lines()` which handles the
problem. Dear unknown someone, please review and pull if it's okay.
[1]: <https://github.com/geany/geany/pull/21>
2) I want to raise a question, do we need a "join lines" command? This
command would be a companion of the existing "reflow paragraph"
command, but in contrast with the latter, it would only join lines, but
not split them.
This command may be useful when, let's say, you have a document created
by someone else who sticks with line breaking and inserts \n at column
80. Suppose that you prefer using line wrapping instead and want to
remove those \n in a peace of a document which you're editing. The new
command would help you a bit.
Implementation of the new "join lines" command could use the bits of
code already written for "reflow paragraph" (though, those bits need to
be extracted/refactored first). Moreover, I already implemented it
and, if the new command seems useful to anyone, I can put my
implementation in a pull request.
3) Here there should have been a point about some bug reports we have
in Geany bug tracker, referring to "reflow paragraph" glitches. As
this message is already too long, I decided to designate a separate
message for that (later).
Thank you for reading :) Please write your thoughts about 1) and 2)
--
Best regards,
Eugene.
Hi folks,
I saw that the SM-branch is merged with trunk on a regular basis, but
not sure what's the current status of that branch. Can someone help me
out there?
Cheers,
Frank
--
http://frank.uvena.de/en/
On Tue, Jan 3, 2012 at 13:44, Matthew Brush <mbrush(a)codebrainz.ca> wrote:
> I already ported all of the existing old-style color schemes to work with
> the new filedefs, see the geany-themes[1] project on Github to get them.
> Some might need a little tweaking, but should for the most part be quite
> similar to the original ones.
Nice!
Unfortunately, the 'dark' scheme needs some serious tweaking to make
it look like I'm used to (it's very brownish dull right now), but I
guess some well-placed copy/paste actions will solve that for me! ;)
Armed with a screenshot of the old scheme, dark.conf, an old
filetypes.* file and the documentation[1] I'll try to recreate the old
dark theme.
Cheers!
-H-
[1] http://www.geany.org/manual/dev/index.html#named-colors-section
Now that the geany-plugins has been converted to Git, I thought I'd post
this patch that adds the feature I've been working on (wrapping text with
characters) to the Addons plugin. Any chance of it being added?
And I've never really used Git before too, so please let me know if the
patch is incorrectly made or something.
Cheers
Alex
There is a problem as I understand it with checking for the
SC_MARK_AVAILABLE marker to see if a marker is available...
Markers seem by default to be set to 0 (SC_MARK_CIRCLE) by scintilla. So
there is no way to tell if a marker is being used with the default marker
icon (SC_MARK_CIRCLE), or is not being used. The following code dropped in
anywhere that it will get run (I placed it in the DefineMarkers function of
geanynummberedbookmarks) will demonstrate:
GtkWidget *dialog;
gchar temp[10000];
gint m[32];
for(i=0;i<32;i++)
m[i]=scintilla_send_message(sci,SCI_MARKERSYMBOLDEFINED,i,0);
sprintf(temp,"%d %d %d %d %d %d %d %d\n%d %d %d %d %d %d %d %d\n%d %d %d %d
%d %d %d %d\n%d %d %d %d %d %d %d
%d",m[0],m[1],m[2],m[3],m[4],m[5],m[6],m[7],m[8],m[9],m[10],m[11],m[12],m[13],m[14],m[15],m[16],m[17],m[18],m[19],m[20],m[21],m[22],m[23],m[24],m[25],m[26],m[27],m[28],m[29],m[30],m[31]);
dialog=gtk_message_dialog_new(GTK_WINDOW(geany->main_widgets->window),
GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_ERROR,
GTK_BUTTONS_NONE,
"%s",temp);
gtk_dialog_add_button(GTK_DIALOG(dialog),_("_Okay"),GTK_RESPONSE_OK);
gtk_dialog_run(GTK_DIALOG(dialog));
gtk_widget_destroy(dialog);
g_free(temp);
This displays the value of each marker, and those that aren't being used
for anything are showing up as 0, and not 28 (SC_MARK_AVAILABLE).
I can see 4 options, and I'd like to see what people think about them, or
if they can think of any better solutions:
1) agree between plugin developers which markers they will use and use them
staticly (as we are now, but ensuring they don't overlap)
2) change scintilla or geany so that markers are set to SC_MARK_AVAILABLE
when it is initialised.
3) Have a plugin that is run before any others or some static code usable
by all plugins that sets all editor unused markers to SC_MARK_AVAILABLE
ready for the other plugins.
4) Have an option in the preferences for each plugin that uses markers to
allow users to define which markers are to be used by that plugin.
There are pros & cons to each of these:
With option 1 we will probably run out of markers for anyone wanting to
develop a new plugin. Also would have to change code if editor's use of
markers changed. It is easiest to implement here and now.
Option 2 would be the most versatile in the long run, but would require
altering someone else's project purely for our own devices, and it would
require anyone using a plugin using markers to have to use the latest
version of geany.
Option 3 would mean we could handle marker allocation in-house, but would
require an extra plugin, and can we ensure that it would be loaded before
any other plugin? Or would we agree that any plugin using markers would
have to access a shared piece of code that's keeping track of which markers
are being used to see what's available?
Option 4 would be simple for us to implement, but would be messy, and
complicated for the user (like having to set IRQ numbers in the old day to
get your PC to work).
My personal preference would be some shared static function that any plugin
using markers could access.
Looking forward to your opinions.
William Fraser
Hi folks,
Just something I thought on last merges based on Jiri's patches. Its
hard to understand what this merges do just by reading the commit
message. Given, that we want to create the ChangeLog based on git log it
will be nearly impossible to create a good ChangeLog/Newsfile if we
don't keep care..... Not sure how, but can we be more verbose here?
Cheers,
Frank
I don't agree with this change, the types are just that, types, not
keywords, they should not be highlighted as keywords. They are not
always available. This change should be reverted.
Cheers
Lex
On 25 February 2012 08:01, Frank Lanitz <git-noreply(a)geany.org> wrote:
> Branch: refs/heads/master
> Author: Frank Lanitz <frank(a)frank.uvena.de>
> Committer: Frank Lanitz <frank(a)frank.uvena.de>
> Date: Fri, 24 Feb 2012 21:01:08
> Commit: 795ee4cf4bea525814b5793a6771d3da78f6c863
> https://github.com/geany/geany/commit/795ee4cf4bea525814b5793a6771d3da78f6c…
>
> Log Message:
> -----------
> Merge pull request #28 from RetroX/patch-1
>
> Added size_t, ptrdiff_t, intN_t to filetypes.cpp.
>
>
> Modified Paths:
> --------------
> data/filetypes.cpp
>
> Modified: data/filetypes.cpp
> 2 files changed, 1 insertions(+), 1 deletions(-)
> ===================================================================
> @@ -3,7 +3,7 @@
>
> [keywords]
> # all items must be in one line
> -primary=alignas alignof and and_eq asm auto bitand bitor bool break case catch char char16_t char32_t class compl const constexpr const_cast continue decltype default delete do double dynamic_cast else enum explicit export extern false final float for friend goto if inline int long mutable namespace new noexcept not not_eq nullptr operator or or_eq override private protected public register reinterpret_cast return short signed sizeof static static_assert static_cast struct switch template this thread_local throw true try typedef typeid typename union unsigned using virtual void volatile wchar_t while xor xor_eq
> +primary=alignas alignof and and_eq asm auto bitand bitor bool break case catch char char16_t char32_t class compl const const_cast constexpr continue decltype default delete do double dynamic_cast else enum explicit export extern false final float for friend goto if inline int int8_t int16_t int32_t int64_t long mutable namespace new noexcept not not_eq nullptr operator or or_eq override private protected ptrdiff_t public register reinterpret_cast return short signed sizeof size_t static static_assert static_cast struct switch template this thread_local throw true try typedef typeid typename union unsigned using virtual void volatile wchar_t while xor xor_eq
> secondary=
> # these are some doxygen keywords (incomplete)
> docComment=attention author brief bug class code date def enum example exception file fn namespace note param remarks return see since struct throw todo tparam typedef var version warning union
>
>
>
> --------------
> This E-Mail was brought to you by github_commit_mail.py (Source: TBD).
> _______________________________________________
> Geany-commits mailing list
> Geany-commits(a)uvena.de
> https://lists.uvena.de/cgi-bin/mailman/listinfo/geany-commits