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 158280 - option to make gcalctool use only gtk
option to make gcalctool use only gtk
Status: RESOLVED FIXED
Product: gnome-calculator
Classification: Core
Component: general
unspecified
Other All
: Low enhancement
: ---
Assigned To: Rich Burridge
Rich Burridge
Depends on:
Blocks:
 
 
Reported: 2004-11-14 17:45 UTC by Alan Horkan
Modified: 2005-04-06 17:21 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch that hopefully provides this functionality. (5.06 KB, patch)
2005-03-23 16:47 UTC, Rich Burridge
none Details | Review
Patch to not show the Help->Contents menu item if gtk-only (1.42 KB, text/plain)
2005-04-06 17:19 UTC, Rich Burridge
  Details

Description Alan Horkan 2004-11-14 17:45:49 UTC
I love crossplatform software, I love being able to choose the same software
even if I do not have the choice to use Gnome.  

This request is for the option to build gcalctool using only gtk so that it
would be more portable and future proof in the long run.
Comment 1 Rich Burridge 2005-03-23 16:47:05 UTC
Created attachment 39138 [details] [review]
Patch that hopefully provides this functionality.

Note that you create the Gtk-only version by adding in
"--disable-gnome" as a command line option when running
configure.
Comment 2 Rich Burridge 2005-03-23 16:51:45 UTC
Changes checked into CVS HEAD. Version number in configure.in
bumped to 5.6.3.
Comment 3 Alan Horkan 2005-03-23 18:08:27 UTC
Thanks for this, I do appreciate it.  

From reading the patch it looks to me like Help files wont be available a
version built without Gnome support, using the menu item will result in a NO OP.  
It might be worth going one step further and hiding the Help contents menu (but
that is better left until more people are actually using the GTK only version. 
I'm eagerly watching Tor trying to build garnome on windows)

From what I can understand of the patch none of the other changes seem as
terrible as the warning message implies "Remove GNOME support. Don't do this, it
removes essential features" but I can understand the need from harsh warnings to
stop people like me from shooting ourselves in the foot.  

If you can spare a moment to explain if I'm failing to see/understand other
important details I'd appreciate it.  

Comment 4 Rich Burridge 2005-03-23 18:16:03 UTC
I asked on the #gnome IRC channel whether there were any apps
that did something like this, and i was pointed at Totem and
GnomeMeeting. I used the later as a model for how I did the
changes in gcalctool. It just wraps "#ifndef DISABLE_GNOME"'s
around the code in the help callbacks. I just did the same.

One of the big reasons why you might not want to use the 
GNOME libraries version of gcalctool is that accessibility
support won't automatically work. That's built into the
gnome_init() call but not the gtk_init() call. As you've
seen, help support is not their either.
Comment 5 Alan Horkan 2005-03-23 20:03:58 UTC
Abiword is another app that has both GTK and Gnome versions (and if I ever get
around to checking it for Accessibility I'll be sure to check the Gnome version
thanks to your comment above)

Thanks again.  
Comment 6 Kristof Vansant 2005-04-06 15:46:32 UTC
Euhm won't compiling it as gtk only program break the help?

Can someone plz test this
Comment 7 Kristof Vansant 2005-04-06 15:49:18 UTC
looks like the menu should not show help because it will do nothing.
Comment 8 Kristof Vansant 2005-04-06 15:51:49 UTC
something like:
haven't tested it :)

#ifndef DISABLE_GNOME
"      <menuitem action='Contents'/>"
#endif /*DISABLE_GNOME*/
Comment 9 Alan Horkan 2005-04-06 15:55:32 UTC
I think only GTK addicts like me will ever want the GTK only version for when
I'm stuck using Windows or other platforms that dont fully support Gnome.  

It will break the help, the only question is in what way will it fail.  
If it fails cleanly with a NO OP then I'd be happy enough to just leave it as is
if it is more of a problem I'd rather disable it and grey it out than remove it
and risk forgetting about it.  
Comment 10 Rich Burridge 2005-04-06 16:03:18 UTC
I like Kristof's fix. I'll try to get this in later today.
Comment 11 Rich Burridge 2005-04-06 17:19:31 UTC
Created attachment 39761 [details]
Patch to not show the Help->Contents menu item if gtk-only
Comment 12 Rich Burridge 2005-04-06 17:21:31 UTC
Changes checked into CVS HEAD. Version number in
configure.in bumped to 5.6.6. Thanks!