make usable on recent fedora/gnome/gtk

gh-pages
Wolf Vollprecht 2017-12-07 07:56:39 +01:00
parent da4efb4b0b
commit dad4da1678
8 changed files with 26 additions and 77 deletions

View File

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
</project>

View File

@ -1,27 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DaemonCodeAnalyzer">
<disable_hints />
</component>
<component name="DependencyValidationManager">
<option name="SKIP_IMPORT_STATEMENTS" value="false" />
</component>
<component name="Encoding" useUTFGuessing="true" native2AsciiForPropertiesFiles="false" />
<component name="ProjectLevelVcsManager" settingsEditedManually="false">
<OptionsSetting value="true" id="Add" />
<OptionsSetting value="true" id="Remove" />
<OptionsSetting value="true" id="Checkout" />
<OptionsSetting value="true" id="Update" />
<OptionsSetting value="true" id="Status" />
<OptionsSetting value="true" id="Edit" />
<ConfirmationsSetting value="0" id="Add" />
<ConfirmationsSetting value="0" id="Remove" />
</component>
<component name="ProjectModuleManager">
<modules />
</component>
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.4.1 (/usr/bin/python3.4)" project-jdk-type="Python SDK" />
<component name="RunManager">
<list size="0" />
</component>
</project>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/uberwriter.iml" filepath="$PROJECT_DIR$/.idea/uberwriter.iml" />
</modules>
</component>
</project>

View File

@ -1,5 +0,0 @@
<component name="DependencyValidationManager">
<state>
<option name="SKIP_IMPORT_STATEMENTS" value="false" />
</state>
</component>

View File

@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="$PROJECT_DIR$" vcs="Git" />
</component>
</project>

View File

@ -37,13 +37,14 @@
} }
.uberwriter_window { .uberwriter_window {
gtk-key-bindings: window-bindings; -gtk-key-bindings: window-bindings;
/*border-radius: 7px 7px 3px 3px;*/ /*border-radius: 7px 7px 3px 3px;*/
background: @light_editor_bg; background: @light_editor_bg;
} }
.uberwriter_window.small .uberwriter-editor { .uberwriter_window.small .uberwriter-editor {
font: Inconsolata 12; font-family: 'Fira Mono', monospace;
font-size: 12px;
} }
.uberwriter_window GtkGrid { .uberwriter_window GtkGrid {
background-color: @light_editor_bg; background-color: @light_editor_bg;
@ -55,13 +56,13 @@
} }
#UberwriterWindow.medium .uberwriter-editor { #UberwriterWindow.medium .uberwriter-editor {
font: Fira Mono 15; font-family: 'Fira Mono', monospace;
font-size: 15px;
} }
#UberwriterWindow.large .uberwriter-editor { #UberwriterWindow.large .uberwriter-editor {
/*font: Inconsolata 17; font-family: 'Fira Mono', monospace;
*/ font-size: 18px;
font: Fira Mono 12;
} }
#UberwriterWindow GtkAlignment { #UberwriterWindow GtkAlignment {
@ -80,7 +81,7 @@
.uberwriter_window.dark_mode .uberwriter-editor { .uberwriter_window.dark_mode .uberwriter-editor {
color: #CCC; color: #CCC;
background: @dark_bg; background: @dark_bg;
-GtkWidget-cursor-color: shade(#4D9FCE, 0.9); /*-GtkWidget-cursor-color: shade(#4D9FCE, 0.9);*/
} }
.scrollbars-junction, .scrollbars-junction,
@ -92,9 +93,9 @@
border: none; border: none;
background-color: transparent; background-color: transparent;
color: #222; color: #222;
-GtkWidget-cursor-color: shade(#4D9FCE, 0.9); /*-GtkWidget-cursor-color: shade(#4D9FCE, 0.9);*/
-GtkWidget-cursor-aspect-ratio: 0.1; /*-GtkWidget-cursor-aspect-ratio: 0.1;*/
gtk-key-bindings: editor-bindings; -gtk-key-bindings: editor-bindings;
} }
.uberwriter-editor:selected { .uberwriter-editor:selected {
@ -123,7 +124,7 @@
/* finding reset */ /* finding reset */
background-color: initial; background-color: initial;
text-shadow: inherit; text-shadow: inherit;
icon-shadow: inherit; /*icon-shadow: inherit;*/
box-shadow: initial; box-shadow: initial;
background-clip: initial; background-clip: initial;
background-origin: initial; background-origin: initial;
@ -141,13 +142,14 @@
border-radius: 2px; border-radius: 2px;
color: #666; color: #666;
padding: 3px 5px; padding: 3px 5px;
/*
-GtkButton-child-displacement-y: 0px; -GtkButton-child-displacement-y: 0px;
-GtkButton-child-displacement-x: 0px; -GtkButton-child-displacement-x: 0px;
-GtkButton-default-border: 0; -GtkButton-default-border: 0;
-GtkButton-image-spacing: 5px; -GtkButton-image-spacing: 5px;
-GtkButton-interior-focus: false; -GtkButton-interior-focus: false;
-GtkButton-inner-border: 0; -GtkButton-inner-border: 0;
*/
transition: 500ms ease-in; transition: 500ms ease-in;
} }
@ -191,7 +193,9 @@
} }
#LexikonBubble { #LexikonBubble {
font: serif 10; /*font: serif 10;*/
font-family: serif;
font-size: 10px;
background: #FFF; background: #FFF;
border-radius: 4px; border-radius: 4px;
margin: 5px; margin: 5px;
@ -215,7 +219,9 @@
} }
#LexikonBubble .lexikon_heading { #LexikonBubble .lexikon_heading {
font: serif 12; /*font: serif 12;*/
font-family: serif;
font-size: 12px;
padding-bottom: 5px; padding-bottom: 5px;
padding-top: 5px; padding-top: 5px;
font-weight: bold; font-weight: bold;
@ -238,7 +244,7 @@
#UberwriterWindow #AutoCorrect GtkLabel { #UberwriterWindow #AutoCorrect GtkLabel {
padding: 3px 5px; padding: 3px 5px;
font: sans-serif; font-family: sans-serif;
} }
#UberwriterWindow #AutoCorrect GtkImage { #UberwriterWindow #AutoCorrect GtkImage {

View File

@ -27,7 +27,8 @@ locale.textdomain('uberwriter')
import mimetypes import mimetypes
from gi.repository import Gtk, Gdk, GObject, WebKit, Gio # pylint: disable=E0611 from gi.repository import Gtk, Gdk, GObject, Gio # pylint: disable=E0611
from gi.repository import WebKit2 as WebKit
from gi.repository import Pango # pylint: disable=E0611 from gi.repository import Pango # pylint: disable=E0611
import cairo import cairo
@ -40,7 +41,7 @@ from .UberwriterTextEditor import TextEditor
from .UberwriterInlinePreview import UberwriterInlinePreview from .UberwriterInlinePreview import UberwriterInlinePreview
from .UberwriterSidebar import UberwriterSidebar from .UberwriterSidebar import UberwriterSidebar
from .UberwriterSearchAndReplace import UberwriterSearchAndReplace from .UberwriterSearchAndReplace import UberwriterSearchAndReplace
from .UberwriterAutoCorrect import UberwriterAutoCorrect # from .UberwriterAutoCorrect import UberwriterAutoCorrect
import logging import logging
logger = logging.getLogger('uberwriter') logger = logging.getLogger('uberwriter')
@ -61,7 +62,7 @@ from uberwriter_lib import Window
from uberwriter_lib import helpers from uberwriter_lib import helpers
from .AboutUberwriterDialog import AboutUberwriterDialog from .AboutUberwriterDialog import AboutUberwriterDialog
from .UberwriterAdvancedExportDialog import UberwriterAdvancedExportDialog from .UberwriterAdvancedExportDialog import UberwriterAdvancedExportDialog
from .plugins.bibtex import BibTex # from .plugins.bibtex import BibTex
# Some Globals # Some Globals
# TODO move them somewhere for better # TODO move them somewhere for better
# accesibility from other files # accesibility from other files
@ -1149,7 +1150,7 @@ class UberwriterWindow(Window):
self.gtk_settings = Gtk.Settings.get_default() self.gtk_settings = Gtk.Settings.get_default()
self.load_settings(builder) self.load_settings(builder)
self.plugins = [BibTex(self)] # self.plugins = [BibTex(self)]
# self.connect_after('realize', self.color_window) # self.connect_after('realize', self.color_window)