Enlightenment CVS committal Author : technikolor Project : web Module : e
Dir : web/e/data Modified Files: edb.html eet.html ewl.html Log Message: Fixes and updates. =================================================================== RCS file: /cvsroot/enlightenment/web/e/data/edb.html,v retrieving revision 1.8 retrieving revision 1.9 diff -u -3 -r1.8 -r1.9 --- edb.html 3 Feb 2004 10:48:53 -0000 1.8 +++ edb.html 6 Feb 2004 00:50:15 -0000 1.9 @@ -37,8 +37,7 @@ <div class="code"> <pre> -#include <Edb.h> -#include <stdio.h> +#include <Edb.h> int main() { =================================================================== RCS file: /cvsroot/enlightenment/web/e/data/eet.html,v retrieving revision 1.3 retrieving revision 1.4 diff -u -3 -r1.3 -r1.4 --- eet.html 2 Feb 2004 07:15:29 -0000 1.3 +++ eet.html 6 Feb 2004 00:50:15 -0000 1.4 @@ -8,6 +8,59 @@ <p>It also can encode and decode data structures in memory, as well as image data for saving to Eet files or sending across the network to other machines, or just writing to arbitary files on the system. All data is encoded in a platform independant way and can be written and read by any architecture.</p> +<p>Code Example:</p> + +<div class="code"> + +<pre> +#include <Eet.h> + +int main(int argc, char **argv) { + + Eet_File *ef; + char buf[1024], *ret, **list; + int size, num, i; + + strcpy(buf, "Here is a string of data to save!"); + + ef = eet_open("/tmp/my_file.eet, EET_FILE_MODE_WRITE); + if (!ef) return -1; + if (!eet_write(ef, "/key/to_store/at", buf, 1024, 1)) + fprintf("Error writing data!\n"); + eet_close(ef); + + ef = eet_open("/tmp/my_file.eet, EET_FILE_MODE_READ); + if (!ef) return -1; + list = eet_list(ef, "*", &num); + if (list) + { + for (i = 0; i < num; i++) + printf("Key stored: %s\n", list[i]); + free(list); + } + ret = eet_read(ef, "/key/to_store/at", &size); + if (ret) + { + printf("Data read (%i bytes):\n%s\n", size, ret); + free(ret); + } + eet_close(ef); + + return 0; +} +</pre> +</div> + +<p>This code is compiled in the following manner: gcc `eet-config --libs --cflags` eet_example.c -o eet_example</p> + +<p> +EET also provides the CLI "eet" tool which allows for easy EET +management and creation. Supported operations with the tool include +listing the contents of an eet file, and both packing and unpacking +of an eet file, as well as some compression control over files to +be packed. +</p> + <p class="manager">EET's project manager is <a href="team.html" class="lite">Carsten "Rasterman" Haitzler</a>.</p> =================================================================== RCS file: /cvsroot/enlightenment/web/e/data/ewl.html,v retrieving revision 1.11 retrieving revision 1.12 diff -u -3 -r1.11 -r1.12 --- ewl.html 2 Feb 2004 07:15:29 -0000 1.11 +++ ewl.html 6 Feb 2004 00:50:15 -0000 1.12 @@ -30,7 +30,7 @@ main_win = ewl_window_new(); ewl_window_set_title(main_win, "The Cuddletech Test App: EWL"); - ewl_window_resize(main_win, 297, 68); + ewl_object_resize(EWL_OBJECT(main_win), 297, 68); ewl_widget_show(main_win); /* Setup and show a button */ ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ enlightenment-cvs mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs