Skip to content

Commit

Permalink
UI|libappfw: Only allow UI downscaling on HiDPI displays
Browse files Browse the repository at this point in the history
On a non-retina display, text would simply become unreadable. Better to use
the -dpi and -fontsize switches instead.

IssueID #2009
  • Loading branch information
skyjake committed Apr 4, 2015
1 parent 39c536d commit a346281
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions doomsday/sdk/libappfw/src/vrwindowtransform.cpp
Expand Up @@ -66,6 +66,8 @@ DENG2_PIMPL(VRWindowTransform)

float displayModeDependentUIScalingFactor() const
{
if(GuiWidget::toDevicePixels(1) == 1) return 1.0f; // Not enough pixels for good-quality scaling.

// Since the UI style doesn't yet support scaling at runtime based on
// display resolution (or any other factor).
return 1.f / Rangef(.5f, 1.0f).clamp((self.window().width() - GuiWidget::toDevicePixels(256.f)) /
Expand Down

0 comments on commit a346281

Please sign in to comment.