From 0613034688a5fa5e05b994278f3093448d10f67f Mon Sep 17 00:00:00 2001 From: benweet Date: Sun, 15 Sep 2013 18:10:14 +0100 Subject: [PATCH] Switch to ACE editor --- res/config.js | 2 +- res/core.js | 2 +- res/styles/main.less | 2 +- res/themes/night.less | 11 ++++++++--- 4 files changed, 11 insertions(+), 6 deletions(-) diff --git a/res/config.js b/res/config.js index e25f3ec4..7250a7a7 100644 --- a/res/config.js +++ b/res/config.js @@ -16,7 +16,7 @@ var BITLY_ACCESS_TOKEN = "317e033bfd48cf31155a68a536b1860013b09c4c"; var DEFAULT_FILE_TITLE = "Title"; var DEFAULT_FOLDER_NAME = "New folder"; var GDRIVE_DEFAULT_FILE_TITLE = "New Markdown document"; -var EDITOR_DEFAULT_PADDING = 12; +var EDITOR_DEFAULT_PADDING = 15; var CHECK_ONLINE_PERIOD = 120000; var AJAX_TIMEOUT = 30000; var ASYNC_TASK_DEFAULT_TIMEOUT = 60000; diff --git a/res/core.js b/res/core.js index 0d36f199..9cae9020 100644 --- a/res/core.js +++ b/res/core.js @@ -207,7 +207,7 @@ define([ } aceEditor = ace.edit("wmd-input"); aceEditor.renderer.setShowGutter(false); - aceEditor.renderer.setShowPrintMargin(false); + //aceEditor.renderer.setShowPrintMargin(false); aceEditor.renderer.setPrintMarginColumn(false); aceEditor.renderer.setPadding(EDITOR_DEFAULT_PADDING); aceEditor.session.setUseWrapMode(true); diff --git a/res/styles/main.less b/res/styles/main.less index d4c81e11..107da986 100644 --- a/res/styles/main.less +++ b/res/styles/main.less @@ -944,7 +944,7 @@ ul,ol { } .ace_print-margin { - background-color: @primary-bg-lighter; + background-color: fade(@primary-bg-lighter, 50%); } .ace_markup.ace_heading { diff --git a/res/themes/night.less b/res/themes/night.less index 288b29ec..08c4a1fe 100644 --- a/res/themes/night.less +++ b/res/themes/night.less @@ -45,7 +45,12 @@ .img-retina('../img/loader-night.gif', '../img/loader-night2x.gif', 50px, 17px); } -.ace-tm .ace_cursor { - border-left-color: #fff; -} +.ace-tm { + .ace_cursor { + border-left-color: #fff; + } + .ace_print-margin { + background-color: @primary-bg-lighter; + } +}