File tree Expand file tree Collapse file tree 1 file changed +10
-8
lines changed
extensions/widgets/gradientrampeditor Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Original file line number Diff line number Diff line change @@ -303,14 +303,16 @@ private handler paintCheckerboard() returns nothing
303303end handler
304304
305305private handler paintGradient() returns nothing
306- variable tGradient as Gradient
307- put linear gradient with ramp mGradientRamp into tGradient
308- set the from of tGradient to point [the left of mGradientRectangle, (the top of mGradientRectangle + the bottom of mGradientRectangle) / 2]
309- set the to of tGradient to point [the right of mGradientRectangle, (the top of mGradientRectangle + the bottom of mGradientRectangle) / 2]
310- set the via of tGradient to point [the left of mGradientRectangle, the bottom of mGradientRectangle]
311- add rectangle path of mGradientRectangle to this canvas
312- set the paint of this canvas to tGradient
313- fill this canvas
306+ if mGradientRamp is not empty then
307+ variable tGradient as Gradient
308+ put linear gradient with ramp mGradientRamp into tGradient
309+ set the from of tGradient to point [the left of mGradientRectangle, (the top of mGradientRectangle + the bottom of mGradientRectangle) / 2]
310+ set the to of tGradient to point [the right of mGradientRectangle, (the top of mGradientRectangle + the bottom of mGradientRectangle) / 2]
311+ set the via of tGradient to point [the left of mGradientRectangle, the bottom of mGradientRectangle]
312+ add rectangle path of mGradientRectangle to this canvas
313+ set the paint of this canvas to tGradient
314+ fill this canvas
315+ end if
314316end handler
315317
316318private handler paintRulerBottom() returns nothing
You can’t perform that action at this time.
0 commit comments