Skip to content

Commit

Permalink
Fix regression caused by #1266
Browse files Browse the repository at this point in the history
Closes #1282
  • Loading branch information
tresf committed Jul 23, 2024
1 parent 2aba19c commit 522fba3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/qz/ui/component/DisplayTable.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ private void initComponents() {

// Fix Linux row height
int origHeight = getRowHeight();
if(SystemUtilities.getWindowScaleFactor() != 1) {
if(SystemUtilities.getWindowScaleFactor() > 1) {
setRowHeight((int)(origHeight * SystemUtilities.getWindowScaleFactor()));
}

Expand Down
4 changes: 2 additions & 2 deletions src/qz/utils/GtkUtilities.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public static double getScaleFactor() {
} catch(Throwable t) {
log.warn("An error occurred initializing the Gtk library", t);
}
return 0;
return 1;
}

private static GTK getGtkInstance() {
Expand Down Expand Up @@ -88,7 +88,7 @@ private static double getGtk3ScaleFactor(GTK3 gtk3) {
Pointer screen = gtk3.gdk_display_get_default_screen(display);
return gtk3.gdk_screen_get_monitor_scale_factor(screen, 0);
}
return 0;
return 1;
}

/**
Expand Down

0 comments on commit 522fba3

Please sign in to comment.