[Geany-Devel] Problems calling ui_update_statusbar from a plugin

Lex Trotman elextr at xxxxx
Sat Oct 31 10:28:26 UTC 2015


Nothing is usually added to the API "just because" since it has to be
maintained and supported and remain stable, and if the particular
function is too deep in the implementation that may constrain later
changes to Geany.  Things are mostly added these days if a plugin has
a need.

I guess we can take this as a request for the function to be added to the API :)

Maybe you can make a PR to speed the process.  Note the need to
doxygen document the function.

Cheers
Lex


On 31 October 2015 at 19:43, Abel <akronix5 at gmail.com> wrote:
> And why is not such function in the API? It's very used across all the geany
> code and there's no reason to think a plugin wouldn't ever want to use it.
>
> I want to display the document statistics of the document opened on split
> window when it gets the focus. ui_set_statusbar() let you display text but
> doesn't give you access to create_statusbar_statistics() neither to
> DEFAULT_STATUSBAR_TEMPLATE.
>
> Saludos,
>
>                                                        Abel.
>
> On 31 October 2015 at 03:59, Lex Trotman <elextr at gmail.com> wrote:
>>
>> See the big warning message at the start of the plugins doco
>> http://www.geany.org/manual/reference/ "Do not use any symbol not in
>> the documentation".
>>
>> On more recent versions of Geany the restriction on use of functions
>> not in the API is better enforced to reduce the risk of accidental
>> use.  Functions not in the API never worked on Windows I believe, so a
>> plugin that used non-API functions was not portable as well as
>> possibly breaking without warning.
>>
>> Can you not use
>>
>> http://www.geany.org/manual/reference/ui__utils_8h.html#aa0948006d2f45a2a2a6b7da40169b8ac
>>
>> Cheers
>> Lex
>>
>> On 31 October 2015 at 12:47, Abel <akronix5 at gmail.com> wrote:
>> > Hi!
>> >
>> > I'm hacking split window plugin and I wanted to use the function
>> > ui_update_statusbar(), located in ui_utils.h
>> >
>> > When I try to compile I get the following warning:
>> >
>> > "warning: implicit declaration of function 'ui_update_statusbar'
>> > [-Wimplicit-function-declaration]"
>> >
>> > And if I try yo execute the bin generated it doesn't allow you to enable
>> > that plugin, it is never shown anymore.
>> >
>> > The plugin includes geanyplugin.h which in turn includes ui_utils.h
>> >
>> > Some help or hints?
>> >
>> > _______________________________________________
>> > Devel mailing list
>> > Devel at lists.geany.org
>> > https://lists.geany.org/cgi-bin/mailman/listinfo/devel
>> >
>> _______________________________________________
>> Devel mailing list
>> Devel at lists.geany.org
>> https://lists.geany.org/cgi-bin/mailman/listinfo/devel
>
>
>
> _______________________________________________
> Devel mailing list
> Devel at lists.geany.org
> https://lists.geany.org/cgi-bin/mailman/listinfo/devel
>


More information about the Devel mailing list