Skip to content

Commit

Permalink
print layout sizes during the bootstrap too
Browse files Browse the repository at this point in the history
  • Loading branch information
quasilyte committed Apr 1, 2024
1 parent 2eff54e commit bbeeee8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ require (
github.com/mattn/go-sqlite3 v1.14.22
github.com/quasilyte/ebitengine-resource v0.5.1-0.20231101125830-f1fc00a87be0
github.com/quasilyte/gdata v0.8.1
github.com/quasilyte/ge v0.0.0-20231124151700-929daaff90ec
github.com/quasilyte/ge v0.0.0-20240401194036-d365e4a24b88
github.com/quasilyte/gmath v0.0.0-20230626195558-43d7cdc669ef
github.com/quasilyte/gsignal v0.0.0-20231010082051-3c00e9ebb4e5
github.com/quasilyte/xm v0.0.0-20240228102732-966acb9af598
Expand Down
2 changes: 2 additions & 0 deletions src/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ github.com/quasilyte/gdata v0.8.1 h1:cR9TFUHrRciVq1E4hqofan6jcQvmJd9lM1E7YLeUfi8
github.com/quasilyte/gdata v0.8.1/go.mod h1:VZbd2RCpKR2cbTGuLC1Esnyl1+KFv/jXBJrs/ijL8TA=
github.com/quasilyte/ge v0.0.0-20231124151700-929daaff90ec h1:9pxzQXfTkwGKATAMbaSrDBOItQLiAqohc3en+KZZiHk=
github.com/quasilyte/ge v0.0.0-20231124151700-929daaff90ec/go.mod h1:SZ1XrZNdqgThnC/GS4lAPrwyP00pUNlESCDAGdZz95c=
github.com/quasilyte/ge v0.0.0-20240401194036-d365e4a24b88 h1:ch8MWJqeW27amIn7v5SyeeGJpoa/qWt1ekNm9H2QBkg=
github.com/quasilyte/ge v0.0.0-20240401194036-d365e4a24b88/go.mod h1:SZ1XrZNdqgThnC/GS4lAPrwyP00pUNlESCDAGdZz95c=
github.com/quasilyte/gmath v0.0.0-20230626195558-43d7cdc669ef h1:ylROAnCA+a6Ry6M9pkRXzL+bhPIT5ctHND5kcdxbwe4=
github.com/quasilyte/gmath v0.0.0-20230626195558-43d7cdc669ef/go.mod h1:EbI+KMbALSVE2s0YFOQpR4uj66zBh9ter5P4CBMSuvA=
github.com/quasilyte/gsignal v0.0.0-20231010082051-3c00e9ebb4e5 h1:G6D9dfcBvveLmNi8B7de96/347Xk8rvTyhQb6uNwWPQ=
Expand Down
6 changes: 4 additions & 2 deletions src/scenes/menus/bootload.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,11 @@ func (c *BootloadController) Init(scene *ge.Scene) {

d := c.scene.Dict()

{
if c.state.Persistent.Settings.DebugLogs {
scaleFactor := ebiten.DeviceScaleFactor()
c.state.Logf("device scale factor is %.2f", scaleFactor)
c.state.Logf("device scale factor: %.2f", scaleFactor)
layoutWidth, layoutHeight := scene.Context().LayoutSize()
c.state.Logf("device layout sizes: %vx%v", layoutWidth, layoutHeight)
}

smallFont := assets.BitmapFont1
Expand Down

0 comments on commit bbeeee8

Please sign in to comment.