jettero has asked for the wisdom of the Perl Monks concerning the following question:

I'm using gtk-perl to write my newest and super fun project. When you adjust the size of a CList column you have to do it in pixels. Not terribly helpfull really since I know of no way to get the size of a string in a non-fixed width font (nor even what gnome font is set...).

Know of a way to calculate the pixel width of a string in perl?

Replies are listed 'Best First'.
Re: jettero's unnamed question about gtk-perl
by Adam (Vicar) on Nov 17, 2000 at 05:37 UTC
    I don't know the answer to your question, but it would be easier for other people to find your question if you gave it a title.

    Update: this post is no longer relevant as a title has now been given to node id 42140.

Re: GTK-Perl question
by qi3ber (Scribe) on Nov 17, 2000 at 19:52 UTC
    I have also been trying to find a way to perform this operation. It occurs to me that this would be some sort of Gdk::Font functionality (if there is such a thing).


       [ qi3ber ] I used to think that I knew it all, then I started to listen.
      I'm not opposed to writing a Gdk::wtf_is_the_font_size module... but afaik gtk programmers have the same trouble ...