Lines Matching refs:pDrawable

86 getDrawableDamageRef(DrawablePtr pDrawable)
90 if (WindowDrawable(pDrawable->type)) {
91 ScreenPtr pScreen = pDrawable->pScreen;
96 && ((WindowPtr) pDrawable)->viewable
99 pPixmap = (*pScreen->GetWindowPixmap) ((WindowPtr) pDrawable);
108 pPixmap = (PixmapPtr) pDrawable;
112 #define getDrawableDamage(pDrawable) (*getDrawableDamageRef (pDrawable))
115 #define drawableDamage(pDrawable) \
116 DamagePtr pDamage = getDrawableDamage(pDrawable)
126 _damageRegionAppend(DrawablePtr pDrawable, RegionPtr pRegion, Bool clip,
131 damageRegionAppend(DrawablePtr pDrawable, RegionPtr pRegion, Bool clip,
135 ScreenPtr pScreen = pDrawable->pScreen;
138 drawableDamage(pDrawable);
159 if (pDrawable->type != DRAWABLE_WINDOW) {
160 screen_x = ((PixmapPtr) pDrawable)->screen_x - pDrawable->x;
161 screen_y = ((PixmapPtr) pDrawable)->screen_y - pDrawable->y;
167 if (pDrawable->type == DRAWABLE_WINDOW &&
168 ((WindowPtr) (pDrawable))->backingStore == NotUseful) {
171 &((WindowPtr) (pDrawable))->clipList);
175 NotClippedByChildren((WindowPtr) (pDrawable));
197 if (pDamage->pDrawable->type == DRAWABLE_WINDOW &&
198 !((WindowPtr) (pDamage->pDrawable))->realized) {
202 draw_x = pDamage->pDrawable->x;
203 draw_y = pDamage->pDrawable->y;
209 if (!WindowDrawable(pDamage->pDrawable->type)) {
210 draw_x += ((PixmapPtr) pDamage->pDrawable)->screen_x;
211 draw_y += ((PixmapPtr) pDamage->pDrawable)->screen_y;
220 if (clip || pDamage->pDrawable != pDrawable) {
222 if (pDamage->pDrawable->type == DRAWABLE_WINDOW) {
224 &((WindowPtr) (pDamage->pDrawable))->
232 box.x2 = draw_x + pDamage->pDrawable->width;
233 box.y2 = draw_y + pDamage->pDrawable->height;
250 pDrawable->id, pDamage->pDrawable->id));
286 damageRegionProcessPending(DrawablePtr pDrawable)
288 drawableDamage(pDrawable);
309 _damageDamageBox(DrawablePtr pDrawable, BoxPtr pBox, int subWindowMode,
313 damageDamageBox(DrawablePtr pDrawable, BoxPtr pBox, int subWindowMode)
320 _damageRegionAppend(pDrawable, &region, TRUE, subWindowMode, where);
322 damageRegionAppend(pDrawable, &region, TRUE, subWindowMode);
362 #define DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable) \
368 #define DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable) \
382 damageValidateGC(GCPtr pGC, unsigned long changes, DrawablePtr pDrawable)
385 (*pGC->funcs->ValidateGC) (pGC, changes, pDrawable);
446 #define TRANSLATE_BOX(box, pDrawable) { \
447 box.x1 += pDrawable->x; \
448 box.x2 += pDrawable->x; \
449 box.y1 += pDrawable->y; \
450 box.y2 += pDrawable->y; \
453 #define TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC) { \
454 TRANSLATE_BOX(box, pDrawable); \
473 #define checkPictureDamage(p) (getDrawableDamage(p->pDrawable) && \
487 ScreenPtr pScreen = pDst->pDrawable->pScreen;
495 box.x1 = xDst + pDst->pDrawable->x;
496 box.y1 = yDst + pDst->pDrawable->y;
501 damageDamageBox(pDst->pDrawable, &box, pDst->subWindowMode);
508 if (pSrc->pDrawable && WindowDrawable(pSrc->pDrawable->type))
510 if (pMask && pMask->pDrawable && WindowDrawable(pMask->pDrawable->type))
518 damageRegionProcessPending(pDst->pDrawable);
530 ScreenPtr pScreen = pDst->pDrawable->pScreen;
549 x = pDst->pDrawable->x;
550 y = pDst->pDrawable->y;
576 damageDamageBox(pDst->pDrawable, &box, pDst->subWindowMode);
580 damageRegionProcessPending(pDst->pDrawable);
588 ScreenPtr pScreen = pPicture->pDrawable->pScreen;
603 x = pPicture->pDrawable->x + x_off;
604 y = pPicture->pDrawable->y + y_off;
624 damageDamageBox(pPicture->pDrawable, &box, pPicture->subWindowMode);
628 damageRegionProcessPending(pPicture->pDrawable);
635 damageFillSpans(DrawablePtr pDrawable,
638 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
640 if (npt && checkGCDamage(pDrawable, pGC)) {
666 TRANSLATE_BOX(box, pDrawable);
671 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
674 (*pGC->ops->FillSpans) (pDrawable, pGC, npt, ppt, pwidth, fSorted);
676 damageRegionProcessPending(pDrawable);
677 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
681 damageSetSpans(DrawablePtr pDrawable,
686 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
688 if (npt && checkGCDamage(pDrawable, pGC)) {
714 TRANSLATE_BOX(box, pDrawable);
719 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
721 (*pGC->ops->SetSpans) (pDrawable, pGC, pcharsrc, ppt, pwidth, npt, fSorted);
722 damageRegionProcessPending(pDrawable);
723 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
727 damagePutImage(DrawablePtr pDrawable,
733 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
734 if (checkGCDamage(pDrawable, pGC)) {
737 box.x1 = x + pDrawable->x;
739 box.y1 = y + pDrawable->y;
744 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
746 (*pGC->ops->PutImage) (pDrawable, pGC, depth, x, y, w, h,
748 damageRegionProcessPending(pDrawable);
749 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
817 damagePolyPoint(DrawablePtr pDrawable,
820 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
822 if (npt && checkGCDamage(pDrawable, pGC)) {
867 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
869 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
871 (*pGC->ops->PolyPoint) (pDrawable, pGC, mode, npt, ppt);
872 damageRegionProcessPending(pDrawable);
873 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
877 damagePolylines(DrawablePtr pDrawable,
880 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
882 if (npt && checkGCDamage(pDrawable, pGC)) {
940 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
942 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
944 (*pGC->ops->Polylines) (pDrawable, pGC, mode, npt, ppt);
945 damageRegionProcessPending(pDrawable);
946 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
950 damagePolySegment(DrawablePtr pDrawable, GCPtr pGC, int nSeg, xSegment * pSeg)
952 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
954 if (nSeg && checkGCDamage(pDrawable, pGC)) {
1019 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1021 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1023 (*pGC->ops->PolySegment) (pDrawable, pGC, nSeg, pSeg);
1024 damageRegionProcessPending(pDrawable);
1025 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1029 damagePolyRectangle(DrawablePtr pDrawable,
1032 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1034 if (nRects && checkGCDamage(pDrawable, pGC)) {
1051 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1053 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1059 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1061 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1067 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1069 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1075 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1077 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1082 (*pGC->ops->PolyRectangle) (pDrawable, pGC, nRects, pRects);
1083 damageRegionProcessPending(pDrawable);
1084 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1088 damagePolyArc(DrawablePtr pDrawable, GCPtr pGC, int nArcs, xArc * pArcs)
1090 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1092 if (nArcs && checkGCDamage(pDrawable, pGC)) {
1125 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1127 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1129 (*pGC->ops->PolyArc) (pDrawable, pGC, nArcs, pArcs);
1130 damageRegionProcessPending(pDrawable);
1131 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1135 damageFillPolygon(DrawablePtr pDrawable,
1138 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1140 if (npt > 2 && checkGCDamage(pDrawable, pGC)) {
1183 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1185 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1188 (*pGC->ops->FillPolygon) (pDrawable, pGC, shape, mode, npt, ppt);
1189 damageRegionProcessPending(pDrawable);
1190 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1194 damagePolyFillRect(DrawablePtr pDrawable,
1197 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1198 if (nRects && checkGCDamage(pDrawable, pGC)) {
1220 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1222 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1224 (*pGC->ops->PolyFillRect) (pDrawable, pGC, nRects, pRects);
1225 damageRegionProcessPending(pDrawable);
1226 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1230 damagePolyFillArc(DrawablePtr pDrawable, GCPtr pGC, int nArcs, xArc * pArcs)
1232 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1234 if (nArcs && checkGCDamage(pDrawable, pGC)) {
1256 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC);
1258 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1260 (*pGC->ops->PolyFillArc) (pDrawable, pGC, nArcs, pArcs);
1261 damageRegionProcessPending(pDrawable);
1262 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1271 damageDamageChars(DrawablePtr pDrawable,
1298 damageDamageBox(pDrawable, &box, subWindowMode);
1310 damageText(DrawablePtr pDrawable,
1324 if (!checkGCDamage(pDrawable, pGC))
1336 damageDamageChars(pDrawable, pGC->font, x + pDrawable->x,
1337 y + pDrawable->y, n, charinfo, imageblt,
1344 damagePolyText8(DrawablePtr pDrawable,
1347 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1348 damageText(pDrawable, pGC, x, y, (unsigned long) count, chars, Linear8Bit,
1350 x = (*pGC->ops->PolyText8) (pDrawable, pGC, x, y, count, chars);
1351 damageRegionProcessPending(pDrawable);
1352 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1357 damagePolyText16(DrawablePtr pDrawable,
1360 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1361 damageText(pDrawable, pGC, x, y, (unsigned long) count, (char *) chars,
1364 x = (*pGC->ops->PolyText16) (pDrawable, pGC, x, y, count, chars);
1365 damageRegionProcessPending(pDrawable);
1366 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1371 damageImageText8(DrawablePtr pDrawable,
1374 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1375 damageText(pDrawable, pGC, x, y, (unsigned long) count, chars, Linear8Bit,
1377 (*pGC->ops->ImageText8) (pDrawable, pGC, x, y, count, chars);
1378 damageRegionProcessPending(pDrawable);
1379 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1383 damageImageText16(DrawablePtr pDrawable,
1386 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1387 damageText(pDrawable, pGC, x, y, (unsigned long) count, (char *) chars,
1390 (*pGC->ops->ImageText16) (pDrawable, pGC, x, y, count, chars);
1391 damageRegionProcessPending(pDrawable);
1392 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1396 damageImageGlyphBlt(DrawablePtr pDrawable,
1402 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1403 damageDamageChars(pDrawable, pGC->font, x + pDrawable->x, y + pDrawable->y,
1405 (*pGC->ops->ImageGlyphBlt) (pDrawable, pGC, x, y, nglyph, ppci, pglyphBase);
1406 damageRegionProcessPending(pDrawable);
1407 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1411 damagePolyGlyphBlt(DrawablePtr pDrawable,
1417 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1418 damageDamageChars(pDrawable, pGC->font, x + pDrawable->x, y + pDrawable->y,
1420 (*pGC->ops->PolyGlyphBlt) (pDrawable, pGC, x, y, nglyph, ppci, pglyphBase);
1421 damageRegionProcessPending(pDrawable);
1422 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1428 DrawablePtr pDrawable, int dx, int dy, int xOrg, int yOrg)
1430 DAMAGE_GC_OP_PROLOGUE(pGC, pDrawable);
1431 if (checkGCDamage(pDrawable, pGC)) {
1438 box.x1 += pDrawable->x;
1439 box.y1 += pDrawable->y;
1447 damageDamageBox(pDrawable, &box, pGC->subWindowMode);
1449 (*pGC->ops->PushPixels) (pGC, pBitMap, pDrawable, dx, dy, xOrg, yOrg);
1450 damageRegionProcessPending(pDrawable);
1451 DAMAGE_GC_OP_EPILOGUE(pGC, pDrawable);
1633 miDamageRegister(DrawablePtr pDrawable, DamagePtr pDamage)
1635 if (pDrawable->type == DRAWABLE_WINDOW)
1636 TraverseTree((WindowPtr)pDrawable, damageRegisterVisit, NULL);
1638 pDrawable->serialNumber = NEXT_SERIAL_NUMBER;
1642 miDamageUnregister(DrawablePtr pDrawable, DamagePtr pDamage)
1644 if (pDrawable->type == DRAWABLE_WINDOW)
1645 TraverseTree((WindowPtr)pDrawable, damageRegisterVisit, NULL);
1647 pDrawable->serialNumber = NEXT_SERIAL_NUMBER;
1731 pDamage->pDrawable = 0;
1744 DamageRegister(DrawablePtr pDrawable, DamagePtr pDamage)
1746 ScreenPtr pScreen = pDrawable->pScreen;
1751 if (pDrawable->pScreen != pDamage->pScreen) {
1757 if (pDrawable->type == DRAWABLE_WINDOW) {
1758 WindowPtr pWindow = (WindowPtr) pDrawable;
1777 pDamage->pDrawable = pDrawable;
1778 damageInsertDamage(getDrawableDamageRef(pDrawable), pDamage);
1779 (*pScrPriv->funcs.Register) (pDrawable, pDamage);
1793 DrawablePtr pDrawable = pDamage->pDrawable;
1794 ScreenPtr pScreen = pDrawable->pScreen;
1798 (*pScrPriv->funcs.Unregister) (pDrawable, pDamage);
1800 if (pDrawable->type == DRAWABLE_WINDOW) {
1801 WindowPtr pWindow = (WindowPtr) pDrawable;
1825 pDamage->pDrawable = 0;
1826 damageRemoveDamage(getDrawableDamageRef(pDrawable), pDamage);
1836 if (pDamage->pDrawable)
1852 DrawablePtr pDrawable = pDamage->pDrawable;
1855 if (pDrawable) {
1856 if (pDrawable->type == DRAWABLE_WINDOW)
1857 pClip = &((WindowPtr) pDrawable)->borderClip;
1861 box.x1 = pDrawable->x;
1862 box.y1 = pDrawable->y;
1863 box.x2 = pDrawable->x + pDrawable->width;
1864 box.y2 = pDrawable->y + pDrawable->height;
1868 RegionTranslate(&pDamage->damage, pDrawable->x, pDrawable->y);
1870 RegionTranslate(&pDamage->damage, -pDrawable->x, -pDrawable->y);
1871 if (pDrawable->type != DRAWABLE_WINDOW)
1896 DamageRegionAppend(DrawablePtr pDrawable, RegionPtr pRegion)
1898 damageRegionAppend(pDrawable, pRegion, FALSE, -1);
1902 DamageRegionProcessPending(DrawablePtr pDrawable)
1904 damageRegionProcessPending(pDrawable);
1909 DamageDamageRegion(DrawablePtr pDrawable, RegionPtr pRegion)
1911 damageRegionAppend(pDrawable, pRegion, FALSE, -1);
1917 damageRegionProcessPending(pDrawable);