Re: Color and Font
| From: | Eduardo RBS | Date: | Wed, 08 Feb 2006 15:09:39 +0000 |
| Subject: | Re: Color and Font | ||
| References: | 1 2 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-6682@lists.php.net to get a copy of this message | ||
thanks for the help Pablo,
I just found another way to do it.. see:
$this->entry_codmerc=$this->xml->get_widget("entry_codmerc");
$azul=new GdkColor(0,0,65535,0);
$this->entry_codmerc->modify_text(0,$azul);
$fonte= new PangoFontDescription;
$fonte->set_size(20000);
$this->entry_codmerc->modify_font($fonte);
2006/2/7, Pablo Dall'Oglio <pablo@dalloglio.net>:
>
> much easier ;-)
>
> $label = new GtkLabel();
> $label->set_markup('<span foreground="blue"
> background="gray"><b>Text:
> Blue on gray</b></span>');
>
> Em Ter, 2006-02-07 às 17:01 -0200, Eduardo RBS escreveu:
> > Hi..
> > With php-gtk1 I used this to use some font with blue color.
> > $this->Azul= new GtkStyle;
> > $this->Azul->fg[GTK_STATE_NORMAL] = new GdkColor("#0000FF");
> >
> > $this->Azul->font=gdk::font_load("-*-*-bold-r-*-*-*-180-*-*-*-*-*-*");
> >
> > How to do the same thing with php-gtk2? How to work with fonts and
> colors?
> > --
> > []'s
> > Eduardo RBS
> > http://linuxstok.sourceforge.net
> --
> :: Pablo Dall'Oglio
> :: www.dalloglio.net
>
>
--
[]'s
Eduardo RBS
http://linuxstok.sourceforge.net