Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
skiko
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
liuqiang
skiko
Commits
926a970c
Commit
926a970c
authored
Jan 21, 2021
by
Igor Demin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix white screen on Ubuntu with 200% scale
parent
be05f641
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
PlatformOperations.kt
.../jvmMain/kotlin/org/jetbrains/skiko/PlatformOperations.kt
+11
-1
No files found.
skiko/src/jvmMain/kotlin/org/jetbrains/skiko/PlatformOperations.kt
View file @
926a970c
...
...
@@ -68,7 +68,17 @@ internal val platformOperations: PlatformOperations by lazy {
}
override
fun
getDpiScale
(
component
:
Component
):
Float
{
return
linuxGetDpiScaleNative
(
component
)
return
component
.
graphicsConfiguration
.
defaultTransform
.
scaleX
.
toFloat
()
// TODO doesn't work well because java doesn't scale windows (content has offset with 200% scale)
//
// Two solutions:
// 1. dynamically change sun.java2d.uiScale (it is global property, so we have to be careful) and update all windows
//
// 2. apply contentScale manually to all windows
// (it is not good, because on different platform windows will have different size.
// Maybe we will apply contentScale manually on all platforms?)
// return linuxGetDpiScaleNative(component)
}
override
fun
createHardwareRedrawer
(
layer
:
HardwareLayer
)
=
LinuxRedrawer
(
layer
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment