Skip to content

Commit

Permalink
Add a "views" toolbar to the main GUI (#1057)
Browse files Browse the repository at this point in the history
  • Loading branch information
vkbo authored May 14, 2022
2 parents d6ca878 + d965320 commit badb768
Show file tree
Hide file tree
Showing 19 changed files with 411 additions and 93 deletions.
2 changes: 1 addition & 1 deletion CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ The following libraries are dependencies of novelWriter:

Some of the assets bundled with novelWriter were adapted from the following sources:

* Typicons icons by Stephen Hutchings (CC BY-SA 4.0)
* [Typicons](https://github.com/stephenhutchings/typicons.font) icons by Stephen Hutchings (CC BY-SA 4.0)
* Tomorrow syntax themes by Chris Kempson (MIT License)
* Owl syntax themes by Sarah Drasner (MIT License)
* Solarized themes by Ethan Schoonover, added by @nullbasis (MIT License)
Expand Down
5 changes: 5 additions & 0 deletions novelwriter/assets/icons/typicons_dark/icons.conf
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,12 @@ hash = typ_hash.svg
maximise = typ_arrow-maximise.svg
minimise = typ_arrow-minimise.svg
proj_chapter = mixed_document-chapter.svg
proj_details = typ_th-list-grey.svg
proj_document = typ_document-text.svg
proj_folder = typ_folder.svg
proj_note = mixed_document-note.svg
proj_scene = mixed_document-scene.svg
proj_stats = typ_chart-bar-grey.svg
proj_title = mixed_document-title.svg
reference = typ_at.svg
refresh = typ_refresh.svg
Expand All @@ -76,3 +78,6 @@ status_time = typ_stopwatch-grey.svg
sticky-off = typ_pin-outline.svg
sticky-on = typ_pin.svg
up = typ_chevron-up.svg
view_editor = typ_edit.svg
view_novel = typ_book-grey.svg
view_outline = typ_puzzle-outline.svg
31 changes: 31 additions & 0 deletions novelwriter/assets/icons/typicons_dark/typ_book-grey.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions novelwriter/assets/icons/typicons_dark/typ_edit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions novelwriter/assets/icons/typicons_dark/typ_puzzle-outline.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions novelwriter/assets/icons/typicons_light/icons.conf
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,12 @@ hash = typ_hash.svg
maximise = typ_arrow-maximise.svg
minimise = typ_arrow-minimise.svg
proj_chapter = mixed_document-chapter.svg
proj_details = typ_th-list-grey.svg
proj_document = typ_document-text.svg
proj_folder = typ_folder.svg
proj_note = mixed_document-note.svg
proj_scene = mixed_document-scene.svg
proj_stats = typ_chart-bar-grey.svg
proj_title = mixed_document-title.svg
reference = typ_at.svg
refresh = typ_refresh.svg
Expand All @@ -76,3 +78,6 @@ status_time = typ_stopwatch-grey.svg
sticky-off = typ_pin-outline.svg
sticky-on = typ_pin.svg
up = typ_chevron-up.svg
view_editor = typ_edit.svg
view_novel = typ_book-grey.svg
view_outline = typ_puzzle-outline.svg
31 changes: 31 additions & 0 deletions novelwriter/assets/icons/typicons_light/typ_book-grey.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions novelwriter/assets/icons/typicons_light/typ_edit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions novelwriter/assets/icons/typicons_light/typ_puzzle-outline.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions novelwriter/enum.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,20 @@ class nwState(Enum):
# END Enum nwState


class nwView(Enum):

EDITOR = 0
PROJECT = 1
NOVEL = 2
OUTLINE = 3
DETAILS = 4
STATS = 5
SET_PROJ = 6
SET_MAIN = 7

# END Enum nwView


class nwWidget(Enum):

TREE = 1
Expand Down
2 changes: 2 additions & 0 deletions novelwriter/gui/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
from novelwriter.gui.projtree import GuiProjectTree
from novelwriter.gui.statusbar import GuiMainStatus
from novelwriter.gui.theme import GuiTheme
from novelwriter.gui.viewsbar import GuiViewsBar

__all__ = [
"GuiDocEditor",
Expand All @@ -42,4 +43,5 @@
"GuiOutlineDetails",
"GuiProjectTree",
"GuiTheme",
"GuiViewsBar",
]
1 change: 1 addition & 0 deletions novelwriter/gui/itemdetails.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ def __init__(self, theParent):
self.usageData = QLabel("")
self.usageData.setFont(fntValue)
self.usageData.setAlignment(Qt.AlignLeft)
self.usageData.setWordWrap(True)

# Character Count
self.cCountName = QLabel(" "+self.tr("Characters"))
Expand Down
Loading

0 comments on commit badb768

Please sign in to comment.