diff --git a/VERSION b/VERSION index 05c7ae5e..6f0f9c09 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.0.8 (2012-09-09 14:58:46) stable +Version 2.0.8 (2012-09-09 16:57:02) stable diff --git a/applications/admin/languages/default.py b/applications/admin/languages/default.py index 51e8f453..2e65d5d2 100644 --- a/applications/admin/languages/default.py +++ b/applications/admin/languages/default.py @@ -152,6 +152,7 @@ 'to previous version.': 'to previous version.', 'To create a plugin, name a file/folder plugin_[name]': 'To create a plugin, name a file/folder plugin_[name]', 'toggle breakpoint': 'toggle breakpoint', +'Toggle Fullscreen': 'Toggle Fullscreen', 'Traceback': 'Traceback', 'Translation strings for the application': 'Translation strings for the application', 'try view': 'try view', diff --git a/applications/admin/models/0.py b/applications/admin/models/0.py index df0e2a29..961ada45 100644 --- a/applications/admin/models/0.py +++ b/applications/admin/models/0.py @@ -18,10 +18,11 @@ TEXT_EDITOR_THEME = ( "solarized_dark", "solarized_light", "textmate", "tomorrow", "tomorrow_night", "tomorrow_night_blue", "tomorrow_night_bright", "tomorrow_night_eighties", "twilight", "vibrant_ink")[0] -## Editor Keyboard bindings (only for ace) -TEXT_EDITOR_KEYBINDING = '' #'emacs' or 'vi' - -### edit_area + +## Editor Keyboard bindings (only for ace and codemirror) +TEXT_EDITOR_KEYBINDING = '' # 'emacs' or 'vi' + +### edit_area only # The default font size, measured in 'points'. The value must be an integer > 0 FONT_SIZE = 10 diff --git a/applications/admin/static/codemirror/theme/web2py.css b/applications/admin/static/codemirror/theme/web2py.css index 88acc257..f3272aec 100644 --- a/applications/admin/static/codemirror/theme/web2py.css +++ b/applications/admin/static/codemirror/theme/web2py.css @@ -29,4 +29,17 @@ .cm-s-web2py { line-height: 1.40em; font-family: Monaco, Menlo,"Andale Mono","lucida console","Courier New",monospace !important; -} \ No newline at end of file +} + +/* Fullscreen mode and active line highlight */ + +.cm-s-web2py .CodeMirror-fullscreen { + display: block; + position: absolute; + top: 0; + left: 0; + width: 100%; + z-index: 9999; +} + +.cm-s-web2py .activeline {background: #e8f2ff !important;} \ No newline at end of file diff --git a/applications/admin/views/default/edit.html b/applications/admin/views/default/edit.html index 38a5bc3b..567b5235 100644 --- a/applications/admin/views/default/edit.html +++ b/applications/admin/views/default/edit.html @@ -12,7 +12,8 @@ - +{{if TEXT_EDITOR_KEYBINDING == 'emacs':}}{{pass}} +{{if TEXT_EDITOR_KEYBINDING == 'vi':}}{{pass}} @@ -131,6 +132,30 @@ jQuery(document).ready(function(){ {{cm_mode = {'html':'htmlmixed'}.get(filetype,filetype)}} {{elif TEXT_EDITOR == 'ace':}} @@ -193,6 +226,14 @@ window.onload = function() { {{=shortcut('Ctrl+Shift+↑', T('Go to Matching Pair'))}} +{{elif TEXT_EDITOR == 'codemirror':}} +
+

{{=T("Key bindings")}}

+ +
{{else:}}

{{=T("Key bindings")}}

@@ -201,4 +242,3 @@ window.onload = function() {
{{pass}} -