Fix font errors and spacing in GTK 3.20+
This commit is contained in:
parent
f0d601f98c
commit
7a12af3c11
@ -190,7 +190,7 @@ public class WriteAs.MainWindow : Gtk.ApplicationWindow {
|
||||
var styles = option.get_style_context();
|
||||
var provider = new Gtk.CssProvider();
|
||||
try {
|
||||
provider.load_from_data("* {font: %s;}".printf(families));
|
||||
provider.load_from_data("* {font-family: %s;}".printf(families));
|
||||
styles.add_provider(provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
} catch (Error e) {
|
||||
warning(e.message);
|
||||
@ -230,7 +230,7 @@ public class WriteAs.MainWindow : Gtk.ApplicationWindow {
|
||||
Gtk.StyleContext.remove_provider_for_screen(Gdk.Screen.get_default(), cur_styles);
|
||||
|
||||
var padding = canvas.get_allocated_width()*0.10;
|
||||
var css = ("GtkTextView {font: %s; font-size: %dpx; padding: 20px;" +
|
||||
var css = ("textview {font-family: %s; font-size: %dpx; padding: 20px;" +
|
||||
" padding-left: %ipx; padding-right: %ipx;" +
|
||||
" -GtkWidget-cursor-color: #5ac4ee;}").printf(font, font_size,
|
||||
(int) padding, (int) padding);
|
||||
|
Loading…
Reference in New Issue
Block a user