[Qt-interest] vertical QHeaderView clipping - revisited
Efan Harris
efanharris at gmail.com
Fri Dec 12 22:25:28 CET 2008
Oh looks like I mis understood your issue,
Do you want your vertical header should be expanded as per the labels size?
If yes then it will work just use
> horizontalHeader()->setResizeMode(QHeaderView::ResizeToContents);
verticalHeader()->setResizeMode(QHeaderView::ResizeToContents);
By the way which Qt version are you working on?
On Fri, Dec 12, 2008 at 11:42 AM, Paul Miller <paul at fxtech.com> wrote:
> Efan Harris wrote:
> > Oops I told you wrong one, This will do
> >
> > horizontalHeader()->setResizeMode(QHeaderView::ResizeToContents);
>
> No, that doesn't work either. The vertical header is not a column of the
> horizontal header, so is unaffected.
>
> >
> > On Fri, Dec 12, 2008 at 10:48 AM, Paul Miller <paul at fxtech.com
> > <mailto:paul at fxtech.com>> wrote:
> >
> > Efan Harris wrote:
> > > Hi,
> > > Did you try resizecolumnToContents() ??
> >
> > Yes, it doesn't work. Headers aren't technically columns, so those
> > functions don't really affect it anyway.
> >
> > >
> > > Efan
> > > On Fri, Dec 12, 2008 at 9:44 AM, Paul Miller <paul at fxtech.com
> > <mailto:paul at fxtech.com>
> > > <mailto:paul at fxtech.com <mailto:paul at fxtech.com>>> wrote:
> > >
> > > I found this thread from almost 3 years ago:
> > >
> > >
> http://lists.trolltech.com/qt-interest/2006-02/thread00317-0.html
> > >
> > > I'm using Qt 4.4 and am experiencing the exact same problem.
> > My vertical
> > > header (for a QTableView) will not resize itself horizontally
> > when I
> > > change the labels. When I first display the table, if I have
> > "Some Text"
> > > in header for the first row, then programmatically change it
> > to "Some
> > > Bigger Text", it will end up displayed as "Some Bigg". And
> > there doesn't
> > > seem to be a function I can call to re-layout the header
> > manually.
> > >
> > > Obviously, this is not acceptable. Is there any way to work
> > around this?
> > >
> > >
> > > --
> > > Paul Miller | paul at fxtech.com <mailto:paul at fxtech.com>
> > <mailto:paul at fxtech.com <mailto:paul at fxtech.com>> |
> > > www.fxtech.com <http://www.fxtech.com>
> > <http://www.fxtech.com> | Got Tivo?
> > >
> > > _______________________________________________
> > > Qt-interest mailing list
> > > Qt-interest at trolltech.com <mailto:Qt-interest at trolltech.com>
> > <mailto:Qt-interest at trolltech.com <mailto:Qt-interest at trolltech.com
> >>
> > > http://lists.trolltech.com/mailman/listinfo/qt-interest
> > >
> > >
> >
> >
> > --
> > Paul Miller | paul at fxtech.com <mailto:paul at fxtech.com> |
> > www.fxtech.com <http://www.fxtech.com> | Got Tivo?
> >
> > _______________________________________________
> > Qt-interest mailing list
> > Qt-interest at trolltech.com <mailto:Qt-interest at trolltech.com>
> > http://lists.trolltech.com/mailman/listinfo/qt-interest
> >
> >
>
>
> --
> Paul Miller | paul at fxtech.com | www.fxtech.com | Got Tivo?
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20081212/9e48ad79/attachment.html
More information about the Qt-interest-old
mailing list