Commandline options
Implement code that takes argc,argv, parses it via popt, and stores it in a member of Inkscape::Application::Application in src/application/application.cpp. If you"ve not used popt before, here"s a handy PDF on it: http://www.rpm.org/local/popt.pdf
The current option handling code is in main.cpp, but is kind of hackish so feel free to redesign it a bit.
Glib 2.6 has a new API to address this need, if you're going to use glibmm the new API (GOption) is wrapped.
On Mon, Mar 14, 2005 at 07:56:07PM +0100, Diego Gonz?lez wrote:
Commandline options
Implement code that takes argc,argv, parses it via popt, and stores it in a member of Inkscape::Application::Application in src/application/application.cpp. If you've not used popt before, here's a handy PDF on it: http://www.rpm.org/local/popt.pdf
The current option handling code is in main.cpp, but is kind of hackish so feel free to redesign it a bit.
Glib 2.6 has a new API to address this need, if you're going to use glibmm the new API (GOption) is wrapped.
Well, I think popt as is should be more than sufficient to our needs. I would imagine cleaning up the existing popt handling would pretty straightforward. But thank you for taking a look at it!
Also, for the record, our plan is to not change the gtk/glib version to 2.6 in the near term (some distros are still just now catching up with gtk 2.4 (plus we have to worry about the Windows and OSX gtk ports)). In general, regardless of the library, we must be careful not to get too close to the bleeding edge with dependencies, or there will be a lot of user installation issues to have to handle. We have to be especially careful with upgrading Gtk because upgrading it actually implies upgrading half a dozen libraries, and we find this quantity of libs to be beyond the pain threshhold of many users. ;-)
Bryce
participants (2)
-
Bryce Harrington
-
Diego González