View Full Version : gtk_object question
maslan
hi
i want some 1 describe to me those instuction :
gtk_object_set_data
gtk_object_get_data
thanks
bye
:)
uniball
Use them to store some data into the gobject and retrieve them later when you want.
I don't think you'll need these functions ;)
what are you trying to do ?
maslan
now i'm not doing any thing but i learning Gtk+ beside
i read many progs source code
as glade source
gtk+ source
may be after reaching the skill i need i will build some progs
& i may use assembly & link it with gtk+lib so i can write them in assembly but that's later i don't think about it now.
so in glade source i find usage of gtk_object_set_data() & gtk_object_get_data()
so can u send me an example on how to use them.
thanks bye ;)
maslan
so can u send me a simple source with describtion ?
:)
uniball
I don't have an example, though i fully understand what they do.
I didn't have to use them till now.
glade is complicated, Have a look at a simpler prog.
You can have a look at the gtk examples.
Don't wait till you reach the skill u need.
If you begin coding, You'll reach it faster.
I till now have the Gtk+ reference Manual opened as well as glib, pango reference manual.
Katoob was my 1st Gtk app.
The code was something i don't know how i did such a bad thing. Though i'm proud now with the current CVS code ;-)
maslan
i have see glade example editor .
but i need some more difficult code to get the power i needed.
;)
ok i will take with ur advise
thanks
bye.:D
maslan
ok another thing
if a i made a label containing text & font selection dialog
how can i use it to change the label text.
&what is MainWindowKey sometimes i found it.
:)
uniball
I said the Gtk examples Not the glade example !!
gchar *font = NULL;
GtkWidget *dlg;
font = gtk_font_selection_dialog_get_font_name (GTK_FONT_SELECTION_DIALOG
(dlg));
if (font)
{
gtk_label_set_markup (GTK_LABEL (font_label),
g_strdup_printf
("<span font_desc=\"%s\">%s</span>", font,
font));
g_free (font);
}
Where did you find "MainWindowKey" ??
maslan
hi thnx 4 the code
i found WindowMainKey in the glade example.:)
just read it ;)
vBulletin v3.0.1, Copyright ©2000-2004, Jelsoft Enterprises Ltd.