got rid of data subdirectory in pkgdatadir. fixed a bunch of warnings

SVN revision: 13483
This commit is contained in:
tsauerbeck 2005-02-23 20:32:07 +00:00 committed by tsauerbeck
parent 9bd9e51230
commit f8b835ea0c
6 changed files with 23 additions and 18 deletions

View File

@ -4,7 +4,7 @@ FILES = Vera.ttf VeraBI.ttf VeraBd.ttf VeraIt.ttf VeraMoBI.ttf VeraMoBd.ttf \
panel_shadow.png panel_top.png \ panel_shadow.png panel_top.png \
t1.png t2.png test_pattern.png t1.png t2.png test_pattern.png
miscdir = $(pkgdatadir)/data miscdir = $(pkgdatadir)
misc_DATA = $(FILES) misc_DATA = $(FILES)
EXTRA_DIST = $(FILES) EXTRA_DIST = $(FILES)

View File

@ -110,7 +110,7 @@ int main( int argc, char *argv[] )
desc.flags = DFDESC_HEIGHT; desc.flags = DFDESC_HEIGHT;
desc.height = layer_config.width/50; desc.height = layer_config.width/50;
DFBCHECK(dfb->CreateFont( dfb, PACKAGE_DATA_DIR"/data/grunge.ttf", &desc, &font )); DFBCHECK(dfb->CreateFont( dfb, PACKAGE_DATA_DIR"/grunge.ttf", &desc, &font ));
font->GetHeight( font, &fontheight ); font->GetHeight( font, &fontheight );
} }
@ -118,7 +118,7 @@ int main( int argc, char *argv[] )
DFBSurfaceDescription desc; DFBSurfaceDescription desc;
DFBCHECK(dfb->CreateImageProvider( dfb, DFBCHECK(dfb->CreateImageProvider( dfb,
PACKAGE_DATA_DIR"/data/bg.png", PACKAGE_DATA_DIR"/bg.png",
&provider )); &provider ));
desc.flags = DSDESC_WIDTH | DSDESC_HEIGHT; desc.flags = DSDESC_WIDTH | DSDESC_HEIGHT;

View File

@ -10,13 +10,13 @@
#ifndef _WIN32_WCE #ifndef _WIN32_WCE
# define IM PACKAGE_DATA_DIR"/data/" # define IM PACKAGE_DATA_DIR"/"
# define FN PACKAGE_DATA_DIR"/data/" # define FN PACKAGE_DATA_DIR"/"
#else #else
# define IM PACKAGE_DATA_DIR"\\data\\" # define IM PACKAGE_DATA_DIR"\\"
# define FN PACKAGE_DATA_DIR"\\data\\" # define FN PACKAGE_DATA_DIR"\\"
wchar_t buf[1024]; wchar_t buf[1024];
#endif #endif

View File

@ -317,6 +317,8 @@ evas_object_textblock_layout_format_apply(Layout *layout, Layout_Command *comman
if (data[0] == '#') if (data[0] == '#')
{ {
int r, g, b, a; int r, g, b, a;
r = g = b = a = 0;
if (strlen(data) == 7) /* #RRGGBB */ if (strlen(data) == 7) /* #RRGGBB */
{ {
@ -708,7 +710,7 @@ evas_object_textblock_format_parse(const char *format)
int inquote = 0, inescape = 0; int inquote = 0, inescape = 0;
Evas_List *params = NULL; Evas_List *params = NULL;
if (!format) return; if (!format) return NULL;
p = format - 1; p = format - 1;
do do
{ {
@ -1240,12 +1242,12 @@ evas_object_textblock_layout_internal(Evas_Object *obj, int w, int h, int *forma
} }
else if (node->text) else if (node->text)
{ {
int inset = 0, hadvance = 0, vadvance = 0; int inset = 0, hadvance = 0;
int ascent = 0, descent = 0, tw = 0, th = 0; int ascent = 0, descent = 0, tw = 0, th = 0;
int chrpos = -1, nchrpos = -1, x, y, cx, cy, cw, ch; int chrpos = -1, nchrpos = -1, cx, cy, cw, ch;
void *font = NULL; void *font = NULL;
char *text; char *text;
int adj, lastnode; int adj;
int srcpos = 0; int srcpos = 0;
text = strdup(node->text); text = strdup(node->text);
@ -1523,7 +1525,7 @@ evas_object_textblock_layout_internal(Evas_Object *obj, int w, int h, int *forma
} }
} }
} }
breakout: /*breakout:*/
evas_object_textblock_layout_clear(obj, &layout); evas_object_textblock_layout_clear(obj, &layout);
*line_count = last_line + 1; *line_count = last_line + 1;
fw += pad_r; fw += pad_r;
@ -1576,7 +1578,6 @@ static void
evas_object_textblock_native_calc(Evas_Object *obj) evas_object_textblock_native_calc(Evas_Object *obj)
{ {
Evas_Object_Textblock *o; Evas_Object_Textblock *o;
Layout layout;
int fw = 0, fh = 0, lines = 0; int fw = 0, fh = 0, lines = 0;
Layout_Node *lnodes; Layout_Node *lnodes;
@ -1644,6 +1645,8 @@ evas_object_textblock_layout_node_pos_get(Evas_Object *obj, int pos, int *pstart
return NULL; return NULL;
} }
/* unused */
#if 0
static Layout_Node * static Layout_Node *
evas_object_textblock_layout_node_line_get(Evas_Object *obj, int line) evas_object_textblock_layout_node_line_get(Evas_Object *obj, int line)
{ {
@ -1667,6 +1670,7 @@ evas_object_textblock_layout_node_line_get(Evas_Object *obj, int line)
} }
return NULL; return NULL;
} }
#endif
/* private methods for textblock objects */ /* private methods for textblock objects */
static void evas_object_textblock_init(Evas_Object *obj); static void evas_object_textblock_init(Evas_Object *obj);
@ -2083,7 +2087,6 @@ evas_object_textblock_char_coords_get(Evas_Object *obj, Evas_Coord x, Evas_Coord
{ {
Evas_Object_Textblock *o; Evas_Object_Textblock *o;
Layout_Node *lnode; Layout_Node *lnode;
int ps;
Evas_Object_List *l; Evas_Object_List *l;
MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ); MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ);
@ -2853,7 +2856,7 @@ evas_object_textblock_current_format_get(Evas_Object *obj)
#define CHECK_COL(str, col) \ #define CHECK_COL(str, col) \
if (lnode->layout.col.a > 0) \ if (lnode->layout.col.a > 0) \
{ \ { \
snprintf(tbuf, sizeof(tbuf), "#02x02x02x02x", lnode->layout.col.r, lnode->layout.col.g, lnode->layout.col.b, lnode->layout.col.a); \ snprintf(tbuf, sizeof(tbuf), "#%02x%02x%02x%02x", lnode->layout.col.r, lnode->layout.col.g, lnode->layout.col.b, lnode->layout.col.a); \
sz += strlen(str"=") + strlen(tbuf) + 1; \ sz += strlen(str"=") + strlen(tbuf) + 1; \
} }
/* FIXME: we dont handle any strings with a space in them */ /* FIXME: we dont handle any strings with a space in them */
@ -2898,7 +2901,7 @@ evas_object_textblock_current_format_get(Evas_Object *obj)
{ \ { \
if (buf[0] != 0) strcat(buf, " "); \ if (buf[0] != 0) strcat(buf, " "); \
strcat(buf, str"="); \ strcat(buf, str"="); \
snprintf(tbuf, sizeof(tbuf), "#02x02x02x02x", lnode->layout.col.r, lnode->layout.col.g, lnode->layout.col.b, lnode->layout.col.a); \ snprintf(tbuf, sizeof(tbuf), "#%02x%02x%02x%02x", lnode->layout.col.r, lnode->layout.col.g, lnode->layout.col.b, lnode->layout.col.a); \
strcat(buf, tbuf); \ strcat(buf, tbuf); \
} }
@ -3109,7 +3112,7 @@ evas_object_textblock_render(Evas_Object *obj, void *output, void *context, void
{ {
Evas_Object_Textblock *o; Evas_Object_Textblock *o;
Evas_Object_List *l; Evas_Object_List *l;
int pbackx; int pbackx = 0;
int i, j; int i, j;
const char vals[5][5] = const char vals[5][5] =
{ {

View File

@ -102,7 +102,7 @@ evas_common_font_utf8_get_next(unsigned char *buf, int *iindex)
* *
* Returns 0 to indicate an error (e.g. invalid UTF8) * Returns 0 to indicate an error (e.g. invalid UTF8)
*/ */
int index = *iindex, r, istart = *iindex; int index = *iindex, r;
unsigned char d, d2, d3, d4; unsigned char d, d2, d3, d4;
d = buf[index++]; d = buf[index++];

View File

@ -2,7 +2,9 @@
#define EVAS_PRIVATE_H #define EVAS_PRIVATE_H
#endif #endif
#ifndef _GNU_SOURCE
#define _GNU_SOURCE #define _GNU_SOURCE
#endif
/* complain when peole pass in wrong object types etc. */ /* complain when peole pass in wrong object types etc. */
#define MAGIC_DEBUG #define MAGIC_DEBUG