Re: [Lazarus] Setting TStringGrid row/col border styles
On 25/03/2014 01:44, Gary Randall wrote: Thanks Howard. I did as you suggested. I also did some more searching and found the Lazarus Component Library help file (lcl.chm) which gives me the component spec's I was looking for. You may have noticed the link to those official LCL docs at the top of the wiki page I mentioned earlier... IIRC, there's a quite helpful how to article in the LCL docs as well which I think the wiki article links to directly... -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Setting TStringGrid row/col border styles
Thank you for your help Reinier and Howard. Let me give you some background. I'm evaluating Lazarus/FPC to convert a large Excel engineering scheduling VBA program (16K lines of code x 3 similar modules) to Pascal. I developed it in VBA for a friend because Excel's formatting and shape controls made it easy to prototype the look and feel he wanted. Unfortunately, we can't use Excel to distribute it commercially because of it's lack of security and the need to revise it to run under constantly changing MS Office. The program is stable in 32 bit and we'd like to have it run on other platforms. Besides that, I really loved Delphi when I used it years ago and have converted one engineering program with Lazarus already. Our program does not need spreadsheet calculation capability since almost all data is entered directly, or pasted from form and shape controls. From what I see so far, Lazarus will let me do everything once I learn the finer details of existing controls and relearn how to build components. On the stringgrid, I should have said that I specifically need to change SOME cell's attributes, such as cell borders, and I think it will need to use DrawGrid. I have read everything I can find find, such as the grid reference you recommended, but this old brain has the remnants of too many languages in it to sort it out quickly. It's gotten too used to IDEs that step you through object properties, events, etc.. From what I've read in the archives, the standard procedure is to go to the Lazarus source code and track down undocumented parameter and type requirements. I hope I'm missing some documentation. I intend to pursue the Lazarus solution and would be glad to do what engineers do - tabulate my findings. If someone can tell me how to post a .png image to the forum I can show you the stringgrid format I need. It's not complicated, but I need to duplicate what we've created. Any help is appreciated and I will reciprocate any way I can. Gary -- View this message in context: http://free-pascal-lazarus.989080.n3.nabble.com/Setting-TStringGrid-row-col-border-styles-tp4036389p4036405.html Sent from the Free Pascal - Lazarus mailing list archive at Nabble.com. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Setting TStringGrid row/col border styles
On 24/03/2014 18:19, Gary Randall wrote: If someone can tell me how to post a .png image to the forum I can show you the stringgrid format I need. Once logged in, go to the appropriate forum board (say Lazarus General) and click the [New Topic] button. As well as filling in the subject field and content edit box you'll see an [+ Attachments and other options] link below the edit box. That brings up a dialog which lets you locate a file somewhere on your disk to add to the new topic as an attachment. Howard -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Setting TStringGrid row/col border styles
Thanks Howard. I did as you suggested. I also did some more searching and found the Lazarus Component Library help file (lcl.chm) which gives me the component spec's I was looking for. Gary -- View this message in context: http://free-pascal-lazarus.989080.n3.nabble.com/Setting-TStringGrid-row-col-border-styles-tp4036389p4036407.html Sent from the Free Pascal - Lazarus mailing list archive at Nabble.com. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Setting TStringGrid row/col border styles
On 22/03/2014 22:04, Howard Page-Clark wrote: On 22/03/2014 20:53, Gary Randall wrote: may be all you need, without custom drawing. Apart from Howard's suggestion you'll find a lot of info on Lazarus on the wiki - in this case http://wiki.lazarus.freepascal.org/Grids_Reference_Page -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
[Lazarus] Setting TStringGrid row/col border styles
I'm new to Lazarus/FPC but had a lot of Delphi experience over 20 years ago. I'm baffled finding help for customizing stringgrid to use different row/col border styles, etc.. I understand that I need to use the OnPrepareCanvas and OnDrawCell events and have made some minor progress setting custom row heights and grid colors but I don't seem to be able to find help on the various object properties that I need. I do see the popups for object properties in the source editor, but then I can't find anything on parameters, etc.. Any suggestions about finding help and recommendations on properties would be appreciated. Specifically, I need to change the penstyle and weight of row/col borders. -- View this message in context: http://free-pascal-lazarus.989080.n3.nabble.com/Setting-TStringGrid-row-col-border-styles-tp4036389.html Sent from the Free Pascal - Lazarus mailing list archive at Nabble.com. -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
Re: [Lazarus] Setting TStringGrid row/col border styles
On 22/03/2014 20:53, Gary Randall wrote: ... Specifically, I need to change the penstyle and weight of row/col borders. The public properties: GridLineColor GridLineStyle and published property GridLineWidth may be all you need, without custom drawing. Howard -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus