- make sure we have a name before trying to look it up

- strip off an + or - in _format_fill so we don't end up with things like
  +font=fonts/Vera which then won't match when we try to recognize it as a
  keyword


SVN revision: 17580
This commit is contained in:
Dan Sinclair 2005-10-15 22:02:59 +00:00 committed by Dan Sinclair
parent 347c26ce53
commit ef2fcdc4c1
2 changed files with 7 additions and 1 deletions

View File

@ -159,6 +159,8 @@ evas_font_load(Evas *evas, const char *name, const char *source, int size)
Evas_List *fonts, *l;
Fndat *fd;
if (!name) return NULL;
for (l = fonts_cache; l; l = l->next)
{
fd = l->data;

View File

@ -747,7 +747,7 @@ _format_color_parse(char *str, unsigned char *r, unsigned char *g, unsigned char
slen = strlen(str);
*r = *g = *b = *a = 0;
if (slen == 7) /* #RRGGBB */
{
*r = (_hex_string_get(str[1]) << 4) | (_hex_string_get(str[2]));
@ -1128,6 +1128,10 @@ _format_fill(Evas_Object *obj, Evas_Object_Textblock_Format *fmt, char *str)
char *item;
s = str;
/* get rid of anything +'s or -'s off the start of the string */
while ((*s == ' ') || (*s == '+') || (*s == '-')) s++;
while ((item = _format_parse(&s)))
{
if (_format_is_param(item))