1. 相对位置:每个Qwidget都能通过pos()获取到相对自己父类窗口的位置, 2. 绝对位置:pWidget->mapToGlobal(QPoint(0,0)) ;将当前控件的相对位置转换 … Continue reading Qt 相对位置,绝对位置之间的转换(maptoglobal,mapfromglobal)
1. 相对位置:每个Qwidget都能通过pos()获取到相对自己父类窗口的位置, 2. 绝对位置:pWidget->mapToGlobal(QPoint(0,0)) ;将当前控件的相对位置转换 … Continue reading Qt 相对位置,绝对位置之间的转换(maptoglobal,mapfromglobal)