Skip to content

Commit

Permalink
Quilter 3.0-1
Browse files Browse the repository at this point in the history
  • Loading branch information
Lains committed Jan 21, 2021
1 parent c99916c commit 827b1e5
Show file tree
Hide file tree
Showing 11 changed files with 76 additions and 40 deletions.
Binary file modified data/images/shot-dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified data/images/shot-preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified data/images/shot-sepia.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified data/images/shot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
26 changes: 18 additions & 8 deletions data/styles/app-stylesheet-dark.css
Original file line number Diff line number Diff line change
@@ -1,23 +1,33 @@
@define-color accent #3584e4;
@define-color color_primary #111;

.quilter-sidebar {
background: shade(mix(@accent, @color_primary, 0.88), 0.90);
}
@define-color color_primary #1e1e1e;

.quilter-sidebar,
.quilter-sidebar list,
.quilter-sidebar treeview.view {
background: shade(mix(@accent, @color_primary, 0.88), 0.90);
background: mix (@accent, @color_primary, 0.90);
color: @theme_fg_color;
}

.quilter-sidebar-box {
background-color: shade(mix(@accent, @color_primary, 0.88), 0.90);
color: @theme_fg_color;
}

.quilter-sidebar-box button {
color: @theme_fg_color;
}

.quilter-sidebar-box:focus,
.quilter-sidebar-box:selected,
.quilter-sidebar-box:active,
.quilter-sidebar-box:hover {
background-color: shade(mix(@accent, @color_primary, 0.88), 1.5);
background-color: shade(mix(@accent, @color_primary, 0.88), 1.5);
}

.quilter-sidebar-box:active:backdrop,
.quilter-sidebar-box:selected:backdrop,
.quilter-sidebar-box:focus:backdrop,
.quilter-sidebar-box:hover:backdrop {
background: alpha(shade(mix (@accent, @color_primary, 0.90), 0.88), 0.88);
}

.quilter-menu {
Expand Down
28 changes: 19 additions & 9 deletions data/styles/app-stylesheet-sepia.css
Original file line number Diff line number Diff line change
@@ -1,29 +1,39 @@
@define-color color_primary #f0e8dd;
@define-color accent #33d17a;

.quilter-sidebar {
background: shade(mix(@accent, @color_primary, 0.88), 0.90);
}

.quilter-sidebar,
.quilter-sidebar list,
.quilter-sidebar treeview.view {
background: shade(mix(@accent, @color_primary, 0.88), 0.90);
background: mix (@accent, @color_primary, 0.90);
color: @theme_fg_color;
}

.quilter-sidebar-box {
background-color: shade(mix(@accent, @color_primary, 0.88), 0.90);
color: @theme_fg_color;
}

.quilter-sidebar-box button {
color: @theme_fg_color;
}

.quilter-sidebar-box:focus,
.quilter-sidebar-box:selected,
.quilter-sidebar-box:active,
.quilter-sidebar-box:hover {
background-color: shade(mix(@accent, @color_primary, 0.88), 0.66);
background: shade(mix (@accent, @color_primary, 0.90), 0.88);
}

.quilter-sidebar-box:active:backdrop,
.quilter-sidebar-box:selected:backdrop,
.quilter-sidebar-box:focus:backdrop,
.quilter-sidebar-box:hover:backdrop {
background: alpha(shade(mix (@accent, @color_primary, 0.90), 0.88), 0.88);
}

.quilter-menu {
background-color: shade(@color_primary, 1.04);
background: shade(@color_primary, 1.04);
}

.quilter-focus-button {
background-color: shade(@color_primary, 1.1);
background: shade(@color_primary, 1.1);
}
30 changes: 20 additions & 10 deletions data/styles/app-stylesheet.css
Original file line number Diff line number Diff line change
@@ -1,29 +1,39 @@
@define-color color_primary #F6F5F4;
@define-color color_primary #f6f5f4;
@define-color accent #3584e4;

.quilter-sidebar {
background: shade(mix(@accent, @color_primary, 0.88), 0.90);
}

.quilter-sidebar,
.quilter-sidebar list,
.quilter-sidebar treeview.view {
background: shade(mix(@accent, @color_primary, 0.88), 0.90);
background: mix (@accent, @color_primary, 0.90);
color: @theme_fg_color;
}

.quilter-sidebar-box {
background-color: shade(mix(@accent, @color_primary, 0.88), 0.90);
color: @theme_fg_color;
}

.quilter-sidebar-box button {
color: @theme_fg_color;
}

.quilter-sidebar-box:focus,
.quilter-sidebar-box:selected,
.quilter-sidebar-box:active,
.quilter-sidebar-box:hover {
background-color: shade(mix(@accent, @color_primary, 0.88), 0.66);
background: shade(mix (@accent, @color_primary, 0.90), 0.88);
}

.quilter-sidebar-box:active:backdrop,
.quilter-sidebar-box:selected:backdrop,
.quilter-sidebar-box:focus:backdrop,
.quilter-sidebar-box:hover:backdrop {
background: alpha(shade(mix (@accent, @color_primary, 0.90), 0.88), 0.88);
}

.quilter-menu {
background-color: shade(@color_primary, 1.04);
background: shade(@color_primary, 1.04);
}

.quilter-focus-button {
background-color: shade(@color_primary, 1.1);
background: shade(@color_primary, 1.1);
}
2 changes: 1 addition & 1 deletion src/MainWindow.vala
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@ namespace Quilter {
main_leaf.add (win_stack);

var sep = new Gtk.Separator (Gtk.Orientation.VERTICAL);
sep.vexpand = true;
sep.get_style_context ().add_class ("sidebar");

grid = new Hdy.Leaflet ();
grid.add (sidebar);
Expand Down
26 changes: 15 additions & 11 deletions src/Widgets/HeaderBar.vala
Original file line number Diff line number Diff line change
Expand Up @@ -380,19 +380,23 @@ namespace Quilter.Widgets {
rename_button.get_style_context ().add_class ("suggested-action");

rename_button.clicked.connect (() => {
var new_filename = rename_entry.get_text ();
foreach (var child in win.sidebar.column.get_children ()) {
if (child == win.sidebar.get_selected_row ()) {
var path_new = ((Widgets.SideBarBox)child).path.replace (Path.get_basename(((Widgets.SideBarBox)child).path), new_filename);
Services.FileManager.save_file (path_new, win.edit_view_content.text);

((Widgets.SideBarBox)child).path = path_new;
samenu_button.title = Path.get_basename(path_new);
samenu_button.subtitle = path_new.replace(GLib.Environment.get_home_dir (), "~");
try {
var new_filename = rename_entry.get_text ();
foreach (var child in win.sidebar.column.get_children ()) {
if (child == win.sidebar.get_selected_row ()) {
var path_new = ((Widgets.SideBarBox)child).path.replace (Path.get_basename(((Widgets.SideBarBox)child).path), new_filename);
Services.FileManager.save_file (path_new, win.edit_view_content.text);

((Widgets.SideBarBox)child).path = path_new;
samenu_button.title = Path.get_basename(path_new);
samenu_button.subtitle = path_new.replace(GLib.Environment.get_home_dir (), "~");
}
}
}

rename_entry.set_text ("");
rename_entry.set_text ("");
} catch (Error e) {
warning ("Unexpected error during rename: " + e.message);
}
});

var rename_label = new Gtk.Label (_("Rename the File:"));
Expand Down
2 changes: 1 addition & 1 deletion src/Widgets/SideBar.vala
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ namespace Quilter.Widgets {
column.selection_mode = Gtk.SelectionMode.SINGLE;
column.set_sort_func (list_sort);
column.set_placeholder (no_files);
column.margin_top = 6;
column.margin_top = 12;
column.margin_start = column.margin_end = 12;

for (int i = 0; i < Quilter.Application.gsettings.get_strv("last-files").length; i++) {
Expand Down
2 changes: 2 additions & 0 deletions src/Widgets/WebView.vala
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,8 @@ namespace Quilter {
return false;
}
break;
case WebKit.PolicyDecisionType.NAVIGATION_ACTION:
break;
}

return true;
Expand Down

0 comments on commit 827b1e5

Please sign in to comment.