Rendering Plugin: GtkMathView
Hello Inkscape Hackers!
I have a couple of questions:
In general: Does the planned plugin architechture of Inkscape allow for rendering plugins, i.e. plugins that render new/custom/other tags in the SVG document (embedded via the foreignObject tag)?
More specifically: I would really like a MathML rendering plugin. Does your (planned) plugin architechture allow for such a thing?
If it does, my suggestion is the following: GtkMathView [1] is a very mature MathML rendering engine which provides a) a GTK rendering widget, b) a C++ interface for rendering MathML and, most importantly, a Bonobo component. For details see [1]. It might be possible to use this to render MathML formulas inside pictures/diagramms created with Inkscape without too much implementation effort (?).
Rationale: Currently there is no modern visual software to create mathematical/technical drawings. The free software user who needs such drawings (i.e. drawings that contain formulas) is forced to use programms like Xfig or to hand-code these drawings in LaTeX. Neither approach suits me and most of the mathematicians I know rather stick to pen and paper because of that. Hence, I think there is a not-too-small community of people who would be interested in this feature.
If you think this is feasible with regard to Inkscape's plugin architechture, I might well take to the task of implementing the actual plugin. Please tell me what you think.
Regards, Felix
On Wed, 7 Jan 2004, Felix Breuer wrote:
Hello Inkscape Hackers!
I have a couple of questions:
In general: Does the planned plugin architechture of Inkscape allow for rendering plugins, i.e. plugins that render new/custom/other tags in the SVG document (embedded via the foreignObject tag)?
In general, yes we want it to have this capability, however I think it's probably a long way off. There's a lot of structural code changes in areas like style.cpp that need to be done before we can think of moving them to extensions. But putting some design thought into the requirements for it at this point would be very valuable.
More specifically: I would really like a MathML rendering plugin. Does your (planned) plugin architechture allow for such a thing?
If it does, my suggestion is the following: GtkMathView [1] is a very mature MathML rendering engine which provides a) a GTK rendering widget, b) a C++ interface for rendering MathML and, most importantly, a Bonobo component. For details see [1]. It might be possible to use this to render MathML formulas inside pictures/diagramms created with Inkscape without too much implementation effort (?).
Rationale: Currently there is no modern visual software to create mathematical/technical drawings. The free software user who needs such drawings (i.e. drawings that contain formulas) is forced to use programms like Xfig or to hand-code these drawings in LaTeX. Neither approach suits me and most of the mathematicians I know rather stick to pen and paper because of that. Hence, I think there is a not-too-small community of people who would be interested in this feature.
That sounds like something well suited to Inkscape. A number of people have been working on or are interested in seeing more technical-oriented features, and being able to display mathematical equations would be a very desireable feature.
If you think this is feasible with regard to Inkscape's plugin architechture, I might well take to the task of implementing the actual plugin. Please tell me what you think.
We're pretty early on in developing the extension architecture; it may not be fully usable until late 2004.
Here's a few options for you to consider:
1. Bypass the extension architecture and put it directly in the code. The boolean functionality serves as a good model for how this can be effectively handled - add your code in a subdir under inkscape/src/, and integrate it into the build system, then work in the hooks for using your code whereever they're needed. Submit it as a big patch for folks to test, integrate, and poke and prod.
If the code adds an unusual dependency, make sure to talk with some of the other developers first; we need to be careful that new dependencies are going to be widely available enough that people who don't need the feature won't be bothered by having to install extraneous dep's. A good rule of thumb is to look at what's available on redhat 7.3, OSX, and Win2k.
2. Help in developing the extension architecture. This will be of immense benefit to the project in general, but is the long road to getting MathML support. It's definitely the "right way" to go, but realize that we're starting essentially from scratch right now, so there's a lot of definition work to be done.
3. See if you can make use of one of the other extension mechanisms already implemented. For example, the stdin/stdout commandline scripting interface (see the roundhole script as an example). My guess is that it isn't going to be powerful enough for this case, but who knows.
So, if you have interest in developing the extension system, go that route, otherwise I recommend that you investigate feasibility of adding it directly to the codebase (for now). You can either submit a proposal for consideration, or go ahead and prepare a patch that does it and we can review and discuss it subsequently, depending on what you're most comfortable with.
Bryce
We're pretty early on in developing the extension architecture; it may not be fully usable until late 2004.
I would be interested also with an extension ability to implement some openGis functionnality. It would not need a lot of new functionnality (drawing-stuff) but much more of element-properties-stuff such as new attributes in xml elements. I am not a guru in C nor C++ so i don't want to bypass the extension in order not to break things already working. i am listenting carefully to the extension thread and try to pick up (and understant) what is going on.
when i'll go on coding the situation will have moved on a little and i'll see what i can do...
Here's a few options for you to consider:
- Help in developing the extension architecture. This will be of immense benefit to the project in general, but is the long road to getting MathML support. It's definitely the "right way" to go, but realize that we're starting essentially from scratch right now, so there's a lot of definition work to be done.
So, if you have interest in developing the extension system, go that route, otherwise I recommend that you investigate feasibility of adding it directly to the codebase (for now). You can either submit a proposal
I will look for that, but it semmes to me a long way from home :-(
hervé
Felix Breuer wrote:
Hello Inkscape Hackers!
I have a couple of questions:
In general: Does the planned plugin architechture of Inkscape allow for rendering plugins, i.e. plugins that render new/custom/other tags in the SVG document (embedded via the foreignObject tag)?
More specifically: I would really like a MathML rendering plugin. Does your (planned) plugin architechture allow for such a thing?
If it does, my suggestion is the following: GtkMathView [1] is a very mature MathML rendering engine which provides a) a GTK rendering widget, b) a C++ interface for rendering MathML and, most importantly, a Bonobo component. For details see [1]. It might be possible to use this to render MathML formulas inside pictures/diagramms created with Inkscape without too much implementation effort (?).
One issue with this is that gtkmathview doesn't respect transparency or affine transforms. This means that if you rotate a math object, or put something behind it, it will look ugly.
Possibly a better approach would be to get the appropriate subsystem to place glyphs on the canvas directly this would have the added advantage of being able to convert to paths, and allow the same fonts as other text in inkscape.
Personally I found mathml an abbomiation to work with, if anything I'd like the entry to be as latex :)
Related problems include music typesetting (lilypond) and simple visual languages.
njh
Felix Breuer wrote:
Hello Inkscape Hackers!
I have a couple of questions:
In general: Does the planned plugin architechture of Inkscape allow for rendering plugins, i.e. plugins that render new/custom/other tags in the SVG document (embedded via the foreignObject tag)?
More specifically: I would really like a MathML rendering plugin. Does your (planned) plugin architechture allow for such a thing?
If it does, my suggestion is the following: GtkMathView [1] is a very mature MathML rendering engine which provides a) a GTK rendering widget, b) a C++ interface for rendering MathML and, most importantly, a Bonobo component. For details see [1]. It might be possible to use this to render MathML formulas inside pictures/diagramms created with Inkscape without too much implementation effort (?).
One issue with this is that gtkmathview doesn't respect transparency or affine transforms. This means that if you rotate a math object, or put something behind it, it will look ugly.
Possibly a better approach would be to get the appropriate subsystem to place glyphs on the canvas directly this would have the added advantage of being able to convert to paths, and allow the same fonts as other text in inkscape.
Personally I found mathml an abbomiation to work with, if anything I'd like the entry to be as latex :)
Related problems include music typesetting (lilypond) and simple visual languages.
Hi I'm working with Luca to use GtkMathView as the Maths renderer for AbiWord. GtkMathView actually writes to an abstract canvas (similar to AbiWord). It may well be possible to write an interface to to map GtkMathView's abstract canvas to inkscape's.
We're currently working on enabling editting of Formulae with GtkMathView. The plan is to have both a pallete system similar to MS Word equation editor and a command line interface which allows you to type equations in Tex or Latex and have them render in a preview widget as you type.
Regarding affine transformations, I wasn't aware that inkscape could do that with plain Text yet. Is that a newly implemented feature or have I missed something in the interface?
Cheers
Martin
njh
This SF.net email is sponsored by: Perforce Software. Perforce is the Fast Software Configuration Management System offering advanced branching capabilities and atomic changes on 50+ platforms. Free Eval! http://www.perforce.com/perforce/loadprog.html _______________________________________________ Inkscape-devel mailing list Inkscape-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/inkscape-devel
msevior@...79... wrote:
Hi I'm working with Luca to use GtkMathView as the Maths renderer for AbiWord. GtkMathView actually writes to an abstract canvas (similar to AbiWord). It may well be possible to write an interface to to map GtkMathView's abstract canvas to inkscape's.
We're currently working on enabling editting of Formulae with GtkMathView. The plan is to have both a pallete system similar to MS Word equation editor and a command line interface which allows you to type equations in Tex or Latex and have them render in a preview widget as you type.
yep. This is good! Would you like to meet up sometime soon for a chat?
Regarding affine transformations, I wasn't aware that inkscape could do that with plain Text yet. Is that a newly implemented feature or have I missed something in the interface?
Been there for years. click on text with the arrow tool, click again - the arrows turn and you can rotate the text (or shear).
p.s. You don't happen to know V. Kowalenko do you?
njh
msevior@...79... wrote:
Hi I'm working with Luca to use GtkMathView as the Maths renderer for AbiWord. GtkMathView actually writes to an abstract canvas (similar to AbiWord). It may well be possible to write an interface to to map GtkMathView's abstract canvas to inkscape's.
We're currently working on enabling editting of Formulae with GtkMathView. The plan is to have both a pallete system similar to MS Word equation editor and a command line interface which allows you to type equations in Tex or Latex and have them render in a preview widget as you type.
yep. This is good! Would you like to meet up sometime soon for a chat?
Yes. That would be good. Right now I'm on holiday at Point Lonsdale though :-) I won't get back to work until February.
Regarding affine transformations, I wasn't aware that inkscape could do that with plain Text yet. Is that a newly implemented feature or have I missed something in the interface?
Been there for years. click on text with the arrow tool, click again - the arrows turn and you can rotate the text (or shear).
Oh well. I blame the poor sodipodi UI for me not finding it.
p.s. You don't happen to know V. Kowalenko do you?
Yes I know Victor. I see him often.
Cheers
Martin
participants (5)
-
unknown@example.com
-
Bryce Harrington
-
Felix Breuer
-
herve couvelard
-
Nathan Hurst