GtkCellRendererText

Has anyone got any inspired ideas how to make the text in a GtkCellRendererText selectable so the user can copy it? I’m trying to fix fd#19252 and it’s not obvious how you do this with GTK. Thanks.

Tags:

4 Responses to “GtkCellRendererText”

  1. Benjamin Otte says:

    I can tell you that it’s not possible afaik. Someone should probably complain about it loudly in the gtk bugtracker.
    I want to be able to copy/paste a whole tree view, too…

  2. Stian Skjelstad says:

    Use probably need to override an existing class and give it some more functionality. GtkLabel is a nice sample to steal code when it comes to text. It features both text selection and the possibility to make hyper-links. Once I needed to be able to make gtklabel act as an button and stole to hyper-links code and reused it, see pastebin reference bellow :-p

    http://pastebin.com/f1ed2586

  3. tvb says:

    Try making your cell renderer editable, and
    in start-editing set the actual entry widget that
    pops up not editable (so you can still select the
    entry), editing-canceled should be fired normally
    when the focus leaves the cell.

  4. Matt says:

    Have you tried turning it off and on again?