📄 skindata.pas
字号:
procedure TspDataSkinCheckListBox.SaveToFile;
begin
inherited;
WriteRect(IniFile, IDName, 'itemcheckrect', ItemCheckRect);
WriteRect(IniFile, IDName, 'uncheckimagerect', UnCheckImageRect);
WriteRect(IniFile, IDName, 'checkimagerect', CheckImageRect);
end;
constructor TspDataSkinComboBox.Create(AIDName: String);
begin
inherited;
FontName := 'Arial';
FontStyle := [];
FontHeight := 14;
FontColor := 0;
FocusFontColor := 0;
ListBoxName := '';
end;
procedure TspDataSkinComboBox.LoadFromFile;
begin
inherited;
//
SItemRect := ReadRect(IniFile, IDName, 'itemrect');
FocusItemRect := ReadRect(IniFile, IDName, 'focusitemrect');
ItemLeftOffset := IniFile.ReadInteger(IDName, 'itemleftoffset', 0);
ItemRightOffset := IniFile.ReadInteger(IDName, 'itemrightoffset', 0);
ItemTextRect := ReadRect(IniFile, IDName, 'itemtextrect');
FontName := IniFile.ReadString(IDName, 'fontname', 'Arial');
FontHeight := IniFile.ReadInteger(IDName, 'fontheight', 14);
FontStyle := ReadFontStyles(IniFile, IDName, 'fontstyle');
FontColor := IniFile.ReadInteger(IDName, 'fontcolor', 0);
FocusFontColor := IniFile.ReadInteger(IDName, 'focusfontcolor', 0);
//
ListBoxName := IniFile.ReadString(IDName, 'listboxname', '');
//
ButtonRect := ReadRect(IniFile, IDName, 'buttonrect');
ActiveButtonRect := ReadRect(IniFile, IDName, 'activebuttonrect');
DownButtonRect := ReadRect(IniFile, IDName, 'downbuttonrect');
UnEnabledButtonRect := ReadRect(IniFile, IDName, 'unenabledbuttonrect');
//
end;
procedure TspDataSkinComboBox.SaveToFile;
begin
inherited;
WriteRect(IniFile, IDName, 'itemrect', SItemRect);
WriteRect(IniFile, IDName, 'focusitemrect', FocusItemRect);
IniFile.WriteInteger(IDName, 'itemleftoffset', ItemLeftOffset);
IniFile.WriteInteger(IDName, 'itemrightoffset', ItemRightOffset);
WriteRect(IniFile, IDName, 'itemtextrect', ItemTextRect);
IniFile.WriteString(IDName, 'fontname', FontName);
IniFile.WriteInteger(IDName, 'fontheight', FontHeight);
WriteFontStyles(IniFile, IDName, 'fontstyle', FontStyle);
IniFile.WriteInteger(IDName, 'fontcolor', FontColor);
IniFile.WriteInteger(IDName, 'focusfontcolor', FocusFontColor);
//
WriteRect(IniFile, IDName, 'buttonrect', ButtonRect);
WriteRect(IniFile, IDName, 'activebuttonrect', ActiveButtonRect);
WriteRect(IniFile, IDName, 'downbuttonrect', DownButtonRect);
WriteRect(IniFile, IDName, 'unenabledbuttonrect', UnEnabledButtonRect);
//
IniFile.WriteString(IDName, 'listboxname', ListBoxName);
end;
constructor TspDataSkinControlBar.Create(AIDName: String);
begin
inherited;
BGPictureIndex := -1;
end;
procedure TspDataSkinControlBar.LoadFromFile;
begin
inherited;
ItemRect := ReadRect(IniFile, IDName, 'itemrect');
BGPictureIndex := IniFile.ReadInteger(IDName, 'bgpictureindex', -1);
end;
procedure TspDataSkinControlBar.SaveToFile;
begin
inherited;
WriteRect(IniFile, IDName, 'itemrect', ItemRect);
IniFile.WriteInteger(IDName, 'bgpictureindex', BGPictureIndex);
end;
constructor TspDataSkinTreeView.Create;
begin
inherited;
FontName := 'Arial';
FontStyle := [];
FontHeight := 14;
FontColor := 0;
BGColor := clWhite;
end;
procedure TspDataSkinTreeView.LoadFromFile;
begin
inherited;
FontName := IniFile.ReadString(IDName, 'fontname', 'Arial');
FontHeight := IniFile.ReadInteger(IDName, 'fontheight', 14);
FontStyle := ReadFontStyles(IniFile, IDName, 'fontstyle');
FontColor := IniFile.ReadInteger(IDName, 'fontcolor', 0);
BGColor := IniFile.ReadInteger(IDName, 'bgcolor', 0);
end;
procedure TspDataSkinTreeView.SaveToFile;
begin
inherited;
IniFile.WriteString(IDName, 'fontname', FontName);
IniFile.WriteInteger(IDName, 'fontheight', FontHeight);
WriteFontStyles(IniFile, IDName, 'fontstyle', FontStyle);
IniFile.WriteInteger(IDName, 'fontcolor', FontColor);
IniFile.WriteInteger(IDName, 'bgcolor', BGColor);
end;
constructor TspDataSkinListView.Create;
begin
inherited;
FontName := 'Arial';
FontStyle := [];
FontHeight := 14;
FontColor := 0;
BGColor := clWhite;
end;
procedure TspDataSkinListView.LoadFromFile;
begin
inherited;
FontName := IniFile.ReadString(IDName, 'fontname', 'Arial');
FontHeight := IniFile.ReadInteger(IDName, 'fontheight', 14);
FontStyle := ReadFontStyles(IniFile, IDName, 'fontstyle');
FontColor := IniFile.ReadInteger(IDName, 'fontcolor', 0);
BGColor := IniFile.ReadInteger(IDName, 'bgcolor', 0);
end;
procedure TspDataSkinListView.SaveToFile;
begin
inherited;
IniFile.WriteString(IDName, 'fontname', FontName);
IniFile.WriteInteger(IDName, 'fontheight', FontHeight);
WriteFontStyles(IniFile, IDName, 'fontstyle', FontStyle);
IniFile.WriteInteger(IDName, 'fontcolor', FontColor);
IniFile.WriteInteger(IDName, 'bgcolor', BGColor);
end;
constructor TspDataSkinRichEdit.Create;
begin
inherited;
FontName := 'Arial';
FontStyle := [];
FontHeight := 14;
FontColor := 0;
BGColor := clWhite;
end;
procedure TspDataSkinRichEdit.LoadFromFile;
begin
inherited;
FontName := IniFile.ReadString(IDName, 'fontname', 'Arial');
FontHeight := IniFile.ReadInteger(IDName, 'fontheight', 14);
FontStyle := ReadFontStyles(IniFile, IDName, 'fontstyle');
FontColor := IniFile.ReadInteger(IDName, 'fontcolor', 0);
BGColor := IniFile.ReadInteger(IDName, 'bgcolor', 0);
end;
procedure TspDataSkinRichEdit.SaveToFile;
begin
inherited;
IniFile.WriteString(IDName, 'fontname', FontName);
IniFile.WriteInteger(IDName, 'fontheight', FontHeight);
WriteFontStyles(IniFile, IDName, 'fontstyle', FontStyle);
IniFile.WriteInteger(IDName, 'fontcolor', FontColor);
IniFile.WriteInteger(IDName, 'bgcolor', BGColor);
end;
constructor TspDataSkinSlider.Create;
begin
inherited;
BGColor := 0;
end;
procedure TspDataSkinSlider.LoadFromFile;
begin
inherited;
BGColor := IniFile.ReadInteger(IDName, 'bgcolor', 0);
HRulerRect := ReadRect(IniFile, IDName, 'hrulerrect');
HThumbRect := ReadRect(IniFile, IDName, 'hthumbrect');
VRulerRect := ReadRect(IniFile, IDName, 'vrulerrect');
VThumbRect := ReadRect(IniFile, IDName, 'vthumbrect');
EdgeSize := IniFile.ReadInteger(IDName, 'edgesize', 0);
PointsColor := IniFile.ReadInteger(IDName, 'pointscolor', 0);
end;
procedure TspDataSkinSlider.SaveToFile;
begin
inherited;
IniFile.WriteInteger(IDName, 'bgcolor', BGColor);
WriteRect(IniFile, IDName, 'hrulerrect', HRulerRect);
WriteRect(IniFile, IDName, 'hthumbrect', HThumbRect);
WriteRect(IniFile, IDName, 'vrulerrect', VRulerRect);
WriteRect(IniFile, IDName, 'vthumbrect', VThumbRect);
IniFile.WriteInteger(IDName, 'edgesize', EdgeSize);
IniFile.WriteInteger(IDName, 'pointscolor', PointsColor);
end;
constructor TspDataSkinBevel.Create;
begin
inherited;
LightColor := 0;
DarkColor := 0;
end;
procedure TspDataSkinBevel.LoadFromFile;
begin
inherited;
LightColor := IniFile.ReadInteger(IDName, 'lightcolor', 0);
DarkColor := IniFile.ReadInteger(IDName, 'darkcolor', 0);
end;
procedure TspDataSkinBevel.SaveToFile;
begin
inherited;
IniFile.WriteInteger(IDName, 'lightcolor', LightColor);
IniFile.WriteInteger(IDName, 'darkcolor', DarkColor);
end;
constructor TspDataSkinTabControl.Create(AIDName: String);
begin
inherited;
FontName := 'Arial';
FontStyle := [];
FontHeight := 14;
FontColor := 0;
ActiveFontColor := 0;
FocusFontColor := 0;
UpDown := '';
BGPictureIndex := -1;
end;
procedure TspDataSkinTabControl.LoadFromFile;
begin
inherited;
TabRect := ReadRect(IniFile, IDName, 'tabrect');
ActiveTabRect := ReadRect(IniFile, IDName, 'activetabrect');
FocusTabRect := ReadRect(IniFile, IDName, 'focustabrect');
MouseInTabRect := ReadRect(IniFile, IDName, 'mouseintabrect');
ClRect := ReadRect(IniFile, IDName, 'clientrect');
BGPictureIndex := IniFile.ReadInteger(IDName, 'bgpictureindex', -1);
LTPoint := ReadPoint(IniFile, IDName, 'lefttoppoint');
RTPoint := Readpoint(IniFile, IDName, 'righttoppoint');
LBPoint := ReadPoint(IniFile, IDName, 'leftbottompoint');
RBPoint := ReadPoint(IniFile, IDName, 'rightbottompoint');
TabLeftOffset := IniFile.ReadInteger(IDName, 'tableftoffset', 0);
TabRightOffset := IniFile.ReadInteger(IDName, 'tabrightoffset', 0);
TabsBGRect := ReadRect(IniFile, IDName, 'tabsbgrect');
FontName := IniFile.ReadString(IDName, 'fontname', 'Arial');
FontHeight := IniFile.ReadInteger(IDName, 'fontheight', 14);
FontStyle := ReadFontStyles(IniFile, IDName, 'fontstyle');
FontColor := IniFile.ReadInteger(IDName, 'fontcolor', 0);
ActiveFontColor := IniFile.ReadInteger(IDName, 'activefontcolor', 0);
FocusFontColor := IniFile.ReadInteger(IDName, 'focusfontcolor', 0);
MouseInFontColor := IniFile.ReadInteger(IDName, 'mouseinfontcolor', 0);
UpDown := IniFile.ReadString(IDName, 'updown', '');
end;
procedure TspDataSkinTabControl.SaveToFile;
begin
inherited;
WriteRect(IniFile, IDName, 'tabrect', TabRect);
WriteRect(IniFile, IDName, 'activetabrect', ActiveTabRect);
WriteRect(IniFile, IDName, 'focustabrect', FocusTabRect);
WriteRect(IniFile, IDName, 'mouseintabrect', MouseInTabRect);
WriteRect(IniFile, IDName, 'clientrect', ClRect);
IniFile.WriteInteger(IDName, 'bgpictureindex', BGPictureIndex);
WritePoint(IniFile, IDName, 'lefttoppoint', LTPoint);
writePoint(IniFile, IDName, 'righttoppoint', RTPoint);
WritePoint(IniFile, IDName, 'leftbottompoint', LBPoint);
WritePoint(IniFile, IDName, 'rightbottompoint', RBPoint);
IniFile.WriteInteger(IDName, 'tableftoffset', TabLeftOffset);
IniFile.WriteInteger(IDName, 'tabrightoffset', TabRightOffset);
WriteRect(IniFile, IDName, 'tabsbgrect', TabsBGRect);
IniFile.WriteString(IDName, 'fontname', FontName);
IniFile.WriteInteger(IDName, 'fontheight', FontHeight);
WriteFontStyles(IniFile, IDName, 'fontstyle', FontStyle);
IniFile.WriteInteger(IDName, 'fontcolor', FontColor);
IniFile.WriteInteger(IDName, 'activefontcolor', ActiveFontColor);
IniFile.WriteInteger(IDName, 'focusfontcolor', FocusFontColor);
IniFile.WriteInteger(IDName, 'mouseinfontcolor', MouseInFontColor);
IniFile.WriteString(IDName, 'updown', UpDown);
end;
constructor TspDataSkinGridControl.Create;
begin
inherited;
FontName := 'Arial';
FontStyle := [];
FontHeight := 14;
FontColor := 0;
FixedFontName := 'Arial';
FixedFontStyle := [];
FixedFontHeight := 14;
FixedFontColor := 0;
BGPictureIndex := -1;
end;
procedure TspDataSkinGridControl.LoadFromFile(IniFile: TCustomIniFile);
begin
inherited;
FixedCellRect := ReadRect(IniFile, IDName, 'fixedcellrect');
SelectCellRect := ReadRect(IniFile, IDName, 'selectcellrect');
FocusCellRect := ReadRect(IniFile, IDName, 'focuscellrect');
//
FixedCellLeftOffset := IniFile.ReadInteger(IDName, 'fixedcellleftoffset', 0);
FixedCellRightOffset := IniFile.ReadInteger(IDName, 'fixedcellrightoffset', 0);
FixedCellTextRect := ReadRect(IniFile, IDName, 'fixedcelltextrect');
//
CellLeftOffset := IniFile.ReadInteger(IDName, 'cellleftoffset', 0);
CellRightOffset := IniFile.ReadInteger(IDName, 'cellrightoffset', 0);
CellTextRect := ReadRect(IniFile, IDName, 'celltextrect');
//
LinesColor := IniFile.ReadInteger(IDName, 'linescolor', 0);
BGColor := IniFile.ReadInteger(IDName, 'bgcolor', 0);
BGPictureIndex := IniFile.ReadInteger(IDName, 'bgpictureindex', -1);
FontName := IniFile.ReadString(IDName, 'fontname', 'Arial');
FontHeight := IniFile.ReadInteger(IDName, 'fontheight', 14);
FontStyle := ReadFontStyles(IniFile, IDName, 'fontstyle');
FontColor := IniFile.ReadInteger(IDName, 'fontcolor', 0);
SelectFontColor := IniFile.ReadInteger(IDName, 'selectfontcolor', 0);
FocusFontColor := IniFile.ReadInteger(IDName, 'focusfontcolor', 0);
//
FixedFontName := IniFile.ReadString(IDName, 'fixedfontname', 'Arial');
FixedFontHeight := IniFile.ReadInteger(IDName, 'fixedfontheight', 14);
FixedFontStyle := ReadFontStyles(IniFile, IDName, 'fixedfontstyle');
FixedFontColor := IniFile.ReadInteger(IDName, 'fixedfontcolor', 0);
end;
procedure TspDataSkinGridControl.SaveToFile(IniFile: TCustomIniFile);
begin
inherited;
WriteRect(IniFile, IDName, 'fixedcellrect', FixedCellRect);
WriteRect(IniFile, IDName, 'selectcellrect', SelectCellRect);
WriteRect(IniFile, IDName, 'focuscellrect', FocusCellRect);
//
IniFile.WriteInteger(IDName, 'fixedcellleftoffset', FixedCellLeftOffset);
IniFile.WriteInteger(IDName, 'fixedcellrightoffset', FixedCellRightOffset);
WriteRect(IniFile, IDName, 'fixedcelltextrect', FixedCellTextRect);
//
IniFile.WriteInteger(IDName, 'cellleftoffset', CellLeftOffset);
IniFile.WriteInteger(IDName, 'cellrightoffset', CellRightOffset);
WriteRect(IniFile, IDName, 'celltextrect', CellTextRect);
//
IniFile.WriteInteger(IDName, 'linescolor', LinesColor);
IniFile.WriteInteger(IDName, 'bgcolor', BGColor);
IniFile.WriteInteger(IDName, 'bgpictureindex', BGPictureIndex);
IniFile.WriteString(IDName, 'fontname', FontName);
IniFile.WriteInteger(IDName, 'fontheight', FontHeight);
WriteFontStyles(IniFile, IDName, 'fontstyle', FontStyle);
IniFile.WriteInteger(IDName, 'fontcolor', FontColor);
IniFile.WriteInteger(IDName, 'selectfontcolor', SelectFontColor);
IniFile.WriteInteger(IDName, 'focusfontcolor', FocusFontColor);
//
IniFile.WriteString(IDName, 'fixedfontname', FixedFontName);
IniFile.WriteInteger(IDName, 'fixedfontheight', FixedFontHeight);
WriteFontStyles(IniFile, IDName, 'fixedfontstyle', FixedFontStyle);
IniFile.WriteInteger(IDName, 'fixedfontcolor', FixedFontColor);
end;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -