Difference between revisions of "Poweredby"
From Lazarus wiki
Jump to navigationJump to searchMinesadorada (talk | contribs) m (Updated download link to Lazarus CCR SVN page) |
(Putting external components inside your Lazarus directory is NOT a good idea as you cannot delete lazarus and reinstall. Better to have an external 3rd party directory with components. Regardless, this is a user decision and not install requirement) |
||
Line 19: | Line 19: | ||
===Install=== | ===Install=== | ||
− | #Make a new folder 'poweredby' | + | #Make a new folder 'poweredby' |
#Unzip the archive into the folder | #Unzip the archive into the folder | ||
#In the Lazarus IDE choose 'Open' poweredby.lpk | #In the Lazarus IDE choose 'Open' poweredby.lpk | ||
Line 25: | Line 25: | ||
#Click Compile | #Click Compile | ||
#Click Use/Install | #Click Use/Install | ||
− | #When asked 'would you like to compile | + | #When asked 'would you like to compile Lazarus?'m answer 'yes' |
#After Lazarus has restarted, check the 'Additional' component tab/palette for the new 'poweredby' component | #After Lazarus has restarted, check the 'Additional' component tab/palette for the new 'poweredby' component | ||
Revision as of 11:11, 5 August 2014
TPoweredBy component
by minesadorada@charcodelvalle.com
Windows graphic
Linux/MacOS graphic
Other logos and banners
Summary
- A visual component (installed on the 'Additional' tab) that fades in above shaped graphic image for 1 second (or in Linux/MacOS displays it for 1 second)
- Drop into your form.create() event
Download
Download from the lazarus CCR here
Install
- Make a new folder 'poweredby'
- Unzip the archive into the folder
- In the Lazarus IDE choose 'Open' poweredby.lpk
- When asked 'Open as a project' answer 'yes'
- Click Compile
- Click Use/Install
- When asked 'would you like to compile Lazarus?'m answer 'yes'
- After Lazarus has restarted, check the 'Additional' component tab/palette for the new 'poweredby' component
Use
- Start a new project application
- Drop a 'poweredby' component onto the form
- Double-click the empty form to show the TForm1.Create method
- Add poweredby1.showpoweredbyform
- Run the application
That's it!
Other uses
The PoweredBy component lends itself well to adding as a subcomponent to an existing custom component:
Uses uPoweredBy, Propedits, ..other units
Type
TMyComponent = Class(TComponent)
private
fPoweredBy:TPoweredBy;
..other stuff
public
procedure ShowPoweredByLogo; // Call fPoweredBy.ShowPoweredByForm method in this proc.
..other stuff
published
property PoweredBy:TPoweredBy read fPoweredBy write fPoweredBy;
..other stuff
end;
procedure Register;
RegisterPropertyEditor(TypeInfo(TPoweredBy),
TMyComponent, 'PoweredBy', TClassPropertyEditor);
Constructor TMyComponent.Create()
// Use tPoweredBy as a subcomponent
// Register a TClassPropertyEditor in order to display it correctly
fPoweredBy := TPoweredBy.Create(Self);
fPoweredBy.SetSubComponent(true); // Tell the IDE to store the modified properties
fPoweredBy.Name:='PoweredBy';
License
LGPL license
Platform
Windows
- PoweredBy will fade-in a shaped graphic
Linux
- PoweredBy will display a square graphic
- This is due to the inability of GTK widgetset to deal with transparent shaped screens
Mac OS X
- PoweredBy displays a square graphic, similar to the Linux version.
Tested
Windows 7 32/64-bit Laz v1.x fpc 2.6.x Linux 32-bit Laz v0.9.x fpc 2.2.x
Version
V1.0.1.2
Support
Email the author with any queries