• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            posts - 319, comments - 22, trackbacks - 0, articles - 11
              C++博客 :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理

            PyQt 抓圖和截圖操作

            Posted on 2011-04-29 22:56 RTY 閱讀(1496) 評論(0)  編輯 收藏 引用 所屬分類: QtPython
            1. 示例代碼
            self.originalPixmap = QtGui.QPixmap.grabWindow(QtGui.QApplication.desktop().winId())

            2.關于QPixmap類的grabWIndow

            QPixmap QPixmap::grabWindow ( WId window, int x = 0, int y = 0, int width = -1, int height = -1 ) [static]

            Creates and returns a pixmap constructed by grabbing the contents of the given window restricted by QRect(x, y, width, height).

            The arguments (x, y) specify the offset in the window, whereas (width, height) specify the area to be copied. If width is negative, the function copies everything to the right border of the window. If height is negative, the function copies everything to the bottom of the window.

            The window system identifier (WId) can be retrieved using the QWidget::winId() function. The rationale for using a window identifier and not a QWidget, is to enable grabbing of windows that are not part of the application, window system frames, and so on.

            The grabWindow() function grabs pixels from the screen, not from the window, i.e. if there is another window partially or entirely over the one you grab, you get pixels from the overlying window, too. The mouse cursor is generally not grabbed.

            Note on X11 that if the given window doesn't have the same depth as the root window, and another window partially or entirely obscures the one you grab, you will not get pixels from the overlying window. The contents of the obscured areas in the pixmap will be undefined and uninitialized.

            On Windows Vista and above grabbing a layered window, which is created by setting the Qt::WA_TranslucentBackground attribute, will not work. Instead grabbing the desktop widget should work.

            Warning: In general, grabbing an area outside the screen is not safe. This depends on the underlying window system.

            久久婷婷色综合一区二区| 狠狠色婷婷久久综合频道日韩| 97久久精品午夜一区二区| 久久国产AVJUST麻豆| 久久夜色精品国产噜噜亚洲AV| 热RE99久久精品国产66热| 久久乐国产综合亚洲精品| 亚洲欧美精品伊人久久| 久久久中文字幕| 天天综合久久一二三区| www.久久99| 国产A三级久久精品| 狠狠人妻久久久久久综合蜜桃| 久久久久国产| 青青草原综合久久大伊人导航| 久久精品国产日本波多野结衣| 亚洲精品高清国产一久久| 一本色道久久HEZYO无码| 久久久噜噜噜久久中文字幕色伊伊| 久久亚洲AV成人无码电影| 久久精品国产色蜜蜜麻豆| 日韩电影久久久被窝网| 久久精品人妻一区二区三区| 成人资源影音先锋久久资源网| 亚洲AV无码久久精品狠狠爱浪潮| 久久99精品久久久久久噜噜 | 91久久精一区二区三区大全| 伊人久久大香线蕉综合网站| 久久中文字幕无码专区| 国产亚洲成人久久| 久久99久久无码毛片一区二区| 久久综合狠狠综合久久激情 | 一本伊大人香蕉久久网手机| 粉嫩小泬无遮挡久久久久久| 97久久国产亚洲精品超碰热| 99久久免费国产特黄| 九九99精品久久久久久| 青青青国产成人久久111网站| 国产精品久久久久一区二区三区 | 国产精品久久久99| 亚洲国产日韩欧美综合久久|