Lines Matching full:box

228                 BoxRec box;  in _damageRegionAppend()  local
230 box.x1 = draw_x; in _damageRegionAppend()
231 box.y1 = draw_y; in _damageRegionAppend()
232 box.x2 = draw_x + pDamage->pDrawable->width; in _damageRegionAppend()
233 box.y2 = draw_y + pDamage->pDrawable->height; in _damageRegionAppend()
234 RegionInit(&pixClip, &box, 1); in _damageRegionAppend()
438 #define TRIM_BOX(box, pGC) if (pGC->pCompositeClip) { \ argument
440 if(box.x1 < extents->x1) box.x1 = extents->x1; \
441 if(box.x2 > extents->x2) box.x2 = extents->x2; \
442 if(box.y1 < extents->y1) box.y1 = extents->y1; \
443 if(box.y2 > extents->y2) box.y2 = extents->y2; \
446 #define TRANSLATE_BOX(box, pDrawable) { \ argument
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) { \ argument
454 TRANSLATE_BOX(box, pDrawable); \
455 TRIM_BOX(box, pGC); \
458 #define BOX_NOT_EMPTY(box) \ argument
459 (((box.x2 - box.x1) > 0) && ((box.y2 - box.y1) > 0))
465 #define TRIM_PICTURE_BOX(box, pDst) { \ argument
467 if(box.x1 < extents->x1) box.x1 = extents->x1; \
468 if(box.x2 > extents->x2) box.x2 = extents->x2; \
469 if(box.y1 < extents->y1) box.y1 = extents->y1; \
470 if(box.y2 > extents->y2) box.y2 = extents->y2; \
493 BoxRec box; in damageComposite() local
495 box.x1 = xDst + pDst->pDrawable->x; in damageComposite()
496 box.y1 = yDst + pDst->pDrawable->y; in damageComposite()
497 box.x2 = box.x1 + width; in damageComposite()
498 box.y2 = box.y1 + height; in damageComposite()
499 TRIM_PICTURE_BOX(box, pDst); in damageComposite()
500 if (BOX_NOT_EMPTY(box)) in damageComposite()
501 damageDamageBox(pDst->pDrawable, &box, pDst->subWindowMode); in damageComposite()
542 BoxRec box; in damageGlyphs() local
545 box.x1 = 32767; in damageGlyphs()
546 box.y1 = 32767; in damageGlyphs()
547 box.x2 = -32767; in damageGlyphs()
548 box.y2 = -32767; in damageGlyphs()
561 if (x1 < box.x1) in damageGlyphs()
562 box.x1 = x1; in damageGlyphs()
563 if (y1 < box.y1) in damageGlyphs()
564 box.y1 = y1; in damageGlyphs()
565 if (x2 > box.x2) in damageGlyphs()
566 box.x2 = x2; in damageGlyphs()
567 if (y2 > box.y2) in damageGlyphs()
568 box.y2 = y2; in damageGlyphs()
574 TRIM_PICTURE_BOX(box, pDst); in damageGlyphs()
575 if (BOX_NOT_EMPTY(box)) in damageGlyphs()
576 damageDamageBox(pDst->pDrawable, &box, pDst->subWindowMode); in damageGlyphs()
594 BoxRec box; in damageAddTraps() local
599 box.x1 = 32767; in damageAddTraps()
600 box.y1 = 32767; in damageAddTraps()
601 box.x2 = -32767; in damageAddTraps()
602 box.y2 = -32767; in damageAddTraps()
613 if (x1 < box.x1) in damageAddTraps()
614 box.x1 = x1; in damageAddTraps()
615 if (x2 > box.x2) in damageAddTraps()
616 box.x2 = x2; in damageAddTraps()
617 if (y1 < box.y1) in damageAddTraps()
618 box.y1 = y1; in damageAddTraps()
619 if (y2 > box.y2) in damageAddTraps()
620 box.y2 = y2; in damageAddTraps()
622 TRIM_PICTURE_BOX(box, pPicture); in damageAddTraps()
623 if (BOX_NOT_EMPTY(box)) in damageAddTraps()
624 damageDamageBox(pPicture->pDrawable, &box, pPicture->subWindowMode); in damageAddTraps()
644 BoxRec box; in damageFillSpans() local
646 box.x1 = pptTmp->x; in damageFillSpans()
647 box.x2 = box.x1 + *pwidthTmp; in damageFillSpans()
648 box.y2 = box.y1 = pptTmp->y; in damageFillSpans()
653 if (box.x1 > pptTmp->x) in damageFillSpans()
654 box.x1 = pptTmp->x; in damageFillSpans()
655 if (box.x2 < (pptTmp->x + *pwidthTmp)) in damageFillSpans()
656 box.x2 = pptTmp->x + *pwidthTmp; in damageFillSpans()
657 if (box.y1 > pptTmp->y) in damageFillSpans()
658 box.y1 = pptTmp->y; in damageFillSpans()
659 else if (box.y2 < pptTmp->y) in damageFillSpans()
660 box.y2 = pptTmp->y; in damageFillSpans()
663 box.y2++; in damageFillSpans()
666 TRANSLATE_BOX(box, pDrawable); in damageFillSpans()
668 TRIM_BOX(box, pGC); in damageFillSpans()
670 if (BOX_NOT_EMPTY(box)) in damageFillSpans()
671 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damageFillSpans()
692 BoxRec box; in damageSetSpans() local
694 box.x1 = pptTmp->x; in damageSetSpans()
695 box.x2 = box.x1 + *pwidthTmp; in damageSetSpans()
696 box.y2 = box.y1 = pptTmp->y; in damageSetSpans()
701 if (box.x1 > pptTmp->x) in damageSetSpans()
702 box.x1 = pptTmp->x; in damageSetSpans()
703 if (box.x2 < (pptTmp->x + *pwidthTmp)) in damageSetSpans()
704 box.x2 = pptTmp->x + *pwidthTmp; in damageSetSpans()
705 if (box.y1 > pptTmp->y) in damageSetSpans()
706 box.y1 = pptTmp->y; in damageSetSpans()
707 else if (box.y2 < pptTmp->y) in damageSetSpans()
708 box.y2 = pptTmp->y; in damageSetSpans()
711 box.y2++; in damageSetSpans()
714 TRANSLATE_BOX(box, pDrawable); in damageSetSpans()
716 TRIM_BOX(box, pGC); in damageSetSpans()
718 if (BOX_NOT_EMPTY(box)) in damageSetSpans()
719 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damageSetSpans()
735 BoxRec box; in damagePutImage() local
737 box.x1 = x + pDrawable->x; in damagePutImage()
738 box.x2 = box.x1 + w; in damagePutImage()
739 box.y1 = y + pDrawable->y; in damagePutImage()
740 box.y2 = box.y1 + h; in damagePutImage()
742 TRIM_BOX(box, pGC); in damagePutImage()
743 if (BOX_NOT_EMPTY(box)) in damagePutImage()
744 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePutImage()
763 BoxRec box; in damageCopyArea() local
765 box.x1 = dstx + pDst->x; in damageCopyArea()
766 box.x2 = box.x1 + width; in damageCopyArea()
767 box.y1 = dsty + pDst->y; in damageCopyArea()
768 box.y2 = box.y1 + height; in damageCopyArea()
770 TRIM_BOX(box, pGC); in damageCopyArea()
771 if (BOX_NOT_EMPTY(box)) in damageCopyArea()
772 damageDamageBox(pDst, &box, pGC->subWindowMode); in damageCopyArea()
796 BoxRec box; in damageCopyPlane() local
798 box.x1 = dstx + pDst->x; in damageCopyPlane()
799 box.x2 = box.x1 + width; in damageCopyPlane()
800 box.y1 = dsty + pDst->y; in damageCopyPlane()
801 box.y2 = box.y1 + height; in damageCopyPlane()
803 TRIM_BOX(box, pGC); in damageCopyPlane()
804 if (BOX_NOT_EMPTY(box)) in damageCopyPlane()
805 damageDamageBox(pDst, &box, pGC->subWindowMode); in damageCopyPlane()
823 BoxRec box; in damagePolyPoint() local
827 box.x2 = box.x1 = pptTmp->x; in damagePolyPoint()
828 box.y2 = box.y1 = pptTmp->y; in damagePolyPoint()
833 int x = box.x1; in damagePolyPoint()
834 int y = box.y1; in damagePolyPoint()
840 if (box.x1 > x) in damagePolyPoint()
841 box.x1 = x; in damagePolyPoint()
842 else if (box.x2 < x) in damagePolyPoint()
843 box.x2 = x; in damagePolyPoint()
844 if (box.y1 > y) in damagePolyPoint()
845 box.y1 = y; in damagePolyPoint()
846 else if (box.y2 < y) in damagePolyPoint()
847 box.y2 = y; in damagePolyPoint()
853 if (box.x1 > pptTmp->x) in damagePolyPoint()
854 box.x1 = pptTmp->x; in damagePolyPoint()
855 else if (box.x2 < pptTmp->x) in damagePolyPoint()
856 box.x2 = pptTmp->x; in damagePolyPoint()
857 if (box.y1 > pptTmp->y) in damagePolyPoint()
858 box.y1 = pptTmp->y; in damagePolyPoint()
859 else if (box.y2 < pptTmp->y) in damagePolyPoint()
860 box.y2 = pptTmp->y; in damagePolyPoint()
864 box.x2++; in damagePolyPoint()
865 box.y2++; in damagePolyPoint()
867 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyPoint()
868 if (BOX_NOT_EMPTY(box)) in damagePolyPoint()
869 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyPoint()
885 BoxRec box; in damagePolylines() local
888 box.x2 = box.x1 = pptTmp->x; in damagePolylines()
889 box.y2 = box.y1 = pptTmp->y; in damagePolylines()
899 int x = box.x1; in damagePolylines()
900 int y = box.y1; in damagePolylines()
906 if (box.x1 > x) in damagePolylines()
907 box.x1 = x; in damagePolylines()
908 else if (box.x2 < x) in damagePolylines()
909 box.x2 = x; in damagePolylines()
910 if (box.y1 > y) in damagePolylines()
911 box.y1 = y; in damagePolylines()
912 else if (box.y2 < y) in damagePolylines()
913 box.y2 = y; in damagePolylines()
919 if (box.x1 > pptTmp->x) in damagePolylines()
920 box.x1 = pptTmp->x; in damagePolylines()
921 else if (box.x2 < pptTmp->x) in damagePolylines()
922 box.x2 = pptTmp->x; in damagePolylines()
923 if (box.y1 > pptTmp->y) in damagePolylines()
924 box.y1 = pptTmp->y; in damagePolylines()
925 else if (box.y2 < pptTmp->y) in damagePolylines()
926 box.y2 = pptTmp->y; in damagePolylines()
930 box.x2++; in damagePolylines()
931 box.y2++; in damagePolylines()
934 box.x1 -= extra; in damagePolylines()
935 box.x2 += extra; in damagePolylines()
936 box.y1 -= extra; in damagePolylines()
937 box.y2 += extra; in damagePolylines()
940 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolylines()
941 if (BOX_NOT_EMPTY(box)) in damagePolylines()
942 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolylines()
955 BoxRec box; in damagePolySegment() local
964 box.x1 = pSegTmp->x1; in damagePolySegment()
965 box.x2 = pSegTmp->x2; in damagePolySegment()
968 box.x2 = pSegTmp->x1; in damagePolySegment()
969 box.x1 = pSegTmp->x2; in damagePolySegment()
973 box.y1 = pSegTmp->y1; in damagePolySegment()
974 box.y2 = pSegTmp->y2; in damagePolySegment()
977 box.y2 = pSegTmp->y1; in damagePolySegment()
978 box.y1 = pSegTmp->y2; in damagePolySegment()
984 if (pSegTmp->x1 < box.x1) in damagePolySegment()
985 box.x1 = pSegTmp->x1; in damagePolySegment()
986 if (pSegTmp->x2 > box.x2) in damagePolySegment()
987 box.x2 = pSegTmp->x2; in damagePolySegment()
990 if (pSegTmp->x2 < box.x1) in damagePolySegment()
991 box.x1 = pSegTmp->x2; in damagePolySegment()
992 if (pSegTmp->x1 > box.x2) in damagePolySegment()
993 box.x2 = pSegTmp->x1; in damagePolySegment()
996 if (pSegTmp->y1 < box.y1) in damagePolySegment()
997 box.y1 = pSegTmp->y1; in damagePolySegment()
998 if (pSegTmp->y2 > box.y2) in damagePolySegment()
999 box.y2 = pSegTmp->y2; in damagePolySegment()
1002 if (pSegTmp->y2 < box.y1) in damagePolySegment()
1003 box.y1 = pSegTmp->y2; in damagePolySegment()
1004 if (pSegTmp->y1 > box.y2) in damagePolySegment()
1005 box.y2 = pSegTmp->y1; in damagePolySegment()
1009 box.x2++; in damagePolySegment()
1010 box.y2++; in damagePolySegment()
1013 box.x1 -= extra; in damagePolySegment()
1014 box.x2 += extra; in damagePolySegment()
1015 box.y1 -= extra; in damagePolySegment()
1016 box.y2 += extra; in damagePolySegment()
1019 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolySegment()
1020 if (BOX_NOT_EMPTY(box)) in damagePolySegment()
1021 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolySegment()
1035 BoxRec box; in damagePolyRectangle() local
1047 box.x1 = pRectsTmp->x - offset1; in damagePolyRectangle()
1048 box.y1 = pRectsTmp->y - offset1; in damagePolyRectangle()
1049 box.x2 = box.x1 + pRectsTmp->width + offset2; in damagePolyRectangle()
1050 box.y2 = box.y1 + offset2; in damagePolyRectangle()
1051 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyRectangle()
1052 if (BOX_NOT_EMPTY(box)) in damagePolyRectangle()
1053 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyRectangle()
1055 box.x1 = pRectsTmp->x - offset1; in damagePolyRectangle()
1056 box.y1 = pRectsTmp->y + offset3; in damagePolyRectangle()
1057 box.x2 = box.x1 + offset2; in damagePolyRectangle()
1058 box.y2 = box.y1 + pRectsTmp->height - offset2; in damagePolyRectangle()
1059 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyRectangle()
1060 if (BOX_NOT_EMPTY(box)) in damagePolyRectangle()
1061 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyRectangle()
1063 box.x1 = pRectsTmp->x + pRectsTmp->width - offset1; in damagePolyRectangle()
1064 box.y1 = pRectsTmp->y + offset3; in damagePolyRectangle()
1065 box.x2 = box.x1 + offset2; in damagePolyRectangle()
1066 box.y2 = box.y1 + pRectsTmp->height - offset2; in damagePolyRectangle()
1067 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyRectangle()
1068 if (BOX_NOT_EMPTY(box)) in damagePolyRectangle()
1069 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyRectangle()
1071 box.x1 = pRectsTmp->x - offset1; in damagePolyRectangle()
1072 box.y1 = pRectsTmp->y + pRectsTmp->height - offset1; in damagePolyRectangle()
1073 box.x2 = box.x1 + pRectsTmp->width + offset2; in damagePolyRectangle()
1074 box.y2 = box.y1 + offset2; in damagePolyRectangle()
1075 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyRectangle()
1076 if (BOX_NOT_EMPTY(box)) in damagePolyRectangle()
1077 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyRectangle()
1094 BoxRec box; in damagePolyArc() local
1098 box.x1 = pArcsTmp->x; in damagePolyArc()
1099 box.x2 = box.x1 + pArcsTmp->width; in damagePolyArc()
1100 box.y1 = pArcsTmp->y; in damagePolyArc()
1101 box.y2 = box.y1 + pArcsTmp->height; in damagePolyArc()
1105 if (box.x1 > pArcsTmp->x) in damagePolyArc()
1106 box.x1 = pArcsTmp->x; in damagePolyArc()
1107 if (box.x2 < (pArcsTmp->x + pArcsTmp->width)) in damagePolyArc()
1108 box.x2 = pArcsTmp->x + pArcsTmp->width; in damagePolyArc()
1109 if (box.y1 > pArcsTmp->y) in damagePolyArc()
1110 box.y1 = pArcsTmp->y; in damagePolyArc()
1111 if (box.y2 < (pArcsTmp->y + pArcsTmp->height)) in damagePolyArc()
1112 box.y2 = pArcsTmp->y + pArcsTmp->height; in damagePolyArc()
1116 box.x1 -= extra; in damagePolyArc()
1117 box.x2 += extra; in damagePolyArc()
1118 box.y1 -= extra; in damagePolyArc()
1119 box.y2 += extra; in damagePolyArc()
1122 box.x2++; in damagePolyArc()
1123 box.y2++; in damagePolyArc()
1125 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyArc()
1126 if (BOX_NOT_EMPTY(box)) in damagePolyArc()
1127 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyArc()
1143 BoxRec box; in damageFillPolygon() local
1145 box.x2 = box.x1 = pptTmp->x; in damageFillPolygon()
1146 box.y2 = box.y1 = pptTmp->y; in damageFillPolygon()
1149 int x = box.x1; in damageFillPolygon()
1150 int y = box.y1; in damageFillPolygon()
1156 if (box.x1 > x) in damageFillPolygon()
1157 box.x1 = x; in damageFillPolygon()
1158 else if (box.x2 < x) in damageFillPolygon()
1159 box.x2 = x; in damageFillPolygon()
1160 if (box.y1 > y) in damageFillPolygon()
1161 box.y1 = y; in damageFillPolygon()
1162 else if (box.y2 < y) in damageFillPolygon()
1163 box.y2 = y; in damageFillPolygon()
1169 if (box.x1 > pptTmp->x) in damageFillPolygon()
1170 box.x1 = pptTmp->x; in damageFillPolygon()
1171 else if (box.x2 < pptTmp->x) in damageFillPolygon()
1172 box.x2 = pptTmp->x; in damageFillPolygon()
1173 if (box.y1 > pptTmp->y) in damageFillPolygon()
1174 box.y1 = pptTmp->y; in damageFillPolygon()
1175 else if (box.y2 < pptTmp->y) in damageFillPolygon()
1176 box.y2 = pptTmp->y; in damageFillPolygon()
1180 box.x2++; in damageFillPolygon()
1181 box.y2++; in damageFillPolygon()
1183 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damageFillPolygon()
1184 if (BOX_NOT_EMPTY(box)) in damageFillPolygon()
1185 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damageFillPolygon()
1199 BoxRec box; in damagePolyFillRect() local
1203 box.x1 = pRectsTmp->x; in damagePolyFillRect()
1204 box.x2 = box.x1 + pRectsTmp->width; in damagePolyFillRect()
1205 box.y1 = pRectsTmp->y; in damagePolyFillRect()
1206 box.y2 = box.y1 + pRectsTmp->height; in damagePolyFillRect()
1210 if (box.x1 > pRectsTmp->x) in damagePolyFillRect()
1211 box.x1 = pRectsTmp->x; in damagePolyFillRect()
1212 if (box.x2 < (pRectsTmp->x + pRectsTmp->width)) in damagePolyFillRect()
1213 box.x2 = pRectsTmp->x + pRectsTmp->width; in damagePolyFillRect()
1214 if (box.y1 > pRectsTmp->y) in damagePolyFillRect()
1215 box.y1 = pRectsTmp->y; in damagePolyFillRect()
1216 if (box.y2 < (pRectsTmp->y + pRectsTmp->height)) in damagePolyFillRect()
1217 box.y2 = pRectsTmp->y + pRectsTmp->height; in damagePolyFillRect()
1220 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyFillRect()
1221 if (BOX_NOT_EMPTY(box)) in damagePolyFillRect()
1222 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyFillRect()
1235 BoxRec box; in damagePolyFillArc() local
1239 box.x1 = pArcsTmp->x; in damagePolyFillArc()
1240 box.x2 = box.x1 + pArcsTmp->width; in damagePolyFillArc()
1241 box.y1 = pArcsTmp->y; in damagePolyFillArc()
1242 box.y2 = box.y1 + pArcsTmp->height; in damagePolyFillArc()
1246 if (box.x1 > pArcsTmp->x) in damagePolyFillArc()
1247 box.x1 = pArcsTmp->x; in damagePolyFillArc()
1248 if (box.x2 < (pArcsTmp->x + pArcsTmp->width)) in damagePolyFillArc()
1249 box.x2 = pArcsTmp->x + pArcsTmp->width; in damagePolyFillArc()
1250 if (box.y1 > pArcsTmp->y) in damagePolyFillArc()
1251 box.y1 = pArcsTmp->y; in damagePolyFillArc()
1252 if (box.y2 < (pArcsTmp->y + pArcsTmp->height)) in damagePolyFillArc()
1253 box.y2 = pArcsTmp->y + pArcsTmp->height; in damagePolyFillArc()
1256 TRIM_AND_TRANSLATE_BOX(box, pDrawable, pGC); in damagePolyFillArc()
1257 if (BOX_NOT_EMPTY(box)) in damagePolyFillArc()
1258 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePolyFillArc()
1267 * compute bounding box and remove cursor if it is overlapped.
1279 BoxRec box; in damageDamageChars() local
1294 box.x1 = x + extents.overallLeft; in damageDamageChars()
1295 box.y1 = y - extents.overallAscent; in damageDamageChars()
1296 box.x2 = x + extents.overallRight; in damageDamageChars()
1297 box.y2 = y + extents.overallDescent; in damageDamageChars()
1298 damageDamageBox(pDrawable, &box, subWindowMode); in damageDamageChars()
1432 BoxRec box; in damagePushPixels() local
1434 box.x1 = xOrg; in damagePushPixels()
1435 box.y1 = yOrg; in damagePushPixels()
1438 box.x1 += pDrawable->x; in damagePushPixels()
1439 box.y1 += pDrawable->y; in damagePushPixels()
1442 box.x2 = box.x1 + dx; in damagePushPixels()
1443 box.y2 = box.y1 + dy; in damagePushPixels()
1445 TRIM_BOX(box, pGC); in damagePushPixels()
1446 if (BOX_NOT_EMPTY(box)) in damagePushPixels()
1447 damageDamageBox(pDrawable, &box, pGC->subWindowMode); in damagePushPixels()
1859 BoxRec box; in DamageSubtract() local
1861 box.x1 = pDrawable->x; in DamageSubtract()
1862 box.y1 = pDrawable->y; in DamageSubtract()
1863 box.x2 = pDrawable->x + pDrawable->width; in DamageSubtract()
1864 box.y2 = pDrawable->y + pDrawable->height; in DamageSubtract()
1865 RegionInit(&pixmapClip, &box, 1); in DamageSubtract()