Re: custom text editor widget
- From: "ivar ." <ivarbug gmail com>
- To: Kjell Ahlstedt <kjell ahlstedt bredband net>
- Cc: gtkmm-list gnome org
- Subject: Re: custom text editor widget
- Date: Thu, 20 Sep 2012 16:33:40 +0300
Imre, try using Pango::Layout. That's what I once did and I'm guessing
that's what TextView/GtkTextLayout uses in the end. Maybe TextBuffer
has features that should affect the rendering, I don't know. I
rendered my own text.
On Thu, Sep 20, 2012 at 4:19 PM, Kjell Ahlstedt
<kjell ahlstedt bredband net> wrote:
> 2012-09-20 09:23, Horváth Imre skrev:
>>
>> Hi!
>>
>> I want to create a custom textedit widget (with text cursor), with it's
>> own TextBuffer.
>> My problem is to render the TextBuffer.
>> In the gtk+ sources, TextView renders the TextBuffer through a
>> GtkTextLayout object (I think), but I can not find it in Gtkmm.
>>
>> Any help is appreciated:
>> Imre Horvath
>>
> The file gtktextlayout.h contains the comment
>
> /* This is a "semi-private" header; it is intended for
> * use by the text widget, and the text canvas item,
> * but that's all. We may have to install it so the
> * canvas item can use it, but users are not supposed
> * to use it.
> */
> #ifndef GTK_TEXT_USE_INTERNAL_UNSUPPORTED_API
> #error "You are not supposed to be including this file; the equivalent
> public API is in gtktextview.h"
> #endif
>
> That's a good reason for not having a Gtk::TextLayout in gtkmm.
>
> Kjell
>
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> https://mail.gnome.org/mailman/listinfo/gtkmm-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]