20 #ifndef FASTUIDRAW_FONT_DATABASE_HPP 21 #define FASTUIDRAW_FONT_DATABASE_HPP 236 uint32_t selection_strategy = 0u);
249 uint32_t selection_strategy = 0u);
264 uint32_t selection_strategy = 0u);
288 template<
typename input_iterator,
289 typename output_iterator>
292 input_iterator character_codes_begin,
293 input_iterator character_codes_end,
294 output_iterator output_begin,
295 uint32_t selection_strategy = 0u);
311 template<
typename input_iterator,
312 typename output_iterator>
315 input_iterator character_codes_begin,
316 input_iterator character_codes_end,
317 output_iterator output_begin,
318 uint32_t selection_strategy = 0u);
331 template<
typename input_iterator,
332 typename output_iterator>
335 input_iterator character_codes_begin,
336 input_iterator character_codes_end,
337 output_iterator output_begin);
347 fetch_glyph_no_lock(
FontGroup group, uint32_t character_code,
348 uint32_t selection_strategy);
351 fetch_glyph_no_lock(
const FontBase *h,
352 uint32_t character_code,
353 uint32_t selection_strategy);
356 fetch_glyph_no_merging_no_lock(
const FontBase *h, uint32_t character_code);
361 template<
typename input_iterator,
362 typename output_iterator>
366 input_iterator character_codes_begin,
367 input_iterator character_codes_end,
368 output_iterator output_begin,
369 uint32_t selection_strategy)
372 for(;character_codes_begin != character_codes_end; ++character_codes_begin, ++output_begin)
375 v =
static_cast<uint32_t
>(*character_codes_begin);
376 *output_begin = fetch_glyph_no_lock(group, v, selection_strategy);
381 template<
typename input_iterator,
382 typename output_iterator>
386 input_iterator character_codes_begin,
387 input_iterator character_codes_end,
388 output_iterator output_begin,
389 uint32_t selection_strategy)
392 for(;character_codes_begin != character_codes_end; ++character_codes_begin, ++output_begin)
395 v =
static_cast<uint32_t
>(*character_codes_begin);
396 *output_begin = fetch_glyph_no_lock(h, v, selection_strategy);
401 template<
typename input_iterator,
402 typename output_iterator>
406 input_iterator character_codes_begin,
407 input_iterator character_codes_end,
408 output_iterator output_begin)
411 for(;character_codes_begin != character_codes_end; ++character_codes_begin, ++output_begin)
414 v =
static_cast<uint32_t
>(*character_codes_begin);
415 *output_begin = fetch_glyph_no_merging_no_lock(h, v);
all classes and functions of FastUIDraw are in the namespace fastuidraw.
void create_glyph_sequence_no_merging(const FontBase *h, input_iterator character_codes_begin, input_iterator character_codes_end, output_iterator output_begin)
virtual reference_counted_ptr< const FontBase > generate_font(void) const =0
FontBase provides an interface for a font to generate glyph rendering data.
A wrapper over a pointer to implement reference counting.
reference_counted_ptr< const FontBase > fetch_font(c_string source_label)
return_code
Enumeration for simple return codes for functions for success or failure.
A FontGeneratorBase is a means to create a font. Adding a font via a FontGenerator allows one to avoi...
Represents defining properties of a font used by FontDatabase to perform font merging.
reference_counted_ptr< const FontBase > fetch_or_generate_font(const reference_counted_ptr< const FontGeneratorBase > &h)
enum return_code add_font(const reference_counted_ptr< const FontBase > &h)
virtual const FontProperties & font_properties(void) const =0
A FontGroup represents a group of fonts which is selected from a FontProperties value. The accessors for FontGroup are methods of FontDatabase::parent_group(FontGroup), FontDatabase::fetch_font(FontGroup, unsigned int) and FontDatabase::number_fonts(FontGroup).
FontGroup fetch_group(const FontProperties &props, uint32_t selection_strategy)
void create_glyph_sequence(FontGroup group, input_iterator character_codes_begin, input_iterator character_codes_end, output_iterator output_begin, uint32_t selection_strategy=0u)
FontGroup parent_group(FontGroup G)
unsigned int number_fonts(FontGroup G)
FontGroup root_group(void)
Defines default reference counting base classes.
GlyphSource fetch_glyph_no_merging(const FontBase *h, uint32_t character_code)
const char * c_string
Conveniant typedef for C-style strings.
enum return_code add_font_generator(const reference_counted_ptr< const FontGeneratorBase > &h)
GlyphSource fetch_glyph(const FontProperties &props, uint32_t character_code, uint32_t selection_strategy=0u)
A FontDatabase performs the act of font selection and glyph selection. It uses the values of FontProp...