parent
899010e739
commit
8e99c3f339
|
|
@ -1433,7 +1433,7 @@ type TVclDesigner = class(tvcform)
|
|||
ic.Readvcon(HexFormatStrToTsl(GetTsIconBitmapInfo()));
|
||||
self.FormICon := ic;
|
||||
//文件打窗口
|
||||
FProjectFileOpener := new TOpenFileADlg(self);
|
||||
FProjectFileOpener := new TSavefileADlg(self);
|
||||
FProjectFileOpener.filter := array("tvcl工程":"*.tpj");
|
||||
FProjectFileOpener.parent := self;
|
||||
FProjectManager.FTslEditer.setdbugruncall(thisfunction(debugproject)); //设置调试回调
|
||||
|
|
|
|||
|
|
@ -318,6 +318,7 @@ type TDComponent = class()
|
|||
dm := MessageBoxA("¼´½«¼ôÇÐ:"+nd.Caption,"ɾ³ý",(0x1 .| 0x30),nd.owner);//
|
||||
end else dm := MessageBoxA("¼´½«É¾³ý:"+nd.Caption,"ɾ³ý",(0x1 .| 0x30),nd.owner);//
|
||||
if dm<>1 then exit;
|
||||
if not nd.owner then exit;
|
||||
d := nd.owner.Designer;
|
||||
if f then
|
||||
d.cutnode(nd);
|
||||
|
|
|
|||
|
|
@ -1502,6 +1502,8 @@ type TGridCellNaturalEdit = class(TGridPropertyRender,TPropertyNatural)
|
|||
function Ched(o,e);
|
||||
begin
|
||||
v := textonumber(o.TEXT);
|
||||
if flastvalue = v then return ;
|
||||
flastvalue := v;
|
||||
FGrid.CellChanged(FRow,FCol,"value",v);
|
||||
//o.parent.CallChanged(o.parent,nil);
|
||||
end
|
||||
|
|
@ -1562,10 +1564,12 @@ type TGridCellNaturalEdit = class(TGridPropertyRender,TPropertyNatural)
|
|||
@explan(˵Ã÷) À뿪±à¼¸ñ×Ó %%
|
||||
**}
|
||||
if not(FEdit is class(TPopEditCtrl)) then exit;
|
||||
FEdit.text := "";
|
||||
//FEdit.text := "";
|
||||
FEdit.visible := false;
|
||||
inherited;
|
||||
end;
|
||||
private
|
||||
flastvalue;
|
||||
|
||||
end
|
||||
type TGridCellIntegerEdit = class(TGridCellNaturalEdit)
|
||||
|
|
@ -2478,7 +2482,7 @@ type UniCheckList = class(TTreeView) //
|
|||
if nit >=0 then
|
||||
begin
|
||||
inherited;
|
||||
if CurrentNode<>nit then
|
||||
if CurrentNode and CurrentNode<>nit then
|
||||
begin
|
||||
DoOnSelChang(CurrentNode._tag);
|
||||
end
|
||||
|
|
|
|||
|
|
@ -800,7 +800,7 @@ type tsgtkapi = class(tgtkapis)
|
|||
fc := ftod["facename"];
|
||||
ht := ftod["height"];
|
||||
wd := ftod["width"];
|
||||
it := ftod["italic"];
|
||||
it := 0;//ftod["italic"];
|
||||
wt := ftod["weight"]=700;
|
||||
udl := ftod["underline"];
|
||||
fnotset := false;
|
||||
|
|
@ -2229,16 +2229,16 @@ type tsgtkapi = class(tgtkapis)
|
|||
cairo_scale(hdc,p1,p2);
|
||||
cairo_set_source_surface(hdc, img, 0, 0);
|
||||
cairo_rectangle(hdc,0,0,rc[2]-rc[0],rc[3]-rc[1]);
|
||||
if flag = 0x8800c6 or flag = 0x4 then
|
||||
if flag = 0x8800c6 or flag = 0x4 then //Ìí¼Óalpha´¦Àí
|
||||
begin
|
||||
//echo "\r\nset alopha*******+++****************";
|
||||
//cairo_paint_with_alpha(hdc,0.5);
|
||||
//cairo_set_source_rgba(hdc, 0.6, 0.6, 0.6, 0.5);
|
||||
cairo_paint_with_alpha(hdc,0.5);
|
||||
cairo_set_source_rgba(hdc, 0.6, 0.6, 0.6, 0.5);
|
||||
end else
|
||||
begin
|
||||
//cairo_paint_with_alpha(hdc,0);
|
||||
//cairo_paint_with_alpha(hdc,1);
|
||||
//cairo_set_source_rgba(hdc, 1.0, 1.0, 1.0, 0);
|
||||
cairo_paint_with_alpha(hdc,1);
|
||||
cairo_set_source_rgba(hdc, 1.0, 1.0, 1.0, 0);
|
||||
end
|
||||
cairo_fill(hdc);
|
||||
cairo_scale(hdc,1/p1,1/p2);
|
||||
|
|
@ -2546,7 +2546,7 @@ type tsgtkapi = class(tgtkapis)
|
|||
mulsel := false;
|
||||
if obj._getvalue_("flags") .& 0x200 then mulsel := true;
|
||||
//echo "\r\n>>>", obj._getvalue_("nmaxfiletitle");
|
||||
opaction := g_open_file_flag?false:true; //´ò¿ª»òÕßsave
|
||||
opaction := g_open_file_flag?false:true; //´ò¿ª»òÕßsave
|
||||
cdlg := gtk_file_chooser_dialog_new("file selector",wd,opaction,"open",GTK_RESPONSE_ACCEPT,"cancel",GTK_RESPONSE_CANCEL,nil);
|
||||
if mulsel then
|
||||
begin
|
||||
|
|
@ -2555,7 +2555,7 @@ type tsgtkapi = class(tgtkapis)
|
|||
dfdir := obj._getvalue_("lpstrinitialdir");
|
||||
if dfdir then //默认位置
|
||||
begin
|
||||
df := ReadStringFromPtr(dfdir);
|
||||
df := my_trim( ReadStringFromPtr(dfdir));
|
||||
if df then
|
||||
begin
|
||||
gtk_file_chooser_set_filename(cdlg,TslStringToGtk( df));
|
||||
|
|
@ -2678,7 +2678,7 @@ type tsgtkapi = class(tgtkapis)
|
|||
ht := lgobj._getvalue_("height");
|
||||
hts := "";
|
||||
if ht>5 then hts := inttostr(ht);
|
||||
ss := lgobj._getvalue_("facename")+" "+(lgobj._getvalue_("italic")?"Italic":"")+" "+((lgobj._getvalue_("weight")=700)?"Bold":"") + " "+ hts;;
|
||||
ss := my_trim(lgobj._getvalue_("facename"))+" "+(lgobj._getvalue_("italic")?"Italic":"")+" "+((lgobj._getvalue_("weight")=700)?"Bold":"") + " "+ hts;;
|
||||
cdlg := gtk_font_selection_dialog_new("font select");
|
||||
gtk_font_selection_dialog_set_preview_text(cdlg,"test fonttext");
|
||||
gtk_font_selection_dialog_set_font_name(cdlg,TslStringToGtk(ss));
|
||||
|
|
@ -2772,7 +2772,7 @@ type tsgtkapi = class(tgtkapis)
|
|||
dir := obj._getvalue_("pidlroot");
|
||||
if dir then //默认位置
|
||||
begin
|
||||
df := ReadStringFromPtr(dir);
|
||||
df := (ReadStringFromPtr(dir));
|
||||
if df then
|
||||
begin
|
||||
gtk_file_chooser_set_filename(cdlg,TslStringToGtk( df));
|
||||
|
|
@ -3038,6 +3038,19 @@ begin
|
|||
global G_O_TSWIN32API_;
|
||||
return G_O_TSWIN32API_;
|
||||
end
|
||||
function my_trim(s);
|
||||
begin
|
||||
if not ifstring(s) then return "";
|
||||
for i:= 1 to length(s) do
|
||||
begin
|
||||
if s[i]="\0" then
|
||||
begin
|
||||
if i=1 then return "";
|
||||
return s[1:(i-1)];
|
||||
end
|
||||
end
|
||||
return s;
|
||||
end
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
type TGtkList = class( _gslist) //gtk链表类
|
||||
function create(ptr);
|
||||
|
|
@ -3202,7 +3215,7 @@ type tgtkapis = class() //gtk
|
|||
end
|
||||
if needset then
|
||||
begin
|
||||
c := gtk_object_get_data(it,"caption");
|
||||
c := my_trim(gtk_object_get_data(it,"caption"));
|
||||
if gtk_object_get_data(it,"checked") then
|
||||
begin
|
||||
gtk_menu_item_set_label(it,TslStringToGtk("[√]"+c));
|
||||
|
|
@ -3230,7 +3243,7 @@ type tgtkapis = class() //gtk
|
|||
ft := lpm.ftype;
|
||||
st := lpm.fstate;
|
||||
ss := " ";
|
||||
c := lpm.getdwtypedata()?:"";
|
||||
c := my_trim(lpm.getdwtypedata())?:"";
|
||||
if ft = _const.MFT_SEPARATOR then //分割
|
||||
begin
|
||||
it := gtk_separator_menu_item_new();
|
||||
|
|
@ -5498,7 +5511,7 @@ type tgtkapis = class() //gtk
|
|||
end
|
||||
return r;
|
||||
end
|
||||
|
||||
|
||||
end
|
||||
|
||||
type _cairo_matrix_t = class(tslcstructureobj)
|
||||
|
|
|
|||
|
|
@ -3032,7 +3032,14 @@ type TSynHighLighter = class(TComponent) //
|
|||
if pos(vi," \t")>0 then
|
||||
begin
|
||||
SetTToken(tks,ctk,idx-1);
|
||||
end
|
||||
end else
|
||||
if idx<len and( ord(vi)=0xa3 or ord(vi)=0xa1) then
|
||||
begin
|
||||
SetTToken(tks,ctk,idx-1);
|
||||
ctk := s[idx:(idx+1)];
|
||||
idx++;
|
||||
SetTToken(tks,ctk,idx);
|
||||
end
|
||||
else
|
||||
begin
|
||||
ctk+=vi;
|
||||
|
|
|
|||
|
|
@ -79,7 +79,10 @@ type TCustomThreadworker = class()
|
|||
end
|
||||
function Close(); //¹Ø±Õ
|
||||
begin
|
||||
destroy();
|
||||
if FThreader then
|
||||
begin
|
||||
FThreader.close();
|
||||
end
|
||||
end
|
||||
function terminate();
|
||||
begin
|
||||
|
|
@ -138,10 +141,7 @@ type TCustomThreadworker = class()
|
|||
end
|
||||
function destroy();override;
|
||||
begin
|
||||
if FThreader then
|
||||
begin
|
||||
FThreader.close();
|
||||
end
|
||||
close();
|
||||
inherited;
|
||||
end
|
||||
property componet read getcomponet write setcomponet;
|
||||
|
|
|
|||
Binary file not shown.
Loading…
Reference in New Issue