Re: Problem with gtk_message dialog_new
- From: Antonio Gomes <tonikitoo gmail com>
- To: dimitri PIEL <d piel siepel com>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: Problem with gtk_message dialog_new
- Date: Sun, 17 Apr 2005 16:35:03 -0400
Hi,
I don't know exactually if this tip will solve your problem, but try
to "cast" the gpointer parameter to a "gchar pointer" , like the
fuction's assignature requires [1]
dialog=gtk_message_dialog_new (GTK_WINDOW(pWindow),
GTK_DIALOG_DESTROY_WITH_PARENT, GTK_MESSAGE_ERROR,GTK_BUTTONS_CLOSE,
(gchar *) message);
Best regards
[1] GtkWidget* gtk_message_dialog_new (GtkWindow *parent,
GtkDialogFlags flags,
GtkMessageType type,
GtkButtonsType buttons,
const gchar *message_format,
...);
I got a problem with gtk_message_dialog_new function :I pass a gchar* as a parameter to a function for
creating message dialog box and it only writes a part of the whole string.
In main :
...
quick_message (" message bla bla ");
...
Function quick_message :
void quick_message(gchar *message)
{
GtkWidget *dialog ;
dialog=gtk_message_dialog_new(GTK_WINDOW(pWindow),GTK_DIALOG_DESTROY_WITH_PARENT,GTK_MESSAGE_ERROR,GTK_BUTTONS_CLOSE,message);
gtk_dialog_run(GTK_DIALOG(dialog));
gtk_widget_destroy(dialog);
}
When running , I only see the part of string : message b. Could you tell me why ?
Thanks
--
Antonio Gomes
E-mail: antonio gomes indt org br
Embedded Linux Lab - 10LE
INdT - Instituto Nokia de Tecnologia (Manaus/Br)
NOKIA's Technology Institute
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]