1 Attachment(s)
How to customize horizontal header (diagonal header view)
I have a requirement in my project viz. the horizontal header data has to be displayed diagonally. Can any one please let me know, how to do this customization?
What I tried was,
Subclassed the QHeaderView and reimplementing the paintSection.
I can draw skewed / angled lines. But there are no grippers for that line to move the header. How to acheive this?
I could not place the text properly in each header column. How do I acheive this?
Can any one help me with a sample code for this?
Re: How to customize horizontal header (diagonal header view)
You will probably need to handle all the events yourself - mainly mouse events.
Re: How to customize horizontal header (diagonal header view)
Quote:
Originally Posted by
wysota
You will probably need to handle all the events yourself - mainly mouse events.
Somehow I could acheive the angled lines in the horizontal header. But when I move the mouse over the header, the angled lines are getting wiped off and it is not happening for the text in the header section. How should I fix this? What we need to handle in the mouse move events? Can I have a example or some snippet of code?
And how to make the horizontal header sections, clickable? (The vertical header sections are behaving like push buttons and it is not happening for the customized Horizontal header view). How to acheive this?
Re: How to customize horizontal header (diagonal header view)
Re: How to customize horizontal header (diagonal header view)
No set clickable didn't work.