Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing issues in text size when DPI scale is different on an Android device #34

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions gooi/component.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ component.colors = {
component.style = {
bgColor = component.colors.blue,
fgColor = component.colors.white, -- Foreground color
tooltipFont = love.graphics.newFont(love.window.toPixels(11)), -- tooltips are smaller than the main font
tooltipFont = love.graphics.newFont(11), -- tooltips are smaller than the main font
radius = 2, -- raw pixels
innerRadius = 2, -- raw pixels
showBorder = true, -- border for components
borderColor = component.colors.blue,
borderWidth = love.window.toPixels(2), -- in pixels
borderWidth = 2, -- in pixels
borderStyle = "smooth", -- or "smooth"
font = love.graphics.newFont(love.window.toPixels(13)),
font = love.graphics.newFont(13),
}

local currId = -1
Expand Down
2 changes: 1 addition & 1 deletion gooi/gooi.lua
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ gooi.dialogW = 0
gooi.canvas = love.graphics.newCanvas(love.graphics.getWidth(), love.graphics.getHeight())
gooi.sx = 1
gooi.sy = 1
gooi.defaultFont = love.graphics.newFont(love.window.toPixels(13))
gooi.defaultFont = love.graphics.newFont(13)
gooi.font = defaultFont
gooi.unit = 25
gooi.bs = "backspace"
Expand Down