[Glade-users] GtkEntry
- From: wambenarcisse at yahoo.fr (narcisse doudieu siewe)
- Subject: [Glade-users] GtkEntry
- Date: Tue, 10 Jun 2014 10:02:58 +0100 (BST)
Ho excuse me this is not correct. The correct form is like this:
const char* text = gtk_entry_get_text( GTK_ENTRY(entry));
or
const char* text = gtk_entry_get_text( (GtkEntry *) entry);
GTK_ENTRY is a macro to cast your pointer to a pointer on GtkEntry widget
(GtkEntry *) do the same thing it is the way to do casting in c language
Le Mardi 10 juin 2014 3h57, Anthony Dardis <adardis at gmail.com> a ?crit :
The argument is supposed to be a
??? GtkEntry *
so you want something like
GtkEntry *myEntry;
...
txt_pt = gtk_entry_get_text (myEntry);
???
On 6/9/14 10:20 PM, Ian Chapman wrote:
Yes, that's correct there should not be a comma, my typo, playing too long with it.? Unfortunately I still
get the same error.
On 06/09/2014 08:47 PM, narcisse doudieu siewe wrote:
replace with
txt_pt = gtk_entry_get_text (GtkEntry(entry));
the is problem, the comma after?GtkEntry
Le Mardi 10 juin 2014 1h14, Ian Chapman <ichapman at videotron.ca> a ?crit :
Many thanks to John and Martin for their help. I've another difficulty
that I do could not figure out. In glade 3.14.2 I have
window with a
container box and in one of the compartments of the
box I have Text
Entry that shows in the inspector as GtkEntry
(FileName).
I should be able to read the text with
const gchar *txt_pt;
txt_pt = gtk_entry_get_text (GtkEntry, (entry)); //
error: expected
expression before ?GtkEntry?
I should also be able to write with
void
gtk_entry_set_text (GtkEntry entry, "hello");
//expected declaration
specifiers or ?...? before string constant
But I get these errors. Also if I have more than one
Text Entry how do I
select between them? Thanks in advance Ian.
_______________________________________________
Glade-users maillist? -? Glade-users at lists.ximian.com
http://lists.ximian.com/mailman/listinfo/glade-users
_______________________________________________
Glade-users maillist - Glade-users at lists.ximian.com http://lists.ximian.com/mailman/listinfo/glade-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/glade-users/attachments/20140610/b5751246/attachment.html>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]