Recent

Author Topic: How to add an image to form???  (Read 11135 times)

JoshM

  • Jr. Member
  • **
  • Posts: 57
How to add an image to form???
« on: December 25, 2012, 06:35:52 pm »
Can someone give me a REALLY basic set of instructions? Thanks  :)

Blaazen

  • Hero Member
  • *****
  • Posts: 3237
  • POKE 54296,15
    • Eye-Candy Controls
Re: How to add an image to form???
« Reply #1 on: December 25, 2012, 06:50:39 pm »
Hi,
Start new project, go to "Additional palette, select TImage and click on a Form.
Click on the Picture property in Object Inspector (click on the small button on the right) and Load Image Dialog will appear. Click "Load" select some image from your disk and click OK. That's all.
Lazarus 2.3.0 (rev main-2_3-2863...) FPC 3.3.1 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

Try Eye-Candy Controls: https://sourceforge.net/projects/eccontrols/files/

wjackson153

  • Sr. Member
  • ****
  • Posts: 267
Re: How to add an image to form???
« Reply #2 on: December 25, 2012, 07:12:20 pm »
As Blaazen stated add Timage to your form

to add picture from source you could do

 image1.Picture.LoadFromFile('/home/technet/demo.jpg');   // Assumes Linux path
 image1.Picture.LoadFromFile('c:\demo.jpg');   // Assumes Windows path

Lazarus 1.1 r39490 CT FPC 2.7.1 i386-linux KDE
Linux Mint 14 KDE 4

JoshM

  • Jr. Member
  • **
  • Posts: 57
Re: How to add an image to form???
« Reply #3 on: December 26, 2012, 02:01:57 pm »
Hi,
Start new project, go to "Additional palette, select TImage and click on a Form.
Click on the Picture property in Object Inspector (click on the small button on the right) and Load Image Dialog will appear. Click "Load" select some image from your disk and click OK. That's all.

Thanks Blaazen. I remember you answered my other question (about how to add tabs). To add a tab I have to right click on the tab bar...I kept trying to right click on the TImage. Now I realise it's in the properties panel. Thanks :)

 

TinyPortal © 2005-2018