comparison include/mb_shapes.h @ 462:af4b506ad56f

Add backend layer to seperate the backend with the MBAF. Currently, X is the only backend. If we have more than one backend, we need to modify the Makefile to sleect the backend or implement a backend selection mechanism in the runtime.
author wycc@122-116-38-188.HINET-IP.hinet.net
date Wed, 28 Oct 2009 02:39:02 +0800
parents bb4f651090bf
children 4254eaa699d0
comparison
equal deleted inserted replaced
461:61a0bceb369d 462:af4b506ad56f
174 */ 174 */
175 static inline void mb_textstyle_init(mb_textstyle_t *style) 175 static inline void mb_textstyle_init(mb_textstyle_t *style)
176 { 176 {
177 style->property = 0; 177 style->property = 0;
178 } 178 }
179 /*! \brief Get the dimension of the text
180 */
181 extern void sh_text_get_size(shape_t *sh, int *w, int *h);
179 extern void mb_textstyle_set_font(mb_textstyle_t *style, char *font); 182 extern void mb_textstyle_set_font(mb_textstyle_t *style, char *font);
180 static inline char *mb_textstyle_get_font(mb_textstyle_t *style) 183 static inline char *mb_textstyle_get_font(mb_textstyle_t *style)
181 { 184 {
182 if (style->property & TEXTSTYLE_FONT) 185 if (style->property & TEXTSTYLE_FONT)
183 return style->font; 186 return style->font;
227 230
228 extern void mb_text_set_style(mb_text_t *text, int begin,int end,mb_textstyle_t *style); 231 extern void mb_text_set_style(mb_text_t *text, int begin,int end,mb_textstyle_t *style);
229 extern void mb_text_get_style(mb_text_t *text, int n,mb_textstyle_t *style); 232 extern void mb_text_get_style(mb_text_t *text, int n,mb_textstyle_t *style);
230 extern void mb_text_set_text(mb_text_t *text, char *string,int begin,int end); 233 extern void mb_text_set_text(mb_text_t *text, char *string,int begin,int end);
231 extern void mb_text_get_text(mb_text_t *text, int begin,int end, char *string); 234 extern void mb_text_get_text(mb_text_t *text, int begin,int end, char *string);
232
233 235
234 /* @} */ 236 /* @} */
235 237
236 /*! \defgroup shape_rect Shape of Rectangle 238 /*! \defgroup shape_rect Shape of Rectangle
237 * @{ 239 * @{