Many thanks to everyone who has written in regarding this query
(I don't have an internet connection at home, hence the delayed
response). I will go and  try out your suggestion.
   Cheers, D. 


-------- Original Message --------
From: Madhusudan E <[EMAIL PROTECTED]>
Apparently from: [EMAIL PROTECTED]
To: [EMAIL PROTECTED], gtk-app-devel-list@gnome.org
Subject: RE: (Easy?) Newbie enquiry re: pointers
Date: Wed, 11 Oct 2006 10:06:21 +0530

> 
> ||I am currently attempting to write my first GTK program, which is
> || a graphical mp3 jukebox frontend to the mpg123 linux command.
> ||I wish to have each button on a grid correspond to a different mp3 track.
> ||To do this I pass a pointer to a string (the name of the mp3 file) to the
> ||respective button callback functions.  This all works 
> || well -  the problem is that I have also built a 'reload button'
> ||which refreshes all the strings so that the same button then plays a
> || different track to before the reload. 
> ||
> ||The problem is that 
> || even though the strings the pointers point to do seem to change 
> || (I write them out on leaving gtk_main) the buttons still seem to point to
> 
> ||the orignal strings, even though they have been overwirtten.
> ||Thus the button seems locked on to the original mp3 filename
> || even if I overwrite this string.
> 
> While rebuilding the UI, you can use gtk_button_set_label() to change the
> label name. It will reset the earlier labels used. Hope this helps.
> 
> ||
> ||
> ||I guess this problem is perhaps easily overcome? (I can supply whatever
> ||details you may require including the code itself).
> 
> ||Many thanks,
> ||              Dan.
> ||p.s. I am new to GUI programming so please keep the advice at 'idiot
> level'!
> _______________________________________________
> gtk-app-devel-list mailing list
> gtk-app-devel-list@gnome.org
> http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
> 
> 
> _______________________________________________
> gtk-app-devel-list mailing list
> gtk-app-devel-list@gnome.org
> http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to