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:
authorTon Roosendaal <ton@blender.org>2005-11-20 13:04:45 +0300
committerTon Roosendaal <ton@blender.org>2005-11-20 13:04:45 +0300
commit77332fa698fb79cc1d0c1539161e0e85c93b68f7 (patch)
treeb02b7ce3c8245c51ff96eb4f45d4532846e8ff78 /source/blender/python/api2_2x/windowTheme.c
parenta86b0af575c6dad58b8c6ef223d20f5e76a055ed (diff)
Patch by Matt Ebb: upgraded usablitiy of text button.
Textbuttons now allow a selection too (like any textbutton in other UIs). By default, on activating a textbutton, the entire button text is selected when you enter the button. A single arrowkey or LMB click reveils the cursor then. Here's more user notes: LMB click: If inside the button, places the text cursor at the clicked position. If outside the button, confirms/finishes editing LMB drag: Selects the text between the start and end point of the drag. Backspace: Deletes selected text, or backspaces a character Shift Backspace: Deletes all, as before. Delete: Deletes selected text or forward deletes a character Shift LeftArrow: Extends the selection left Shift RightArrow: Extends the selection right LeftArrow: If there's a selection, move the cursor to the left edge of the selection, otherwise move the cursor left a character. RightArrow: If there's a selection, move the cursor to the right edge of the selection, otherwise move the cursor right a character. UpArrow/Home: Move the cursor to the beginning of the line DownArrow/End: Move the cursor to the end of the line Ctrl Left arrow and Ctrl Right arrow to jump between directory separators
Diffstat (limited to 'source/blender/python/api2_2x/windowTheme.c')
-rw-r--r--source/blender/python/api2_2x/windowTheme.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/python/api2_2x/windowTheme.c b/source/blender/python/api2_2x/windowTheme.c
index ca4d1603bb7..d07323d0ccd 100644
--- a/source/blender/python/api2_2x/windowTheme.c
+++ b/source/blender/python/api2_2x/windowTheme.c
@@ -361,6 +361,7 @@ static PyObject *ThemeUI_getAttr( BPy_ThemeUI * self, char *name )
ELSEIF_TUI_RGBA( setting2 )
ELSEIF_TUI_RGBA( num )
ELSEIF_TUI_RGBA( textfield )
+ ELSEIF_TUI_RGBA( textfield_hi )
ELSEIF_TUI_RGBA( popup )
ELSEIF_TUI_RGBA( text )
ELSEIF_TUI_RGBA( text_hi )
@@ -375,7 +376,7 @@ static PyObject *ThemeUI_getAttr( BPy_ThemeUI * self, char *name )
attrib = Py_BuildValue( "[ssssssssssssssssss]", "theme",
"outline", "neutral", "action",
"setting", "setting1", "setting2",
- "num", "textfield", "popup", "text",
+ "num", "textfield", "textfield_hi", "popup", "text",
"text_hi", "menu_back", "menu_item",
"menu_hilite", "menu_text",
"menu_text_hi", "drawType" );
@@ -401,6 +402,7 @@ static int ThemeUI_setAttr( BPy_ThemeUI * self, char *name, PyObject * value )
ELSEIF_TUI_RGBA( setting2 )
ELSEIF_TUI_RGBA( num )
ELSEIF_TUI_RGBA( textfield )
+ ELSEIF_TUI_RGBA( textfield_hi )
ELSEIF_TUI_RGBA( popup )
ELSEIF_TUI_RGBA( text )
ELSEIF_TUI_RGBA( text_hi )