Re: string concatanation
- From: Tristan Van Berkom <vantr touchtunes com>
- To: Jacob Perkins <jap1 ionet net>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: string concatanation
- Date: Tue, 20 Aug 2002 13:08:27 -0400
I think you want something like this:
{
gchar *allocated_string = g_strdup_printf("var=%s", ((gint)ENUM));
...
g_free(allocated_string);
}
Cheers.
Jacob Perkins wrote:
This is isn't directly related to gtk, but it's for a gtk project.
I've programmed in java and c++, but not straight c, so I'm wondering
how to concatanate a string.
Here's my situation: I have a set of enums, some of which are
configuration defaults. I'd like to be able to do 'var =
gnome_config_private_get_int("var="+ENUM)', so that the default value of
var is ENUM, but that doesn't seem to work in c. So, how can I specify
this default int value without knowing the specific ENUM int value?
Thanks
--
pub 1024D/57DDD9E3 2002-05-24 Jacob (Direct to Home)
<jap1 rig dyndns ws>
Key fingerprint = 1E02 A5FD 8162 4322 C674 6E67 05EB 30F1 57DD D9E3
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]