Hi all,
Recently I've been playing with compiling Inkscape against the experimental native quartz (Mac OS X) backend for GTK+ [1] and I've had some reasonable success so far.
After following the GTK+ build instructions on the Imendio project page, I then compiled all the pre-reqs for Inkscape into a custom prefix (/opt/gtk), and then compiled Inkscape using:
CFLAGS="-flat_namespace -undefined suppress" ./configure --prefix=/opt/gtk
The result is a binary that I can run (using inkscape -g) and doesn't require X11 at all.
A screenshot is available.[2]
It loads fine, and I can open and edit files. The problems so far: 1. Various visual glitches (eg. some icons in GTK dialogs displaying an ugly yellow, scroll bar glitches, menus not being entirely responsive), 2. Some random crashes when dealing with complex SVGs, 3. Very slow refresh of canvas, which gets painted in gray first, then you can visibly see it paint the canvas on from top to bottom. This happens regularly when interacting or scrolling.
Problem 3 is by far the most noticable, and if it wasn't for that (and the odd crash) it would be quite usable!
Having no experience with developing Inkscape (and very little with GTK+), can someone give me a clue as to which package I need to focus on to troubleshoot #3? Does Inkscape use Cairo to paint the canvas? Or is it pure GDK? Or cairo via GTK+? You can see I know very little here ;)
Anyway the progress so far is impressive, and I don't think it will be too much longer before it would be realistic to start integrating GTK+ further into the OS (eg. using native OSX menu bar, a quartz widget gtk-theme-engine, etc).
Cheers Derek
[1] http://developer.imendio.com/projects/gtk-macosx/ [2] http://www.hinchy.org/inkscape/inkscape-gtk-quartz.png
On 11/6/06, Derek Hinchliffe <derek@...1264...> wrote:
A screenshot is available.[2]
Another problem (dunno if it's specific to your build or to OSX in general): text-on-path.svg contains a line in Russian (in red color) but it's missing on your screenshot. On Linux and Windows, Pango finds and uses any font with Cyrillic characters even if it's not the font specified for this text object. So either your OSX has no Cyrillic in any font at all, or Pango on OSX fails to substitute it.
On 11/7/06, bulia byak <buliabyak@...400...> wrote:
On 11/6/06, Derek Hinchliffe <derek@...1264...> wrote:
A screenshot is available.[2]
Another problem (dunno if it's specific to your build or to OSX in general): text-on-path.svg contains a line in Russian (in red color) but it's missing on your screenshot. On Linux and Windows, Pango finds and uses any font with Cyrillic characters even if it's not the font specified for this text object. So either your OSX has no Cyrillic in any font at all, or Pango on OSX fails to substitute it.
Well spotted. I think that is a known problem with the Pango OSX port.
From the ToDo list[1]:
Investigate why the font substitution that should be done when a font can't be loaded (Monospace Oblique in gtk-demo for example) doesn't work (medium)
That sounds very much like it would cause the missing Cyrillic chars.
Speaking of the ToDo list, it really isn't that long, and it seems fairly comprehensive (based on the fact that every problem I'm encountered is listed on as a Todo item). So I'm going to be tackling all the easy/medium ones that I can get my head around, and will be using Inkscape as my test app so hopefully we'll see some progress.
Having said that I think it might be some time before we see things like native tablet support, which I think would be a big requirement for getting more people using it on Macs.
Cheers Derek
On Tue, Nov 07, 2006 at 10:33:44AM +0800, Derek Hinchliffe wrote:
Hi all,
Recently I've been playing with compiling Inkscape against the experimental native quartz (Mac OS X) backend for GTK+ [1] and I've had some reasonable success so far.
Very cool! You have no idea how many times we've been asked about this, so it's extremely nice to see someone work out how to do it. It would be wonderful if you could share how to do this, for the Inkscape 0.45 release.
Bryce
On 11/7/06, Bryce Harrington <bryce@...961...> wrote:
On Tue, Nov 07, 2006 at 10:33:44AM +0800, Derek Hinchliffe wrote:
Hi all,
Recently I've been playing with compiling Inkscape against the experimental native quartz (Mac OS X) backend for GTK+ [1] and I've had some reasonable success so far.
Very cool! You have no idea how many times we've been asked about this, so it's extremely nice to see someone work out how to do it. It would be wonderful if you could share how to do this, for the Inkscape 0.45 release.
Bryce
I'll add some info to the wiki when I get a chance in the next few days. It was pretty straightforward though, anyone who has compiled Inkscape on OS X before should be able to follow the instructions on the Imendio page, then compile Inkscape as normal pointing it to use the quartz gtk tree instead of the fink/darwinports one.
As for the 0.45 release, the quartz backend is still too experimental. There is still a lot of tiding up to do before you'd want to offer a stable release using it.
I also haven't managed to make an Inkscape.app package that works yet. I tried modifying the existing packaging scripts to remove the X11 loading etc, and got it to work except there is something missing in the pango stuff so all text is garbled... but I probably just need to be including some extra libs or config files in the package.
For anyone interested in more details of the GTK+ OSX port, I noticed a thesis report from the original developer was released just the other day at http://developer.imendio.com/node/62
Cheers Derek
On 2006-November-07 , at 04:15 , Derek Hinchliffe wrote:
On 11/7/06, Bryce Harrington <bryce@...961...> wrote:
On Tue, Nov 07, 2006 at 10:33:44AM +0800, Derek Hinchliffe wrote:
Hi all,
Recently I've been playing with compiling Inkscape against the experimental native quartz (Mac OS X) backend for GTK+ [1] and I've had some reasonable success so far.
Very cool! You have no idea how many times we've been asked about this, so it's extremely nice to see someone work out how to do it. It would be wonderful if you could share how to do this, for the Inkscape 0.45 release.
Bryce
I'll add some info to the wiki when I get a chance in the next few days. It was pretty straightforward though, anyone who has compiled Inkscape on OS X before should be able to follow the instructions on the Imendio page, then compile Inkscape as normal pointing it to use the quartz gtk tree instead of the fink/darwinports one.
That would really be great. Thanks for taking the time to sort all this out.
[...] I also haven't managed to make an Inkscape.app package that works yet. I tried modifying the existing packaging scripts to remove the X11 loading etc, and got it to work except there is something missing in the pango stuff so all text is garbled... but I probably just need to be including some extra libs or config files in the package.
I have had the same problem with Pango and trying to make an .app package from darwinports libraries rather than from Fink provided libraries. The wiki page about compiling Inkscape on mac os x is still incomplete because of that. It's probably the place where to add stuff about the native compilation: http://wiki.inkscape.org/wiki/index.php/CompilingMacOsX
I tried to switch to darwinports for three reasons: - the packages they propose are usually newer than the ones from Fink. There was a discussion about switching to a newer GTK version which available only in DarwinPorts + there is a strange bug in OS X which seems to come from glibmm and I wanted to try DarwinPorts version (and the bug is still present BTW) - the system is somehow cleaner - the official way of building native gtk libraries is via darwinports. So I think that in the long run it would be great to have all dependencies in one place and just tell people who want to compile on OS X to install darwinports and get a specific list of packages.
Feel free to modify the text on the wiki and add whatever is needed. I'll try to complete the DarwinPorts part when I get time for it.
Thanks again.
JiHO --- http://jo.irisson.free.fr/
On Mon, 6 Nov 2006, Bryce Harrington wrote:
On Tue, Nov 07, 2006 at 10:33:44AM +0800, Derek Hinchliffe wrote:
Hi all,
Recently I've been playing with compiling Inkscape against the experimental native quartz (Mac OS X) backend for GTK+ [1] and I've had some reasonable success so far.
Very cool! You have no idea how many times we've been asked about this, so it's extremely nice to see someone work out how to do it. It would be wonderful if you could share how to do this, for the Inkscape 0.45 release.
I too have just been looking at this and conincidetly got to the same stage as Derek. I aggree with him that we won't want to release 0.45 targeting the native GTK port unless most of the issues and probably speed problems could be worked out before then (unlikely).
Also, I have commited to our repository a modified version of Imendio's build script that also handles all the Inkscape dependencies and Inkscape itself: packaging/macosx/native-gtk/build-gtk.sh
I make no guarantees about it, but it should work, and it's probably worth Derek giving comments on this, or using it for his instruction on the wiki rather than writing instructions from scratch.
Effectively the build instructions are the same as: http://developer.imendio.com/projects/gtk-macosx/build-instructions
Probably its as simple as running the following (though you may need cogito and svn installed from fink): export PREFIX=/your/install/prefix ./build-gtk bootstrap ./build-gtk build inkscape
Cheers, Michael
On Tue, Nov 07, 2006 at 10:33:44AM +0800, Derek Hinchliffe wrote:
Recently I've been playing with compiling Inkscape against the experimental native quartz (Mac OS X) backend for GTK+ [1] and I've had some reasonable success so far.
Having no experience with developing Inkscape (and very little with GTK+), can someone give me a clue as to which package I need to focus on to troubleshoot #3? Does Inkscape use Cairo to paint the canvas? Or is it pure GDK? Or cairo via GTK+? You can see I know very little here ;)
Anyway the progress so far is impressive, and I don't think it will be too much longer before it would be realistic to start integrating GTK+ further into the OS (eg. using native OSX menu bar, a quartz widget gtk-theme-engine, etc).
Jon Cruz is the developer to get hooked up with for this; he's also on OSX and knows all the ins and outs of the widgets, gtk, etc.
...unfortunately he's been through a fire, and is still getting his computers back online and stuff. But if you spot him on IRC, I think he'd love to chat about what needs doing.
Bryce
On Nov 6, 2006, at 7:07 PM, Bryce Harrington wrote:
Jon Cruz is the developer to get hooked up with for this; he's also on OSX and knows all the ins and outs of the widgets, gtk, etc.
...unfortunately he's been through a fire, and is still getting his computers back online and stuff. But if you spot him on IRC, I think he'd love to chat about what needs doing.
Yes, I'm getting things back up now.
I'd gotten close to finishing some work on switching to stock toolbars. Once that was set I was going to try to be looking into updating to build the native GTK+ and such, so this timing sounds good.
Also, I've gotten my main Mac up and going again, and have just finished rescuing data off of my wife's computer, so I'll be able to focus on Inkscape again. Definitely watch the Jabber room evening and nights PST, as I'll be back in now.
On 11/8/06, Jon A. Cruz <jon@...18...> wrote:
On Nov 6, 2006, at 7:07 PM, Bryce Harrington wrote:
Jon Cruz is the developer to get hooked up with for this; he's also on OSX and knows all the ins and outs of the widgets, gtk, etc.
...unfortunately he's been through a fire, and is still getting his computers back online and stuff. But if you spot him on IRC, I think he'd love to chat about what needs doing.
Yes, I'm getting things back up now.
I'd gotten close to finishing some work on switching to stock toolbars. Once that was set I was going to try to be looking into updating to build the native GTK+ and such, so this timing sounds good.
Also, I've gotten my main Mac up and going again, and have just finished rescuing data off of my wife's computer, so I'll be able to focus on Inkscape again. Definitely watch the Jabber room evening and nights PST, as I'll be back in now.
I'll try and get onto the Jabber room at some point soon to discuss some of the issues I've encountered so far. Although I'm having problems finding any time to spare on it right now between work and life in general.
One quick thing - I mentioned previously that I was having regular crashes with complex SVGs (eg. tiger.svgz). Well it seems that after fixing one memory leak in GTK+ (2 lines of code) I haven't had any crashes since. So the port does seem to be at the stage where fixing very small problems can have very rewarding results.
Cheers Derek
participants (6)
-
Bryce Harrington
-
bulia byak
-
Derek Hinchliffe
-
jiho
-
Jon A.Cruz
-
Michael Wybrow