MultiLine Grid Header
Moderator: Rathinagiri
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
MultiLine Grid Header
As we know, this is not possible in our actual grid control.
Then reading at little bit more at: Multi-line (merged) datagridview header I saw this that it could interesting to be read:
Difference between datagridview and listview control
Whos knows this could let us to reach another proper results ? It could ?
Then reading at little bit more at: Multi-line (merged) datagridview header I saw this that it could interesting to be read:
Difference between datagridview and listview control
Whos knows this could let us to reach another proper results ? It could ?
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: MultiLine Grid Header
DataGridView is from Windows Forms (.Net) and not Win32 API.
I think it requires fundamental changes to HMG library.
I think it requires fundamental changes to HMG library.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
MultiLine Grid Header
Yes, I think so...
Thank you Rathi for your reply
Thank you Rathi for your reply
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
- serge_girard
- Posts: 3166
- Joined: Sun Nov 25, 2012 2:44 pm
- DBs Used: 1 MySQL - MariaDB
2 DBF - Location: Belgium
- Contact:
Re: MultiLine Grid Header
Nice idea Pablo, now I use labels to simulate this effect.
It works actually very fine, labelfont, color etc. is, of course, no problem.
You only have to keep them together..
Serge
It works actually very fine, labelfont, color etc. is, of course, no problem.
You only have to keep them together..
Serge
There's nothing you can do that can't be done...
- Rathinagiri
- Posts: 5471
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: MultiLine Grid Header
Serge,
Can you show me how?
Can you show me how?
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
MultiLine Grid Header
There is something of curious in this demo (based on ..\SAMPLES\Controls\Grid\GRID_18).
I just over-wrote the 02.bmp file with larger size it simulates two lines.
When run the builded demo, enlarged image can diffusely be displayed. But when we go to first menu option (Change Column 1 Header Image) displays litle better but in column 1 and two.
The big question (most probably Claudio can gives his opinion & tip): Height of grid header, did not changed...
If we could control the height of the header by the size of the image, it would be more interesting to use HEADERIMAGES.
I just over-wrote the 02.bmp file with larger size it simulates two lines.
When run the builded demo, enlarged image can diffusely be displayed. But when we go to first menu option (Change Column 1 Header Image) displays litle better but in column 1 and two.
The big question (most probably Claudio can gives his opinion & tip): Height of grid header, did not changed...
If we could control the height of the header by the size of the image, it would be more interesting to use HEADERIMAGES.
- Attachments
-
- GRID_18.rar
- (2.24 KiB) Downloaded 243 times
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
- serge_girard
- Posts: 3166
- Joined: Sun Nov 25, 2012 2:44 pm
- DBs Used: 1 MySQL - MariaDB
2 DBF - Location: Belgium
- Contact:
Re: MultiLine Grid Header
Rathi, This is very simple and basic:
just put a LABEL at (for example) 10,10 and your GRID at 30,10 then. It's a bit dirty.
Then do the same for each column in the grid!
Serge
just put a LABEL at (for example) 10,10 and your GRID at 30,10 then. It's a bit dirty.
Then do the same for each column in the grid!
Serge
There's nothing you can do that can't be done...
mol
My minigrid sample can be used for small number of rows. It uses labels so every cell can have different font, color etc.
One of limitations is that user can't change width of column.
One of limitations is that user can't change width of column.
- Pablo César
- Posts: 4059
- Joined: Wed Sep 08, 2010 1:18 pm
- Location: Curitiba - Brasil
mol
Hi Marek, of course you can. By LISTVIEW_SETCOLUMNWIDTH C function.mol wrote:One of limitations is that user can't change width of column.
You will find examples at:
viewtopic.php?p=38572#p38572
viewtopic.php?p=36639#p36639
viewtopic.php?p=17016#p17016
And at HMGDoc:
- New Set Properties:
<ParentWindowName>.<GridControlName>.ColumnHEADER ( nColIndex ) := cColumnHeader
<ParentWindowName>.<GridControlName>.ColumnWIDTH ( nColIndex ) := [ nColumnWidth ] |
[ GRID_WIDTH_AUTOSIZE ] |
[ GRID_WIDTH_AUTOSIZEHEADER ]
HMGing a better world
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
"Matter tells space how to curve, space tells matter how to move."
Albert Einstein
Re: MultiLine Grid Header
I was writing about my minigrid based on labels