Skip to content

Commit

Permalink
FIX: issue red#5436 ([GTK, Regression] Pair face/offset is converted …
Browse files Browse the repository at this point in the history
…into point2D which is then ignored)
  • Loading branch information
qtxie committed Nov 30, 2023
1 parent db3de7b commit fa127ba
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions modules/view/backends/gtk3/gui.reds
Original file line number Diff line number Diff line change
Expand Up @@ -247,15 +247,10 @@ set-widget-child: func [
csym [integer!]
clayout [handle!]
playout [handle!]
pt [red-point2D!]
][
sym: get-widget-symbol parent
either TYPE_OF(offset) = TYPE_PAIR [
x: offset/x
y: offset/y
][
x: 0
y: 0
]
GET_PAIR_XY_INT(offset x y)
cvalues: get-face-values widget
ctype: as red-word! cvalues + FACE_OBJ_TYPE
csym: symbol/resolve ctype/symbol
Expand Down Expand Up @@ -320,9 +315,12 @@ set-widget-child-offset: func [
sym [integer!]
cparent [handle!]
alloc [GtkAllocation! value]
pt [red-point2D!]
x y [integer!]
][
GET_PAIR_XY_INT(pos x y)
either type = window [
gtk_window_move widget pos/x pos/y
gtk_window_move widget x y
][
values: get-face-values widget
ntype: as red-word! values + FACE_OBJ_TYPE
Expand All @@ -336,7 +334,7 @@ set-widget-child-offset: func [
ntype: as red-word! values + FACE_OBJ_TYPE
sym: symbol/resolve ntype/symbol
cparent: get-face-child-layout parent sym
set-widget-offset cparent layout pos/x pos/y
set-widget-offset cparent layout x y
]
if type = base [
layout: GET-CARET-OWNER(widget)
Expand Down

0 comments on commit fa127ba

Please sign in to comment.