Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <campbell@blender.org>2022-03-07 02:51:22 +0300
committerCampbell Barton <campbell@blender.org>2022-03-07 02:51:22 +0300
commitfae45a43fab410eb1e46a9bf4d4b6133b5a7bbdd (patch)
tree6d72b3bab6ea345a41661365a5cc388573f07b23 /source/blender/editors/space_text/text_draw.c
parenta5f972c0180be7a87cfcdd3a02c1363e4b7e8350 (diff)
Cleanup: use doxy-sections for pipeline, text_drag & effects
Also improve on the doc-string for RE_RenderFrame & RE_RenderAnim.
Diffstat (limited to 'source/blender/editors/space_text/text_draw.c')
-rw-r--r--source/blender/editors/space_text/text_draw.c66
1 files changed, 55 insertions, 11 deletions
diff --git a/source/blender/editors/space_text/text_draw.c b/source/blender/editors/space_text/text_draw.c
index 8fefd258f7a..0e29c68cf23 100644
--- a/source/blender/editors/space_text/text_draw.c
+++ b/source/blender/editors/space_text/text_draw.c
@@ -36,7 +36,9 @@
#include "WM_api.h"
#include "WM_types.h"
-/******************** text font drawing ******************/
+/* -------------------------------------------------------------------- */
+/** \name Text Font Drawing
+ * \{ */
typedef struct TextDrawContext {
int font_id;
@@ -141,7 +143,11 @@ static void format_draw_color(const TextDrawContext *tdc, char formatchar)
}
}
-/************************** draw text *****************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Draw Text
+ * \{ */
/**
* Notes on word-wrap
@@ -556,7 +562,11 @@ static void text_draw(const SpaceText *st,
flatten_string_free(&fs);
}
-/************************ cache utilities *****************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Cache Utilities
+ * \{ */
typedef struct DrawCache {
int *line_height;
@@ -766,7 +776,11 @@ void text_free_caches(SpaceText *st)
}
}
-/************************ word-wrap utilities *****************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Word-Wrap Utilities
+ * \{ */
/* cache should be updated in caller */
static int text_get_visible_lines_no(const SpaceText *st, int lineno)
@@ -845,7 +859,11 @@ int text_get_total_lines(SpaceText *st, ARegion *region)
return drawcache->total_lines;
}
-/************************ draw scrollbar *****************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Draw Scroll-Bar
+ * \{ */
static void calc_text_rcts(SpaceText *st, ARegion *region, rcti *scroll, rcti *back)
{
@@ -1006,7 +1024,11 @@ static void draw_textscroll(const SpaceText *st, rcti *scroll, rcti *back)
col);
}
-/*********************** draw documentation *******************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Draw Documentation
+ * \{ */
#if 0
static void draw_documentation(const SpaceText *st, ARegion *region)
@@ -1118,7 +1140,11 @@ static void draw_documentation(const SpaceText *st, ARegion *region)
}
#endif
-/*********************** draw suggestion list *******************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Draw Suggestion List
+ * \{ */
static void draw_suggestion_list(const SpaceText *st, const TextDrawContext *tdc, ARegion *region)
{
@@ -1221,7 +1247,11 @@ static void draw_suggestion_list(const SpaceText *st, const TextDrawContext *tdc
}
}
-/*********************** draw cursor ************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Draw Cursor
+ * \{ */
static void draw_text_decoration(SpaceText *st, ARegion *region)
{
@@ -1383,7 +1413,11 @@ static void draw_text_decoration(SpaceText *st, ARegion *region)
immUnbindProgram();
}
-/******************* draw matching brackets *********************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Draw Matching Brackets
+ * \{ */
static void draw_brackets(const SpaceText *st, const TextDrawContext *tdc, ARegion *region)
{
@@ -1544,7 +1578,11 @@ static void draw_brackets(const SpaceText *st, const TextDrawContext *tdc, ARegi
}
}
-/*********************** main region drawing *************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Main Region Drawing
+ * \{ */
void draw_text_main(SpaceText *st, ARegion *region)
{
@@ -1707,7 +1745,11 @@ void draw_text_main(SpaceText *st, ARegion *region)
text_font_end(&tdc);
}
-/************************** update ***************************/
+/** \} */
+
+/* -------------------------------------------------------------------- */
+/** \name Update & Coordinate Conversion
+ * \{ */
void text_update_character_width(SpaceText *st)
{
@@ -1861,3 +1903,5 @@ error:
r_pixel_co[0] = r_pixel_co[1] = -1;
return false;
}
+
+/** \} */