To fit the 
MVC<https://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93controller>(this
is very basic software design) I believe it is not a good idea to use
anything that directly depends on Gtk in the model (i.e. in structures
present in include/*.h). Simply to keep the principle of separating GUI and
real data, and because in the case we need to use Denemo without a GUI it
becomes problematic.

I did not deeply looked at this part of the code, so I am not sure. Don't
you think Denemo.textbuffer can be transformed as a gchar*, and be
synchronized with a GtkTextBuffer (or GtkSourceView) that would be internal
to exportlilypond.c ?


2014/1/14 Richard Shann <[email protected]>

> On Tue, 2014-01-14 at 17:34 +0100, Éloi Rivard wrote:
> > Do you know why Denemo.textbuffer is a GtkTextBuffer and not a simple
> > gchar* ?
>
> See:
>
> src/exportlilypond.c:   gtk_text_view_set_buffer (GTK_TEXT_VIEW
> (Denemo.textview), Denemo.textbuffer);
>
> and much else ... it just *is* a GtkTextBuffer for all the reasons that
> a GtkTextView requires. What would be an interesting project is to merge
> this as a GtkSourceView so that the LilyPond code could benefit from
> syntax highlighting, line numbering etc. There could be serious problems
> though with the GtkAnchors embedded to navigate from PDF to Denemo.
>
> Richard
>
>
> >
> > 2014/1/14 Éloi Rivard <[email protected]>
> >         Ok I did not know that. I get those warnings with this
> >         command:
> >         src/denemo -n --verbose -a "(d-CreateThumbnail #f)(d-Exit)"
> >         tests/integration-data/blank.denemo
> >
> >
> >
> >         2014/1/14 Richard Shann <[email protected]>
> >                 On Tue, 2014-01-14 at 16:27 +0100, Éloi Rivard wrote:
> >                 > 2014/1/14 Richard Shann <[email protected]>
> >                 >         The thumbnailer (run on exit from denemo) is
> >                 now throwing up a
> >                 >         warning
> >                 >         dialog saying "No text buffer" when it runs.
> >                 > Do you mean it is ran each time you quit denemo ?
> >
> >
> >                 It should run every time you close a file which does
> >                 not have an
> >                 up-to-date thumbnail. I haven't checked that this is
> >                 still working, but
> >                 as thumbnails haven't been working for a while nearly
> >                 every file I close
> >                 provokes this.
> >
> >                 Richard
> >
> >
> >
> >
> >
> >
> >
> >         --
> >         Éloi Rivard - [email protected]
> >
> >         « On perd plus à être indécis qu'à se tromper. »
> >
> >
> >
> >
> > --
> > Éloi Rivard - [email protected]
> >
> > « On perd plus à être indécis qu'à se tromper. »
> >
>
>
>


-- 
Éloi Rivard - [email protected]

« On perd plus à être indécis qu'à se tromper. »
_______________________________________________
Denemo-devel mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/denemo-devel

Reply via email to