File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
GUI/src/main/kotlin/ui/components/diffScreen/timeline Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -251,6 +251,8 @@ private fun ThumbnailLabel(
251
251
width : Float ,
252
252
modifier : Modifier = Modifier ,
253
253
) {
254
+ val densityCorrectedWidth = with (LocalDensity .current) { width.toDp() }
255
+
254
256
// Labels Container
255
257
Column (
256
258
modifier = modifier.fillMaxSize(),
@@ -268,10 +270,10 @@ private fun ThumbnailLabel(
268
270
)
269
271
270
272
// draw a tick for the text
271
- Canvas (modifier = Modifier .fillMaxSize ()) {
273
+ Canvas (modifier = Modifier .width(densityCorrectedWidth).fillMaxHeight ()) {
272
274
drawLine(
273
- start = Offset (width / 2 , 0f ),
274
- end = Offset (width / 2 , size.height),
275
+ start = Offset (densityCorrectedWidth.toPx() / 2 , 0f ),
276
+ end = Offset (densityCorrectedWidth.toPx() / 2 , size.height),
275
277
color = lineColor,
276
278
strokeWidth = 3f ,
277
279
)
You can’t perform that action at this time.
0 commit comments