Results 1 to 2 of 2

Thread: QCalendarWidget - height rows

  1. #1
    Join Date
    Apr 2010
    Posts
    2

    Default QCalendarWidget - height rows

    hi
    i am trying to set row height in QCalendarWidget
    example. i want to have 3rd week of month size bigger than other. any ideas ... how can it be done ?

  2. #2
    Join Date
    Apr 2010
    Posts
    2

    Default Re: QCalendarWidget - height rows

    i try this code:


    Qt Code:
    1. QCalendarWidgetMy(QWidget *parent=0) : QCalendarWidget (parent)
    2. {
    3.  
    4. view2 = qFindChild<QTableView *>(this);
    5.  
    6. }
    7.  
    8. mycalendar = new QCalendarWidgetMy(this);
    9. mycalendar->view2->resizeColumnsToContents();
    10.  
    11. mycalendar->view2->verticalHeader()->setDefaultSectionSize(51);
    12. //mycalendar->view2->setShowGrid(true); // works
    13.  
    14.  
    15. mycalendar->view2->setRowHeight ( 2, 51 );
    To copy to clipboard, switch view to plain text mode 



    but this not working
    Last edited by pease; 15th April 2010 at 17:55.

Similar Threads

  1. Set height of QTableView to fit exact number of rows.
    By Ben.Hines in forum Qt Programming
    Replies: 3
    Last Post: 17th January 2019, 01:49
  2. QTableView How to change height for all rows?
    By sergey_85 in forum Qt Programming
    Replies: 2
    Last Post: 1st December 2009, 19:49
  3. How can I add a QCalendarWidget to a QToolBar?
    By cydside in forum Qt Programming
    Replies: 1
    Last Post: 10th April 2009, 23:06
  4. about QCalendarWidget
    By nifei in forum Qt Programming
    Replies: 2
    Last Post: 9th February 2009, 09:17
  5. How to set rows of QtableWidget to the same height?
    By sawerset in forum Qt Programming
    Replies: 3
    Last Post: 7th December 2008, 18:09

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.