4coder/4ed_text_layout.h

39 lines
608 B
C
Raw Normal View History

/*
* Mr. 4th Dimention - Allen Webster
*
* 31.03.2019
*
* Text layout representation
*
*/
// TOP
#if !defined(FRED_TEXT_LAYOUT_H)
#define FRED_TEXT_LAYOUT_H
union Text_Layout{
Text_Layout *next;
struct{
Arena *arena;
Buffer_ID buffer_id;
Buffer_Point point;
Interval_i64 visible_range;
Interval_i64 visible_line_number_range;
Rect_f32 rect;
FColor *item_colors;
};
};
struct Text_Layout_Container{
Arena *node_arena;
Text_Layout *free_nodes;
Table_u64_u64 table;
Text_Layout_ID id_counter;
};
#endif
// BOTTOM