Hello,
I wonder. "Width" of QWidget is in what resolution?
I mean:
ui::QWidget::width()
To copy to clipboard, switch view to plain text mode
It will return value in what units?
I have code that dinamically draws (by QPainter) QPointF (many of them).
And for my horizontal coordinate I have that code:
for(int i=1; i<something; i++)
{
point.setX(i);
}
QPointF point;
for(int i=1; i<something; i++)
{
point.setX(i);
}
To copy to clipboard, switch view to plain text mode
And my aim is to use "something" as a resolution. So for example: no matter how big is "something", my points always fill evenly for example 30% of my widget. But that doesn't work:
ui::QWidget::width() * 0.3
To copy to clipboard, switch view to plain text mode
Because QPointF is in different units than widget width.
Bookmarks