1549 Commits

Author SHA1 Message Date
Le Tan
c7259c307e add delete note button in tool bar
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-15 22:17:15 +08:00
Le Tan
a6c2416cc8 add note info button in tool bar
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-15 14:48:16 +08:00
Le Tan
62c75427e7 complete rename logics
1. Handle directory rename correctly;
2. Handle file rename correctly;

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-14 22:40:38 +08:00
Le Tan
5e97ca8060 display current file in window title
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-13 16:15:13 +08:00
Le Tan
dcc7e6a0f7 add vnote.qss for style sheet
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-13 08:05:43 +08:00
Le Tan
fe4a2cdcc8 move peg-markdown-highlight as a lib to avoid warnings
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-11 23:09:42 +08:00
Le Tan
5f8073eeec modify code style in default markdown.css
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-11 22:46:24 +08:00
Le Tan
d77b333343 fix outline bug in edit mode
Avoid taking the # in code block as a header by mistake.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-11 22:08:03 +08:00
Le Tan
201d14116f set app icon for windows
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-11 22:07:15 +08:00
Le Tan
550a3707a5 remove buttons in directory tree
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-10 23:02:09 +08:00
Le Tan
3d6778e1fe fix highlightjs bug with code block
We should distinguish <code> and <pre><code>.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-10 22:39:57 +08:00
Le Tan
dce6396874 remove buttons in VFileList
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-10 22:31:04 +08:00
Le Tan
99353c37bd fix highlihgtjs highlight using Hoedown
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-10 22:01:51 +08:00
Le Tan
1a77056f4a support outline in edit mode
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-10 21:59:37 +08:00
Le Tan
8a214831e3 fix outline navigation bug using Hoedown
Use a fixed base html and update the body using VDocument.html like
Marked does.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-09 21:43:11 +08:00
Le Tan
454072c9ba update current header in outline correctly
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-09 21:41:57 +08:00
Le Tan
849fdf05bd support synchronization between preview page and outline
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-08 23:21:22 +08:00
Le Tan
fe3d16ba3b change Marked's renderer to be identical with Hoedown
Change the style of the header to align with what Hoedown does (use id
as anchor).

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-08 22:08:18 +08:00
Le Tan
d1a3a9c386 support navigating by outline using Hoedown
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-07 22:40:43 +08:00
Le Tan
ae0130aa26 fix html toc parsing
Handle wrong notation such as header 3 under header 1 directly.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-07 22:12:16 +08:00
Le Tan
ab91f755c0 add dock widget to display outline
1. Support displaying outline of Markdown in read mode;
2. Support navigating by outline using Marked;

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-07 21:53:33 +08:00
Le Tan
db0797a538 add left corner widget to VEditWindow to display a list of tab
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-06 15:36:30 +08:00
Le Tan
29a41e8285 change VEditor to VEditTab
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-06 14:12:09 +08:00
Le Tan
d8aa464653 add removeSplitAct to context menu of VEditWindow
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-06 13:34:00 +08:00
Le Tan
915c25e1a5 support spliting edit windows
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-06 13:03:16 +08:00
Le Tan
1bc95bcea0 disable newNoteAct if FileList's directory is not set
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-03 21:39:46 +08:00
Le Tan
a69bd43e5a disable editNoteAct instead of set it invisible
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-03 21:31:38 +08:00
Le Tan
a6647bb113 add toolbuttons for changing view
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-03 21:21:02 +08:00
Le Tan
de44760cf3 use virtual destructor in VEditOperations
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-02 22:16:56 +08:00
Le Tan
2bbffb9002 change icons from png to svg
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-02 22:09:31 +08:00
Le Tan
435d47bb74 support downloading image from URL
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-11-01 22:58:19 +08:00
Le Tan
047c26b598 support pasting image in markdown
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-31 22:43:59 +08:00
Le Tan
ec7850685e update a more friendly toolbar
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-30 22:43:30 +08:00
Le Tan
a6774fdf49 handle nokebook renaming correctly
We do not allow modifying the path of an existing notebook.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-30 18:02:41 +08:00
Le Tan
49020d9fb2 do not inherit QListWidget in VFileList
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-30 17:44:21 +08:00
Le Tan
35f8d7350c VEdit set the modified to false when saving file
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-30 17:19:02 +08:00
Le Tan
53bce98db6 support changing rendering background color
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-28 21:06:26 +08:00
Le Tan
0c3fc3b006 support changing background color of editor
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-27 22:41:41 +08:00
Le Tan
8960358feb expand tab to spaces
Add configuration "tab_stop_width" and "is_expand_tab". Expand tab to
tab_stop_width spaces if is_expand_tab is true.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-27 10:23:38 +08:00
Le Tan
2bd3194af6 clear the [notebooks] section first before storing new one
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-26 21:50:38 +08:00
Le Tan
1f80fb8583 add VFileListPanel as a wrapper of VFileList
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-26 18:09:07 +08:00
Le Tan
5409ce9769 refactor directory and file related logics
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-25 22:25:34 +08:00
Le Tan
51d0eedcb2 fix HGMarkdownHighlighter regular expression
Change the default markdown.css.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-25 10:21:31 +08:00
Le Tan
6a3fdf63a2 implement dirInfoBtn logics
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-23 22:11:17 +08:00
Le Tan
30766f5738 remove "name" parameter in directory config file
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-23 19:49:21 +08:00
Le Tan
be625f561c implement notebookInfoBtn logics
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-23 18:07:05 +08:00
Le Tan
b85bf8bdc7 add menus and toolbars
1. Add menu item "Converter" to choose markdown converter;
2. Add menu item "About" and "About Qt";
3. Change all QMessageBox's parent to "this";

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-23 13:12:32 +08:00
Le Tan
a983026552 add Hoedown for markdown convertion
Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-23 10:35:31 +08:00
Le Tan
5fa07864a1 move source stuff into src subdir
Make it convenient to add third-party libraries.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
2016-10-22 14:11:33 +08:00