icon inside a gridview cell

Post

Posted
Rating:
#1 (In Topic #917)
Enthusiast
gambafeliz is in the usergroup ‘Enthusiast’
 Is it possible to load an icon into a GridView cell?

Otherwise, how would they do something like that?

For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Online now: No Back to the top

Post

Posted
Rating:
#2
Guru
BruceSteers is in the usergroup ‘Guru’
Sure…

Code (gambas)

  1. GridView1[0,0].Picture = Picture["/my/pic.png"]
  2.  

/comp/gb.qt4/_gridview_cell/picture - Gambas Documentation
Online now: No Back to the top

Post

Posted
Rating:
#3
Enthusiast
gambafeliz is in the usergroup ‘Enthusiast’
 Perfect, thank you very much.

And it occurs to you, how to stretch the image of the cell? or do I have to fit the image to the cell space?

For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Online now: No Back to the top

Post

Posted
Rating:
#4
Guru
BruceSteers is in the usergroup ‘Guru’

Code (gambas)

  1.  
  2. GridView1[0, 0].Picture = Picture["/my/pic.png"].Image.Stretch(64, 64).Picture
  3.  
  4. ' resize grid cell to fit picture
  5. GridView1.Rows[0].Height = -1
  6. GridView1.Columns[0].Width = -1
  7.  
  8.  
Online now: No Back to the top

Post

Posted
Rating:
#5
Enthusiast
gambafeliz is in the usergroup ‘Enthusiast’
 Thank you Mr. You leave me amazed. +10

For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Online now: No Back to the top
1 guest and 0 members have just viewed this.