Hi All,
OK, after further research I have stumbled on the answer:
As well as adding the GEANY_API_SYMBOL macro to the function definition, the
function declaration in keybindings.h also needs to be moved from the
#ifdef GEANY_PRIVATE
section, into the 'public' section. Dereffing the
Trying to programmatically cancel a text selection. There are functions that
will probably do it, e.g. sci_set_selection, but bearing in mind the
restriction on changing the API, those functions are not callable from my code.
Surely I'm missing something obvious here? I do hope so! :)
Hi Lex,
> > Trying to programmatically cancel a text selection. There are functions
> > that will probably do it, e.g. sci_set_selection, but bearing in mind the
> > restriction on changing the API, those functions are not callable from my
> > code.
> > Surely I'm missing something obvious
Hi All,
I'm new to Geany hacking, so please be kind in your response to possibly dumb
question.
Trying to make changes to "addons" plugin, and found that I needed to call
keybindings_get_core_group(), so added the GEANY_API_SYMBOL to that function
and rebuilt Geany. It appeared to work, in
> SCI_SETSEL(position anchor, position caret) ... scintilla_send_message()
> which is in the API
@Lex: Yay! SCI_SETSEL was right on target! Or "rem acu tetigiste" as the
Romans used to say. Overnight my brain had come up with the idea of
investigating the Scintilla message API, so you
Hi Scintilla experts,
I want to insert text at the caret position when the caret is in virtual space,
i.e. off the end of the line. Have tried
SCI_REPLACESEL
SCI_INSERTTEXT
and sundry ways of trying to find the amount of virtual space. The problem
with the latter is that there
Hi Lex,
On Tue, 12 May 2020 14:02:15 +1000
Lex Trotman wrote:
> On Tue, 12 May 2020 at 12:00, Austin Green wrote:
> > I need to ensure that one particular plugin will process keyboard events
> > before other plugins get to see them (as some plugins may cause further
> >
I need to ensure that one particular plugin will process keyboard events before
other plugins get to see them (as some plugins may cause further handling of
the event to be suppressed). Is there a way to achieve that? I'm guessing
that the order of calling the plug init functions is what
Hi Lex,
Further to my last message, which proposed: a new signal, say
"pre-key-press-event", then, in Geany start-up (before any plugin loading)
connect to "key-press-event". In the handler for "key-press-event", Geany just
emits "pre-key-press-event" with the same event data as was passed to
Hi Lex,
> Doesn't matter what you do, any handler returning TRUE will stop other
> handlers being called within signal_emit before it returns to you.
> https://developer.gnome.org/gtk3/stable/GtkWidget.html#GtkWidget-key-press-event
This is true, for 'key-press-event' and 'key-release-event' at
Hi Matthew,
> > No, I was wrong with my first guess about the order mattering; it turns
> > that it's just the fact that anything else (Geany or plugin) binds to a key
> > makes that key unavailable to 'keyrecord'.
>
> That doesn't sound right. Anything that connects to say
>
Well, whaddaya know? I cloned a recent version of geany, and found that
someone has already implemented a very similar Geany signal, called
"key-press". It was needed for the 'vimode' plugin, and at present that's the
only one that uses it. It differs from my proposal in that it can return
@Matthew:
> Further to my previous message, you might also inspect the existing
> plugins which are blocking GTK+ signals and see why they're doing that,
> whether on purpose or on accident, and possible ways they can not do that.
They block the key-press-event signal merely by binding to a
Hi Matthew,
> Just to be clear, you are talking about this:
> https://github.com/geany/geany-plugins/blob/062865e3b57a3baa882f69e4f3bc291278c200e4/keyrecord/src/keyrecord.c#L99
Yes, that's the one.
> and depending on the order the plugins connect to same signal as well as
> whether or not they
@Lex:
> Of course you can't enforce non-suppression, the best you can do is to
> document it clearly (hint not to forget the documentation :)
Actually you can (and my code currently does) enforce it, simply by ignoring
the return value from the g_signal_emit_by_name call. To make certain, if
@Matthew:
> You could use something like `gtk_key_snooper_install()`[0] to get
> priority access to keys. It's deprecated because the GTK+ team don't
> care about edge cases where it's useful, or other reasons, but it should
> still work fine with GTK2/3 on all platforms, though I haven't
Hi Matthew,
On Thu, 14 May 2020 16:20:58 -0700
Matthew Brush wrote:
> Can you elaborate on what you are trying to do specifically? There may
> be a better way.
Sure thing.
The plugin 'recordkey', and possibly others, connects to the 'key-press-event'
signal. Possibly depending on the order
Thanks for responding, Lex.
On Sun, 22 Mar 2020 12:47:56 +1000
Lex Trotman wrote:
> > I'm calling it Slick; I've created a slick.conf file, copied from the
> > default.conf,
> Neither grep nor I can find a file called default.conf??
Ooops, sorry, memory not working; it's been a while.
I'm trying to create a new Geany colour scheme, with only partial success.
I'm calling it Slick; I've created a slick.conf file, copied from the
default.conf, and made some changes. Some of them work, and some are ignored.
In particular, I want to change the colour of function names, so have
On Sun, 22 Mar 2020 14:03:29 +1000
Lex Trotman wrote:
> These are syntax highlighters, they only distinguish syntax, not
> semantics or symbols.
>
> It would therefore only be possible if functions are _syntactically_
> distinguishable from any other names, but that's not the case in most
>
Is there a mechanism for requesting changes to the plugin API? Other than this
list?
I would like to be able to call the function keybindings_check_event which is
in keybindings.c
___
Devel mailing list
Devel@lists.geany.org
Recently built (on Xubuntu system) Geany from source.
Version: geany 1.39 (git >= d031d6f2) (built on 2021-12-14 with GTK 3.24.30,
GLib 2.68.4)
Sometimes it emits hundreds of error messages of this general type:
(geany:7480): Gtk-CRITICAL **: 15:34:29.314: gtk_widget_hide: assertion
22 matches
Mail list logo