From dac466318f06a7a27af2965279b185f67ba62bd5 Mon Sep 17 00:00:00 2001 From: JianjunLiu Date: Mon, 8 May 2023 11:30:08 +0800 Subject: [PATCH] =?UTF-8?q?=E7=95=8C=E9=9D=A2=E5=BA=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修正 --- funcext/tvclib/ugtkinterface.tsf | 9 ++++++--- funcext/tvclib/utslvclcoolbar.tsf | 6 ++++-- funcext/tvclib/utslvclstdctl.tsf | 1 + 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/funcext/tvclib/ugtkinterface.tsf b/funcext/tvclib/ugtkinterface.tsf index fa19a62..f635770 100644 --- a/funcext/tvclib/ugtkinterface.tsf +++ b/funcext/tvclib/ugtkinterface.tsf @@ -1782,7 +1782,7 @@ type tsgtkapi = class(tgtkapis) end Function PolyBezier(dc :pointer;points:array of integer;n:integer):integer; begin - if length(PolyBezier)<6 then return 0; + if length(points)<8 then return 0; x := gtk_object_get_data(dc,"viewport.x"); y := gtk_object_get_data(dc,"viewport.y"); pc := gtk_object_get_data(dc,"pen.color"); @@ -1797,9 +1797,12 @@ type tsgtkapi = class(tgtkapis) gtk_rgb_color_rgb(pc,rc,gc,bc); cairo_set_source_rgb(dc,rc,gc,bc); end - cairo_move_to(dc,points[0]+x,Points[1]+y); cairo_applay_pen_style(dc); - cairo_curve_to(dc,points[0],points[1],points[2],points[3],points[4],points[5]); + cairo_move_to(dc,points[0]+x,Points[1]+y); + for i := 1 to length(points)-1 step 3 do + begin + cairo_curve_to(dc,points[i+0],points[i+1],points[i+2],points[i+3],points[i+4],points[i+5]); + end cairo_stroke(dc); return 1; end diff --git a/funcext/tvclib/utslvclcoolbar.tsf b/funcext/tvclib/utslvclcoolbar.tsf index 463f310..940ae6e 100644 --- a/funcext/tvclib/utslvclcoolbar.tsf +++ b/funcext/tvclib/utslvclcoolbar.tsf @@ -203,7 +203,7 @@ type tcustomcoolbar=class(tcustomcontrol) begin ctl := bsi.fctl; - if ctl.Visible and not(ctl is class(TWinControl) and ctl.WsPopUp) then + if ctl.Visible and not((ctl is class(TWinControl)) and ctl.WsPopUp) then begin bss[length(bss)]:= bsi; drc := array(x,y,x+mwid,y+rhs[i]); @@ -266,7 +266,9 @@ type tcustomcoolbar=class(tcustomcontrol) for i,v in fcoolbands.data do begin dc.brush.color := fdragbtncolor; - paintbtn(v.fbtnrect); + brc := v.fbtnrect; + if brc then + paintbtn(brc); end dc.brush.color := cl; dc.pen.color := bcl; diff --git a/funcext/tvclib/utslvclstdctl.tsf b/funcext/tvclib/utslvclstdctl.tsf index ec6d4e4..c47330f 100644 --- a/funcext/tvclib/utslvclstdctl.tsf +++ b/funcext/tvclib/utslvclstdctl.tsf @@ -2581,6 +2581,7 @@ type tcustomedit=class(TCustomControl) property onmaxtext:eventhandler read Fonmaxtext write fonmaxtext; property onupdate read FOnUpdate write FOnUpdate; property onchange read FOnChange write FOnChange; + property onchanged:eventhandler read FOnChange write FOnChange; property readonly:bool read getReadOnly write setReadOnly; property limitlength:integer read getlimitlength write setLimitLength; property LineWrap:bool read getLineWrap write setLineWrap;