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
|
||||
VpAlarmClock32.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;
|
||||
Label5: TLabel;
|
||||
Label6: TLabel;
|
||||
Label7: TLabel;
|
||||
lblIcons8: TLabel;
|
||||
lblLazForumLink: TLabel;
|
||||
lblIcons8Link: TLabel;
|
||||
lblLazPortLink: TLabel;
|
||||
ImagePanel: TPanel;
|
||||
Image1: TImage;
|
||||
lblLazPortLink1: TLabel;
|
||||
lblRolandHahnLink: TLabel;
|
||||
Panel1: TPanel;
|
||||
TextPanel: TPanel;
|
||||
SupportPanel: TPanel;
|
||||
@ -72,19 +75,24 @@ type
|
||||
ProgramName: TLabel;
|
||||
GeneralNewsgroupsLabel: TLabel;
|
||||
lblTurboLink: TLabel;
|
||||
lblHelp: TLabel;
|
||||
lblHelpLink: TLabel;
|
||||
CopyrightLabel: TLabel;
|
||||
OKButton: TButton;
|
||||
lblGeneralDiscussion: TLabel;
|
||||
lblGeneralDiscussionLink: TLabel;
|
||||
Label2: TLabel;
|
||||
Label3: TLabel;
|
||||
Label1: TLabel;
|
||||
procedure FormActivate(Sender: TObject);
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure FormDestroy(Sender: TObject);
|
||||
procedure lblLinkMouseEnter(Sender: TObject);
|
||||
procedure lblLinkMouseLeave(Sender: TObject);
|
||||
procedure lblLinkClick(Sender: TObject);
|
||||
private
|
||||
{ Private declarations }
|
||||
{$IFDEF LCL}
|
||||
FLogo: TBitmap;
|
||||
{$ENDIF}
|
||||
procedure PositionControls;
|
||||
public
|
||||
{ Public declarations }
|
||||
@ -101,18 +109,22 @@ implementation
|
||||
{$ENDIF}
|
||||
|
||||
uses
|
||||
{$IFNDEF LCL}
|
||||
{$IFDEF LCL}
|
||||
GraphUtil,
|
||||
{$ELSe}
|
||||
ShellAPI,
|
||||
{$ENDIF}
|
||||
VpConst, VpMisc, VpSR;
|
||||
|
||||
const
|
||||
TURBO_LINK_URL = 'http://sourceforge.net/projects/tpvplanit/';
|
||||
HELP_URL = 'http://sourceforge.net/forum/forum.php?forum_id=241880';
|
||||
{%H-}NEWS_SPECIFIC_URL = 'news://news.turbopower.com/turbopower.public.support.visualplanit';
|
||||
GENERAL_DISCUSSION_URL = 'http://sourceforge.net/forum/forum.php?forum_id=241879';
|
||||
LAZARUS_PORT_URL = 'http://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/components/tvplanit';
|
||||
LAZARUS_FORUM_URL = 'http://forum.lazarus.freepascal.org';
|
||||
TURBO_LINK_URL = 'https://sourceforge.net/projects/tpvplanit/';
|
||||
HELP_URL = 'https://sourceforge.net/forum/forum.php?forum_id=241880';
|
||||
// NEWS_SPECIFIC_URL = 'news://news.turbopower.com/turbopower.public.support.visualplanit';
|
||||
GENERAL_DISCUSSION_URL = 'https://sourceforge.net/forum/forum.php?forum_id=241879';
|
||||
LAZARUS_PORT_URL = 'https://sourceforge.net/p/lazarus-ccr/svn/HEAD/tree/components/tvplanit';
|
||||
LAZARUS_FORUM_URL = 'https://forum.lazarus.freepascal.org';
|
||||
ROLAND_HAHN_URL = 'https://www.rhsoft.de';
|
||||
ICONS8_URL = 'https://icons8.com';
|
||||
|
||||
|
||||
{ FrmAbout }
|
||||
@ -126,6 +138,8 @@ const
|
||||
{$ENDIF}
|
||||
var
|
||||
Year, Junk: Word;
|
||||
bmp: TBitmap;
|
||||
w, h: Integer;
|
||||
begin
|
||||
ProgramName.Caption := VpProductName + ' ' + VpVersionStr;
|
||||
DecodeDate(Now, Year, junk, junk);
|
||||
@ -134,13 +148,42 @@ begin
|
||||
LineEnding + 'All rights reserved.',
|
||||
[COPYRIGHT, Year]);
|
||||
|
||||
lblTurboLink.Cursor := crHandPoint;
|
||||
lblHelp.Cursor := crHandPoint;
|
||||
lblGeneralDiscussion.Cursor := crHandPoint;
|
||||
lblLazPortLink.Cursor := crHandPoint;
|
||||
lblLazForumLink.Cursor := crHandpoint;
|
||||
|
||||
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;
|
||||
|
||||
procedure TfrmAbout.lblLinkMouseEnter(Sender: TObject);
|
||||
@ -155,13 +198,17 @@ end;
|
||||
|
||||
procedure TfrmAbout.lblLinkClick(Sender: TObject);
|
||||
var
|
||||
lbl: TLabel;
|
||||
url: String;
|
||||
begin
|
||||
lbl := TLabel(Sender);
|
||||
url := lbl.Caption;
|
||||
(*
|
||||
// if Sender = lblNewsSpecific then url := NEWS_SPECIFIC_URL else
|
||||
if Sender = lblHelp then
|
||||
if Sender = lblHelpLink then
|
||||
url := HELP_URL
|
||||
else
|
||||
if Sender = lblGeneralDiscussion then
|
||||
if Sender = lblGeneralDiscussionLink then
|
||||
url := GENERAL_DISCUSSION_URL
|
||||
else
|
||||
if Sender = lblTurboLink then
|
||||
@ -172,8 +219,15 @@ begin
|
||||
else
|
||||
if Sender = lblLazForumLink then
|
||||
url := LAZARUS_FORUM_URL
|
||||
else
|
||||
if Sender = lblRolandHahnLink then
|
||||
url := ROLAND_HAHN_URL
|
||||
else
|
||||
if Sender = lblIcons8Link then
|
||||
url := ICONS8_URL
|
||||
else
|
||||
exit;
|
||||
*)
|
||||
{$IFDEF LCL}
|
||||
if not OpenUrl(url)
|
||||
{$ELSE}
|
||||
|
Binary file not shown.
@ -48,7 +48,7 @@ uses
|
||||
|
||||
const
|
||||
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';
|
||||
|
||||
BorderStyles: array[TBorderStyle] of LongInt = (0, WS_BORDER);
|
||||
|
Reference in New Issue
Block a user