Recent

Author Topic: TStringgrid à la HTML-Table  (Read 3850 times)

WimVan

  • Jr. Member
  • **
  • Posts: 85
TStringgrid à la HTML-Table
« on: May 18, 2017, 08:20:17 pm »
Hello,
As an old TurboPascal programmer and even Delphi (2...5)-programmer I made several little tools for me.
And then, I stopped because Delphi suddenly changed their components and Paradox was dammed. I went to Perl and PHP ...
I made a kind of book-index (http://www.fotospotter.be/shoot) and now I would make it in Lazarus. (Discovered some weeks ago).
Question 1:
Can I design the data to the grid such I did in HTML (see URL).  I merge some cells in one cell (Column 1) row
Question 2:
Can I  show a jpg-image in this 'merged' cell.
Question 3:
Text is shown in cells but the text is wrapped on several lines.

Some help would be wonderful, but before I risk my life, I want to be sure it can be done.
Thanks

tk

  • Sr. Member
  • ****
  • Posts: 361
Re: TStringgrid à la HTML-Table
« Reply #1 on: May 18, 2017, 09:22:40 pm »
With KControls you can make such tables both in KGrid or in KMemo table, whichever suits you better.
None of those support import or export from/to HTML though.
You will find KControls on my web site.

WimVan

  • Jr. Member
  • **
  • Posts: 85
Re: TStringgrid à la HTML-Table
« Reply #2 on: May 18, 2017, 09:31:15 pm »
I looked to your components and tried it.  But nowhere I see a way to show an image jpg-type in een merged cell.
And how to obtain a wrapped text in a cell ?
I did not request to have an export from/to HTML. I gave the URL to see how I did it in HTML.  Now I would like having a programm that can run on a PC, win10, or IOS or Linux without the need of internetserver, ..

tk

  • Sr. Member
  • ****
  • Posts: 361
Re: TStringgrid à la HTML-Table
« Reply #3 on: May 18, 2017, 09:44:04 pm »
nowhere I see a way to show an image jpg-type in een merged cell.
And how to obtain a wrapped text in a cell ?

Both features are present and possible.
Just merge a cell and draw jpg image inside.
Wrapped text is also possible.
Both principles are shown in the demos, you just need to play with it a little bit more to get desired results.

WimVan

  • Jr. Member
  • **
  • Posts: 85
Re: TStringgrid à la HTML-Table
« Reply #4 on: May 18, 2017, 10:37:24 pm »
OK, but will it be usable for linux and Ios (Apple) too ? And which download do you advice ? there is V 1.7 and one on bitbucket.

Phil

  • Hero Member
  • *****
  • Posts: 2737
Re: TStringgrid à la HTML-Table
« Reply #5 on: May 18, 2017, 11:03:53 pm »
OK, but will it be usable for linux and Ios (Apple) too ? And which download do you advice ? there is V 1.7 and one on bitbucket.

Do you mean macOS? That should be possible with with KControls, but no Lazarus control can be used with iOS (iPad, iPhone, iPod touch).


WimVan

  • Jr. Member
  • **
  • Posts: 85
Re: TStringgrid à la HTML-Table
« Reply #6 on: May 19, 2017, 06:39:02 pm »
So, I looked to kgrid and finally I solved question 1 and 3
But, when looking to all examples I can't find how to show a jpg in a cell. Anyone an idea ?
What have I to write in the ondrawcell-event ?
Thanks

 

TinyPortal © 2005-2018