After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 574010 - set_scroll_adjustments first parameter is GtkWidget* instead of VteTerminal*
set_scroll_adjustments first parameter is GtkWidget* instead of VteTerminal*
Status: RESOLVED OBSOLETE
Product: vte
Classification: Core
Component: general
0.17.x
Other All
: Normal enhancement
: ---
Assigned To: VTE Maintainers
VTE Maintainers
[fixed-next]
Depends on:
Blocks: vte1.0
 
 
Reported: 2009-03-04 00:24 UTC by Krzesimir Nowak
Modified: 2014-03-24 21:11 UTC
See Also:
GNOME target: ---
GNOME version: Unversioned Enhancement


Attachments
patch changing GtkWidget* into VteTerminal* and removing few lines. (2.21 KB, patch)
2009-03-04 00:27 UTC, Krzesimir Nowak
reviewed Details | Review

Description Krzesimir Nowak 2009-03-04 00:24:34 UTC
Shouldn't set_scroll_adjustments take the first parameter as VteTerminal* instead of GtkWidget*? All other default signal handlers take VteTerminal* as first parameter. Even documentation says "set-scroll-adjustments" signal handler receives VteTerminal*.

While wrapping this library for C++ I got an error during compile of generated files:
terminal.cc: In static member function ‘static void Vte::Terminal_Class::set_scroll_adjustments_callback(VteTerminal*, GtkAdjustment*, GtkAdjustment*)’:
terminal.cc:1804: error: cannot convert ‘VteTerminal*’ to ‘GtkWidget*’ in argument passing

So this one prevents me from wrapping vte.

I'll provide a patch.
Comment 1 Krzesimir Nowak 2009-03-04 00:27:34 UTC
Created attachment 129985 [details] [review]
patch changing GtkWidget* into VteTerminal* and removing few lines.

Diffs were done against svn version of vte, but are appliable also in 0.17.
Comment 2 Christian Persch 2009-03-04 13:18:54 UTC
Seems ok to me. However this is exposed in the header so part of the API, which means we can only change this when we next break API.
In the meantime, you could simply omit this vfunc from the wrapper.