You've already forked lazarus-ccr
tvplanit: Improved scaling of logo in About box.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8488 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -1,3 +1,5 @@
|
|||||||
|
../../logo/logo.png
|
||||||
|
|
||||||
VpAlarmClock24.png
|
VpAlarmClock24.png
|
||||||
VpAlarmClock32.png
|
VpAlarmClock32.png
|
||||||
VpAlarmClock48.png
|
VpAlarmClock48.png
|
||||||
|
BIN
components/tvplanit/images/logo/logo.png
Normal file
BIN
components/tvplanit/images/logo/logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 14 KiB |
File diff suppressed because it is too large
Load Diff
@ -60,11 +60,14 @@ type
|
|||||||
Label4: TLabel;
|
Label4: TLabel;
|
||||||
Label5: TLabel;
|
Label5: TLabel;
|
||||||
Label6: TLabel;
|
Label6: TLabel;
|
||||||
|
Label7: TLabel;
|
||||||
|
lblIcons8: TLabel;
|
||||||
lblLazForumLink: TLabel;
|
lblLazForumLink: TLabel;
|
||||||
|
lblIcons8Link: TLabel;
|
||||||
lblLazPortLink: TLabel;
|
lblLazPortLink: TLabel;
|
||||||
ImagePanel: TPanel;
|
ImagePanel: TPanel;
|
||||||
Image1: TImage;
|
Image1: TImage;
|
||||||
lblLazPortLink1: TLabel;
|
lblRolandHahnLink: TLabel;
|
||||||
Panel1: TPanel;
|
Panel1: TPanel;
|
||||||
TextPanel: TPanel;
|
TextPanel: TPanel;
|
||||||
SupportPanel: TPanel;
|
SupportPanel: TPanel;
|
||||||
@ -72,19 +75,24 @@ type
|
|||||||
ProgramName: TLabel;
|
ProgramName: TLabel;
|
||||||
GeneralNewsgroupsLabel: TLabel;
|
GeneralNewsgroupsLabel: TLabel;
|
||||||
lblTurboLink: TLabel;
|
lblTurboLink: TLabel;
|
||||||
lblHelp: TLabel;
|
lblHelpLink: TLabel;
|
||||||
CopyrightLabel: TLabel;
|
CopyrightLabel: TLabel;
|
||||||
OKButton: TButton;
|
OKButton: TButton;
|
||||||
lblGeneralDiscussion: TLabel;
|
lblGeneralDiscussionLink: TLabel;
|
||||||
Label2: TLabel;
|
Label2: TLabel;
|
||||||
Label3: TLabel;
|
Label3: TLabel;
|
||||||
Label1: TLabel;
|
Label1: TLabel;
|
||||||
procedure FormActivate(Sender: TObject);
|
procedure FormActivate(Sender: TObject);
|
||||||
|
procedure FormCreate(Sender: TObject);
|
||||||
|
procedure FormDestroy(Sender: TObject);
|
||||||
procedure lblLinkMouseEnter(Sender: TObject);
|
procedure lblLinkMouseEnter(Sender: TObject);
|
||||||
procedure lblLinkMouseLeave(Sender: TObject);
|
procedure lblLinkMouseLeave(Sender: TObject);
|
||||||
procedure lblLinkClick(Sender: TObject);
|
procedure lblLinkClick(Sender: TObject);
|
||||||
private
|
private
|
||||||
{ Private declarations }
|
{ Private declarations }
|
||||||
|
{$IFDEF LCL}
|
||||||
|
FLogo: TBitmap;
|
||||||
|
{$ENDIF}
|
||||||
procedure PositionControls;
|
procedure PositionControls;
|
||||||
public
|
public
|
||||||
{ Public declarations }
|
{ Public declarations }
|
||||||
@ -101,18 +109,22 @@ implementation
|
|||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
{$IFNDEF LCL}
|
{$IFDEF LCL}
|
||||||
|
GraphUtil,
|
||||||
|
{$ELSe}
|
||||||
ShellAPI,
|
ShellAPI,
|
||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
VpConst, VpMisc, VpSR;
|
VpConst, VpMisc, VpSR;
|
||||||
|
|
||||||
const
|
const
|
||||||
TURBO_LINK_URL = 'http://sourceforge.net/projects/tpvplanit/';
|
TURBO_LINK_URL = 'https://sourceforge.net/projects/tpvplanit/';
|
||||||
HELP_URL = 'http://sourceforge.net/forum/forum.php?forum_id=241880';
|
HELP_URL = 'https://sourceforge.net/forum/forum.php?forum_id=241880';
|
||||||
{%H-}NEWS_SPECIFIC_URL = 'news://news.turbopower.com/turbopower.public.support.visualplanit';
|
// NEWS_SPECIFIC_URL = 'news://news.turbopower.com/turbopower.public.support.visualplanit';
|
||||||
GENERAL_DISCUSSION_URL = 'http://sourceforge.net/forum/forum.php?forum_id=241879';
|
GENERAL_DISCUSSION_URL = 'https://sourceforge.net/forum/forum.php?forum_id=241879';
|
||||||
LAZARUS_PORT_URL = 'http://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/components/tvplanit';
|
LAZARUS_PORT_URL = 'https://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/components/tvplanit';
|
||||||
LAZARUS_FORUM_URL = 'http://forum.lazarus.freepascal.org';
|
LAZARUS_FORUM_URL = 'https://forum.lazarus.freepascal.org';
|
||||||
|
ROLAND_HAHN_URL = 'https://www.rhsoft.de';
|
||||||
|
ICONS8_URL = 'https://icons8.com';
|
||||||
|
|
||||||
|
|
||||||
{ FrmAbout }
|
{ FrmAbout }
|
||||||
@ -126,6 +138,8 @@ const
|
|||||||
{$ENDIF}
|
{$ENDIF}
|
||||||
var
|
var
|
||||||
Year, Junk: Word;
|
Year, Junk: Word;
|
||||||
|
bmp: TBitmap;
|
||||||
|
w, h: Integer;
|
||||||
begin
|
begin
|
||||||
ProgramName.Caption := VpProductName + ' ' + VpVersionStr;
|
ProgramName.Caption := VpProductName + ' ' + VpVersionStr;
|
||||||
DecodeDate(Now, Year, junk, junk);
|
DecodeDate(Now, Year, junk, junk);
|
||||||
@ -134,13 +148,42 @@ begin
|
|||||||
LineEnding + 'All rights reserved.',
|
LineEnding + 'All rights reserved.',
|
||||||
[COPYRIGHT, Year]);
|
[COPYRIGHT, Year]);
|
||||||
|
|
||||||
lblTurboLink.Cursor := crHandPoint;
|
|
||||||
lblHelp.Cursor := crHandPoint;
|
|
||||||
lblGeneralDiscussion.Cursor := crHandPoint;
|
|
||||||
lblLazPortLink.Cursor := crHandPoint;
|
|
||||||
lblLazForumLink.Cursor := crHandpoint;
|
|
||||||
|
|
||||||
PositionControls;
|
PositionControls;
|
||||||
|
|
||||||
|
h := ImagePanel.Height;
|
||||||
|
w := FLogo.Width * h div FLogo.Height;
|
||||||
|
bmp := TBitmap.Create;
|
||||||
|
try
|
||||||
|
bmp.SetSize(w, h);
|
||||||
|
{$IFDEF LCL}
|
||||||
|
AntiAliasedStretchDrawBitmap(FLogo, bmp, w, h);
|
||||||
|
{$ELSE}
|
||||||
|
bmp.Canvas.StretchDraw(Rect(0, 0, bmp.Width,bmp.Height), FLogo);
|
||||||
|
{$ENDIF}
|
||||||
|
Image1.Picture.Bitmap.Assign(bmp);
|
||||||
|
finally
|
||||||
|
bmp.Free;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmAbout.FormCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
FLogo := TBitmap.Create;
|
||||||
|
LoadGlyphFromRCDATA(FLogo, 'LOGO');
|
||||||
|
|
||||||
|
lblTurboLink.Caption := TURBO_LINK_URL;
|
||||||
|
lblLazPortLink.Caption := LAZARUS_PORT_URL;
|
||||||
|
lblHelpLink.Caption := HELP_URL;
|
||||||
|
lblGeneralDiscussionLink.Caption := GENERAL_DISCUSSION_URL;
|
||||||
|
|
||||||
|
lblLazForumLink.Caption := LAZARUS_FORUM_URL;
|
||||||
|
lblRolandHahnLink.Caption := ROLAND_HAHN_URL;
|
||||||
|
lblIcons8Link.Caption := ICONS8_URL;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TfrmAbout.FormDestroy(Sender: TObject);
|
||||||
|
begin
|
||||||
|
FLogo.Free;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrmAbout.lblLinkMouseEnter(Sender: TObject);
|
procedure TfrmAbout.lblLinkMouseEnter(Sender: TObject);
|
||||||
@ -155,13 +198,17 @@ end;
|
|||||||
|
|
||||||
procedure TfrmAbout.lblLinkClick(Sender: TObject);
|
procedure TfrmAbout.lblLinkClick(Sender: TObject);
|
||||||
var
|
var
|
||||||
|
lbl: TLabel;
|
||||||
url: String;
|
url: String;
|
||||||
begin
|
begin
|
||||||
|
lbl := TLabel(Sender);
|
||||||
|
url := lbl.Caption;
|
||||||
|
(*
|
||||||
// if Sender = lblNewsSpecific then url := NEWS_SPECIFIC_URL else
|
// if Sender = lblNewsSpecific then url := NEWS_SPECIFIC_URL else
|
||||||
if Sender = lblHelp then
|
if Sender = lblHelpLink then
|
||||||
url := HELP_URL
|
url := HELP_URL
|
||||||
else
|
else
|
||||||
if Sender = lblGeneralDiscussion then
|
if Sender = lblGeneralDiscussionLink then
|
||||||
url := GENERAL_DISCUSSION_URL
|
url := GENERAL_DISCUSSION_URL
|
||||||
else
|
else
|
||||||
if Sender = lblTurboLink then
|
if Sender = lblTurboLink then
|
||||||
@ -172,8 +219,15 @@ begin
|
|||||||
else
|
else
|
||||||
if Sender = lblLazForumLink then
|
if Sender = lblLazForumLink then
|
||||||
url := LAZARUS_FORUM_URL
|
url := LAZARUS_FORUM_URL
|
||||||
|
else
|
||||||
|
if Sender = lblRolandHahnLink then
|
||||||
|
url := ROLAND_HAHN_URL
|
||||||
|
else
|
||||||
|
if Sender = lblIcons8Link then
|
||||||
|
url := ICONS8_URL
|
||||||
else
|
else
|
||||||
exit;
|
exit;
|
||||||
|
*)
|
||||||
{$IFDEF LCL}
|
{$IFDEF LCL}
|
||||||
if not OpenUrl(url)
|
if not OpenUrl(url)
|
||||||
{$ELSE}
|
{$ELSE}
|
||||||
|
Binary file not shown.
@ -48,7 +48,7 @@ uses
|
|||||||
|
|
||||||
const
|
const
|
||||||
BuildTime = {$I %DATE%} + {$I %TIME}; //'09/13/2002 09:25 AM';
|
BuildTime = {$I %DATE%} + {$I %TIME}; //'09/13/2002 09:25 AM';
|
||||||
VpVersionStr = 'v1.12'; {Visual PlanIt library version}
|
VpVersionStr = 'v1.0.7'; {Visual PlanIt library version}
|
||||||
VpProductName = 'Visual PlanIt';
|
VpProductName = 'Visual PlanIt';
|
||||||
|
|
||||||
BorderStyles: array[TBorderStyle] of LongInt = (0, WS_BORDER);
|
BorderStyles: array[TBorderStyle] of LongInt = (0, WS_BORDER);
|
||||||
|
Reference in New Issue
Block a user