src/liqcell_prop.c File Reference

Manage a liqcell's .tag. More...

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <errno.h>
#include <dirent.h>
#include "liqcell.h"

Functions

int liqcell_propremoves (liqcell *self, char *name)
int liqcell_propremovei (liqcell *self, char *name)
int liqcell_propgeti (liqcell *self, char *name, int valueifnotfound)
int liqcell_propseti (liqcell *self, char *name, int value)
char * liqcell_propgets (liqcell *self, char *name, char *valueifnotfound)
char * liqcell_propsets (liqcell *self, char *name, char *value)
char * liqcell_propsets_vprintf (liqcell *self, char *name, char *format, va_list arg)
char * liqcell_propsets_printf (liqcell *self, char *name, char *format,...)


Detailed Description

Manage a liqcell's .tag.

Author:
Gary Birkett Copyright (C) 2008 Gary Birkett

LICENSE

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA


Function Documentation

int liqcell_propgeti ( liqcell *  self,
char *  name,
int  valueifnotfound 
)

Get an integer prop

Parameters:
self The liqcell to get the prop from
name The name of the prop to get
valueifnotfound Return this value if prop not found
Returns:
int The integer prop or valueifnotfound

char* liqcell_propgets ( liqcell *  self,
char *  name,
char *  valueifnotfound 
)

Get a string prop

Parameters:
self The liqcell to get the prop from
name The name of the prop to get
valueifnotfound Return this value if prop not found
Returns:
char* The string prop or valueifnotfound

Referenced by liqcell_sketch_autoload().

int liqcell_propremovei ( liqcell *  self,
char *  name 
)

Remove an integer prop

Parameters:
self The liqcell to remove the prop from
name The prop to remove
Returns:
int Success or Failure

int liqcell_propremoves ( liqcell *  self,
char *  name 
)

Remove a string prop

Parameters:
self The liqcell to remove the prop from
name The prop to remove
Returns:
int Success or Failure

int liqcell_propseti ( liqcell *  self,
char *  name,
int  value 
)

Create a child liqcell for the parent (self) with .tag defined as the integer value provided. This uses liqcell nameclass "prop.i".

Parameters:
self The parent liqcell
name The name of the prop
value The value to set the child's .tag to
Returns:
int value

Referenced by liqcell_child_arrange_makegrid_internal(), textbox_create(), and uititlebar_create().

char* liqcell_propsets ( liqcell *  self,
char *  name,
char *  value 
)

Set a string prop

Parameters:
self The liqcell to set the prop for
name The name of the prop to set
value The value to set to prop "name"
Returns:
char* The value provided

Referenced by liqcell_propsets_vprintf(), textbox_create(), uiinfobar_create(), uinumberbox_create(), uipicturebox_create(), uitextbox_create(), and uititlebar_create().

char* liqcell_propsets_printf ( liqcell *  self,
char *  name,
char *  format,
  ... 
)

Set formatted string prop and

Parameters:
self The liqcell to set the prop for
name The name of the prop to set
format Format of the string prop
... va_list args
Returns:
char* The formatted string prop

References liqcell_propsets_vprintf().

char* liqcell_propsets_vprintf ( liqcell *  self,
char *  name,
char *  format,
va_list  arg 
)

Helper function for liqcell_propsets_printf

References liqcell_propsets().

Referenced by liqcell_propsets_printf().


Generated on Wed Jul 22 13:20:12 2009 for libliqbase by  doxygen 1.5.9