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:
authorIan Thompson <quornian@googlemail.com>2008-08-05 03:01:47 +0400
committerIan Thompson <quornian@googlemail.com>2008-08-05 03:01:47 +0400
commit53e535dfcf9637e3aa3327dd3bf2793a67756868 (patch)
treeedc307efe53008580feeffab327056779b8ab6b0 /source/blender/blenkernel/BKE_text.h
parented5002458b810974277b7a6bd5d9c3c29d052d53 (diff)
Text Markers: multiple, coloured selections within a Text object with group relationships. They allow portions of text to be edited as one and enable quick jumping between and editing of different areas.
Flags control the behaviour and grouping of markers. At present, Ctrl+M places a marker with TMARK_EDITALL set for testing purposes. I have also split the text area event handler into separate methods for marker handling and the existing text tools. This makes the events system much easier to follow as it was getting a little hairy.
Diffstat (limited to 'source/blender/blenkernel/BKE_text.h')
-rw-r--r--source/blender/blenkernel/BKE_text.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_text.h b/source/blender/blenkernel/BKE_text.h
index abdf32c8ea5..de54b6413ae 100644
--- a/source/blender/blenkernel/BKE_text.h
+++ b/source/blender/blenkernel/BKE_text.h
@@ -100,6 +100,15 @@ int setcurr_tab (struct Text *text);
void convert_tabs (struct SpaceText *st, int tab);
void txt_copy_clipboard (struct Text *text);
void txt_paste_clipboard (struct Text *text);
+
+void txt_add_marker (struct Text *text, struct TextLine *line, int start, int end, char clr[4], int flags);
+void txt_clear_marker_region (struct Text *text, struct TextLine *line, int start, int end, int flags);
+void txt_clear_markers (struct Text *text, int flags);
+struct TextMarker *txt_find_marker (struct Text *text, struct TextLine *line, int curs, int flags);
+struct TextMarker *txt_find_marker_region (struct Text *text, struct TextLine *line, int start, int end, int flags);
+struct TextMarker *txt_prev_marker (struct Text *text, struct TextMarker *marker);
+struct TextMarker *txt_next_marker (struct Text *text, struct TextMarker *marker);
+
/* Undo opcodes */
/* Simple main cursor movement */
@@ -146,6 +155,10 @@ void txt_paste_clipboard (struct Text *text);
#define TXT_FIND_ALLTEXTS 0x02
#define TXT_FIND_WRAP 0x04
+/* Marker flags */
+#define TMARK_TEMP 0x01 /* Remove on non-editing events, don't save */
+#define TMARK_EDITALL 0x02 /* Edit all markers of the same group as one */
+
#ifdef __cplusplus
}
#endif