| OLD | NEW |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #include "fpdfsdk/include/pdfwindow/PWL_Utils.h" | 7 #include "fpdfsdk/include/pdfwindow/PWL_Utils.h" |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 | 10 |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 csAP << pts[0][0].x << " " << pts[0][0].y << " m\n"; | 167 csAP << pts[0][0].x << " " << pts[0][0].y << " m\n"; |
| 168 | 168 |
| 169 for (size_t i = 0; i < FX_ArraySize(pts); ++i) { | 169 for (size_t i = 0; i < FX_ArraySize(pts); ++i) { |
| 170 size_t nNext = i < FX_ArraySize(pts) - 1 ? i + 1 : 0; | 170 size_t nNext = i < FX_ArraySize(pts) - 1 ? i + 1 : 0; |
| 171 | 171 |
| 172 FX_FLOAT px1 = pts[i][1].x - pts[i][0].x; | 172 FX_FLOAT px1 = pts[i][1].x - pts[i][0].x; |
| 173 FX_FLOAT py1 = pts[i][1].y - pts[i][0].y; | 173 FX_FLOAT py1 = pts[i][1].y - pts[i][0].y; |
| 174 FX_FLOAT px2 = pts[i][2].x - pts[nNext][0].x; | 174 FX_FLOAT px2 = pts[i][2].x - pts[nNext][0].x; |
| 175 FX_FLOAT py2 = pts[i][2].y - pts[nNext][0].y; | 175 FX_FLOAT py2 = pts[i][2].y - pts[nNext][0].y; |
| 176 | 176 |
| 177 csAP << pts[i][0].x + px1 * PWL_BEZIER << " " | 177 csAP << pts[i][0].x + px1 * FX_BEZIER << " " |
| 178 << pts[i][0].y + py1 * PWL_BEZIER << " " | 178 << pts[i][0].y + py1 * FX_BEZIER << " " |
| 179 << pts[nNext][0].x + px2 * PWL_BEZIER << " " | 179 << pts[nNext][0].x + px2 * FX_BEZIER << " " |
| 180 << pts[nNext][0].y + py2 * PWL_BEZIER << " " << pts[nNext][0].x << " " | 180 << pts[nNext][0].y + py2 * FX_BEZIER << " " << pts[nNext][0].x << " " |
| 181 << pts[nNext][0].y << " c\n"; | 181 << pts[nNext][0].y << " c\n"; |
| 182 } | 182 } |
| 183 | 183 |
| 184 return csAP.GetByteString(); | 184 return csAP.GetByteString(); |
| 185 } | 185 } |
| 186 | 186 |
| 187 CFX_ByteString CPWL_Utils::GetAP_Circle(const CPDF_Rect& crBBox) { | 187 CFX_ByteString CPWL_Utils::GetAP_Circle(const CPDF_Rect& crBBox) { |
| 188 CFX_ByteTextBuf csAP; | 188 CFX_ByteTextBuf csAP; |
| 189 | 189 |
| 190 FX_FLOAT fWidth = crBBox.right - crBBox.left; | 190 FX_FLOAT fWidth = crBBox.right - crBBox.left; |
| 191 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; | 191 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; |
| 192 | 192 |
| 193 CPDF_Point pt1(crBBox.left, crBBox.bottom + fHeight / 2); | 193 CPDF_Point pt1(crBBox.left, crBBox.bottom + fHeight / 2); |
| 194 CPDF_Point pt2(crBBox.left + fWidth / 2, crBBox.top); | 194 CPDF_Point pt2(crBBox.left + fWidth / 2, crBBox.top); |
| 195 CPDF_Point pt3(crBBox.right, crBBox.bottom + fHeight / 2); | 195 CPDF_Point pt3(crBBox.right, crBBox.bottom + fHeight / 2); |
| 196 CPDF_Point pt4(crBBox.left + fWidth / 2, crBBox.bottom); | 196 CPDF_Point pt4(crBBox.left + fWidth / 2, crBBox.bottom); |
| 197 | 197 |
| 198 csAP << pt1.x << " " << pt1.y << " m\n"; | 198 csAP << pt1.x << " " << pt1.y << " m\n"; |
| 199 | 199 |
| 200 FX_FLOAT px = pt2.x - pt1.x; | 200 FX_FLOAT px = pt2.x - pt1.x; |
| 201 FX_FLOAT py = pt2.y - pt1.y; | 201 FX_FLOAT py = pt2.y - pt1.y; |
| 202 | 202 |
| 203 csAP << pt1.x << " " << pt1.y + py * PWL_BEZIER << " " | 203 csAP << pt1.x << " " << pt1.y + py * FX_BEZIER << " " |
| 204 << pt2.x - px * PWL_BEZIER << " " << pt2.y << " " << pt2.x << " " | 204 << pt2.x - px * FX_BEZIER << " " << pt2.y << " " << pt2.x << " " << pt2.y |
| 205 << pt2.y << " c\n"; | 205 << " c\n"; |
| 206 | 206 |
| 207 px = pt3.x - pt2.x; | 207 px = pt3.x - pt2.x; |
| 208 py = pt2.y - pt3.y; | 208 py = pt2.y - pt3.y; |
| 209 | 209 |
| 210 csAP << pt2.x + px * PWL_BEZIER << " " << pt2.y << " " << pt3.x << " " | 210 csAP << pt2.x + px * FX_BEZIER << " " << pt2.y << " " << pt3.x << " " |
| 211 << pt3.y + py * PWL_BEZIER << " " << pt3.x << " " << pt3.y << " c\n"; | 211 << pt3.y + py * FX_BEZIER << " " << pt3.x << " " << pt3.y << " c\n"; |
| 212 | 212 |
| 213 px = pt3.x - pt4.x; | 213 px = pt3.x - pt4.x; |
| 214 py = pt3.y - pt4.y; | 214 py = pt3.y - pt4.y; |
| 215 | 215 |
| 216 csAP << pt3.x << " " << pt3.y - py * PWL_BEZIER << " " | 216 csAP << pt3.x << " " << pt3.y - py * FX_BEZIER << " " |
| 217 << pt4.x + px * PWL_BEZIER << " " << pt4.y << " " << pt4.x << " " | 217 << pt4.x + px * FX_BEZIER << " " << pt4.y << " " << pt4.x << " " << pt4.y |
| 218 << pt4.y << " c\n"; | 218 << " c\n"; |
| 219 | 219 |
| 220 px = pt4.x - pt1.x; | 220 px = pt4.x - pt1.x; |
| 221 py = pt1.y - pt4.y; | 221 py = pt1.y - pt4.y; |
| 222 | 222 |
| 223 csAP << pt4.x - px * PWL_BEZIER << " " << pt4.y << " " << pt1.x << " " | 223 csAP << pt4.x - px * FX_BEZIER << " " << pt4.y << " " << pt1.x << " " |
| 224 << pt1.y - py * PWL_BEZIER << " " << pt1.x << " " << pt1.y << " c\n"; | 224 << pt1.y - py * FX_BEZIER << " " << pt1.x << " " << pt1.y << " c\n"; |
| 225 | 225 |
| 226 return csAP.GetByteString(); | 226 return csAP.GetByteString(); |
| 227 } | 227 } |
| 228 | 228 |
| 229 CFX_ByteString CPWL_Utils::GetAP_Cross(const CPDF_Rect& crBBox) { | 229 CFX_ByteString CPWL_Utils::GetAP_Cross(const CPDF_Rect& crBBox) { |
| 230 CFX_ByteTextBuf csAP; | 230 CFX_ByteTextBuf csAP; |
| 231 | 231 |
| 232 csAP << crBBox.left << " " << crBBox.top << " m\n"; | 232 csAP << crBBox.left << " " << crBBox.top << " m\n"; |
| 233 csAP << crBBox.right << " " << crBBox.bottom << " l\n"; | 233 csAP << crBBox.right << " " << crBBox.bottom << " l\n"; |
| 234 csAP << crBBox.left << " " << crBBox.bottom << " m\n"; | 234 csAP << crBBox.left << " " << crBBox.bottom << " m\n"; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 csAP << crBBox.left << " " << crBBox.bottom << " l\n"; | 266 csAP << crBBox.left << " " << crBBox.bottom << " l\n"; |
| 267 csAP << crBBox.left << " " << crBBox.top << " l\n"; | 267 csAP << crBBox.left << " " << crBBox.top << " l\n"; |
| 268 | 268 |
| 269 return csAP.GetByteString(); | 269 return csAP.GetByteString(); |
| 270 } | 270 } |
| 271 | 271 |
| 272 CFX_ByteString CPWL_Utils::GetAP_Star(const CPDF_Rect& crBBox) { | 272 CFX_ByteString CPWL_Utils::GetAP_Star(const CPDF_Rect& crBBox) { |
| 273 CFX_ByteTextBuf csAP; | 273 CFX_ByteTextBuf csAP; |
| 274 | 274 |
| 275 FX_FLOAT fRadius = | 275 FX_FLOAT fRadius = |
| 276 (crBBox.top - crBBox.bottom) / (1 + (FX_FLOAT)cos(PWL_PI / 5.0f)); | 276 (crBBox.top - crBBox.bottom) / (1 + (FX_FLOAT)cos(FX_PI / 5.0f)); |
| 277 CPDF_Point ptCenter = CPDF_Point((crBBox.left + crBBox.right) / 2.0f, | 277 CPDF_Point ptCenter = CPDF_Point((crBBox.left + crBBox.right) / 2.0f, |
| 278 (crBBox.top + crBBox.bottom) / 2.0f); | 278 (crBBox.top + crBBox.bottom) / 2.0f); |
| 279 | 279 |
| 280 FX_FLOAT px[5], py[5]; | 280 FX_FLOAT px[5], py[5]; |
| 281 | 281 |
| 282 FX_FLOAT fAngel = PWL_PI / 10.0f; | 282 FX_FLOAT fAngel = FX_PI / 10.0f; |
| 283 | 283 |
| 284 for (int32_t i = 0; i < 5; i++) { | 284 for (int32_t i = 0; i < 5; i++) { |
| 285 px[i] = ptCenter.x + fRadius * (FX_FLOAT)cos(fAngel); | 285 px[i] = ptCenter.x + fRadius * (FX_FLOAT)cos(fAngel); |
| 286 py[i] = ptCenter.y + fRadius * (FX_FLOAT)sin(fAngel); | 286 py[i] = ptCenter.y + fRadius * (FX_FLOAT)sin(fAngel); |
| 287 | 287 |
| 288 fAngel += PWL_PI * 2 / 5.0f; | 288 fAngel += FX_PI * 2 / 5.0f; |
| 289 } | 289 } |
| 290 | 290 |
| 291 csAP << px[0] << " " << py[0] << " m\n"; | 291 csAP << px[0] << " " << py[0] << " m\n"; |
| 292 | 292 |
| 293 int32_t nNext = 0; | 293 int32_t nNext = 0; |
| 294 for (int32_t j = 0; j < 5; j++) { | 294 for (int32_t j = 0; j < 5; j++) { |
| 295 nNext += 2; | 295 nNext += 2; |
| 296 if (nNext >= 5) | 296 if (nNext >= 5) |
| 297 nNext -= 5; | 297 nNext -= 5; |
| 298 csAP << px[nNext] << " " << py[nNext] << " l\n"; | 298 csAP << px[nNext] << " " << py[nNext] << " l\n"; |
| (...skipping 17 matching lines...) Expand all Loading... |
| 316 | 316 |
| 317 csAP << cos(fRotate) << " " << sin(fRotate) << " " << -sin(fRotate) << " " | 317 csAP << cos(fRotate) << " " << sin(fRotate) << " " << -sin(fRotate) << " " |
| 318 << cos(fRotate) << " " << crBBox.left + fWidth / 2 << " " | 318 << cos(fRotate) << " " << crBBox.left + fWidth / 2 << " " |
| 319 << crBBox.bottom + fHeight / 2 << " cm\n"; | 319 << crBBox.bottom + fHeight / 2 << " cm\n"; |
| 320 | 320 |
| 321 csAP << pt1.x << " " << pt1.y << " m\n"; | 321 csAP << pt1.x << " " << pt1.y << " m\n"; |
| 322 | 322 |
| 323 px = pt2.x - pt1.x; | 323 px = pt2.x - pt1.x; |
| 324 py = pt2.y - pt1.y; | 324 py = pt2.y - pt1.y; |
| 325 | 325 |
| 326 csAP << pt1.x << " " << pt1.y + py * PWL_BEZIER << " " | 326 csAP << pt1.x << " " << pt1.y + py * FX_BEZIER << " " |
| 327 << pt2.x - px * PWL_BEZIER << " " << pt2.y << " " << pt2.x << " " | 327 << pt2.x - px * FX_BEZIER << " " << pt2.y << " " << pt2.x << " " << pt2.y |
| 328 << pt2.y << " c\n"; | 328 << " c\n"; |
| 329 | 329 |
| 330 px = pt3.x - pt2.x; | 330 px = pt3.x - pt2.x; |
| 331 py = pt2.y - pt3.y; | 331 py = pt2.y - pt3.y; |
| 332 | 332 |
| 333 csAP << pt2.x + px * PWL_BEZIER << " " << pt2.y << " " << pt3.x << " " | 333 csAP << pt2.x + px * FX_BEZIER << " " << pt2.y << " " << pt3.x << " " |
| 334 << pt3.y + py * PWL_BEZIER << " " << pt3.x << " " << pt3.y << " c\n"; | 334 << pt3.y + py * FX_BEZIER << " " << pt3.x << " " << pt3.y << " c\n"; |
| 335 | 335 |
| 336 return csAP.GetByteString(); | 336 return csAP.GetByteString(); |
| 337 } | 337 } |
| 338 | 338 |
| 339 CPDF_Rect CPWL_Utils::InflateRect(const CPDF_Rect& rcRect, FX_FLOAT fSize) { | 339 CPDF_Rect CPWL_Utils::InflateRect(const CPDF_Rect& rcRect, FX_FLOAT fSize) { |
| 340 if (rcRect.IsEmpty()) | 340 if (rcRect.IsEmpty()) |
| 341 return rcRect; | 341 return rcRect; |
| 342 | 342 |
| 343 CPDF_Rect rcNew(rcRect.left - fSize, rcRect.bottom - fSize, | 343 CPDF_Rect rcNew(rcRect.left - fSize, rcRect.bottom - fSize, |
| 344 rcRect.right + fSize, rcRect.top + fSize); | 344 rcRect.right + fSize, rcRect.top + fSize); |
| (...skipping 673 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1018 if (sColor.GetLength() > 0) { | 1018 if (sColor.GetLength() > 0) { |
| 1019 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor | 1019 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor |
| 1020 << CPWL_Utils::GetAP_Circle(rect) << " S\nQ\n"; | 1020 << CPWL_Utils::GetAP_Circle(rect) << " S\nQ\n"; |
| 1021 } | 1021 } |
| 1022 | 1022 |
| 1023 sColor = CPWL_Utils::GetColorAppStream(crLeftTop, FALSE); | 1023 sColor = CPWL_Utils::GetColorAppStream(crLeftTop, FALSE); |
| 1024 if (sColor.GetLength() > 0) { | 1024 if (sColor.GetLength() > 0) { |
| 1025 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor | 1025 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor |
| 1026 << CPWL_Utils::GetAP_HalfCircle( | 1026 << CPWL_Utils::GetAP_HalfCircle( |
| 1027 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), | 1027 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), |
| 1028 PWL_PI / 4.0f) | 1028 FX_PI / 4.0f) |
| 1029 << " S\nQ\n"; | 1029 << " S\nQ\n"; |
| 1030 } | 1030 } |
| 1031 | 1031 |
| 1032 sColor = CPWL_Utils::GetColorAppStream(crRightBottom, FALSE); | 1032 sColor = CPWL_Utils::GetColorAppStream(crRightBottom, FALSE); |
| 1033 if (sColor.GetLength() > 0) { | 1033 if (sColor.GetLength() > 0) { |
| 1034 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor | 1034 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor |
| 1035 << CPWL_Utils::GetAP_HalfCircle( | 1035 << CPWL_Utils::GetAP_HalfCircle( |
| 1036 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), | 1036 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), |
| 1037 PWL_PI * 5 / 4.0f) | 1037 FX_PI * 5 / 4.0f) |
| 1038 << " S\nQ\n"; | 1038 << " S\nQ\n"; |
| 1039 } | 1039 } |
| 1040 } break; | 1040 } break; |
| 1041 case PBS_INSET: { | 1041 case PBS_INSET: { |
| 1042 FX_FLOAT fHalfWidth = fWidth / 2.0f; | 1042 FX_FLOAT fHalfWidth = fWidth / 2.0f; |
| 1043 | 1043 |
| 1044 sColor = CPWL_Utils::GetColorAppStream(color, FALSE); | 1044 sColor = CPWL_Utils::GetColorAppStream(color, FALSE); |
| 1045 if (sColor.GetLength() > 0) { | 1045 if (sColor.GetLength() > 0) { |
| 1046 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor | 1046 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor |
| 1047 << CPWL_Utils::GetAP_Circle(rect) << " S\nQ\n"; | 1047 << CPWL_Utils::GetAP_Circle(rect) << " S\nQ\n"; |
| 1048 } | 1048 } |
| 1049 | 1049 |
| 1050 sColor = CPWL_Utils::GetColorAppStream(crLeftTop, FALSE); | 1050 sColor = CPWL_Utils::GetColorAppStream(crLeftTop, FALSE); |
| 1051 if (sColor.GetLength() > 0) { | 1051 if (sColor.GetLength() > 0) { |
| 1052 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor | 1052 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor |
| 1053 << CPWL_Utils::GetAP_HalfCircle( | 1053 << CPWL_Utils::GetAP_HalfCircle( |
| 1054 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), | 1054 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), |
| 1055 PWL_PI / 4.0f) | 1055 FX_PI / 4.0f) |
| 1056 << " S\nQ\n"; | 1056 << " S\nQ\n"; |
| 1057 } | 1057 } |
| 1058 | 1058 |
| 1059 sColor = CPWL_Utils::GetColorAppStream(crRightBottom, FALSE); | 1059 sColor = CPWL_Utils::GetColorAppStream(crRightBottom, FALSE); |
| 1060 if (sColor.GetLength() > 0) { | 1060 if (sColor.GetLength() > 0) { |
| 1061 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor | 1061 sAppStream << "q\n" << fHalfWidth << " w\n" << sColor |
| 1062 << CPWL_Utils::GetAP_HalfCircle( | 1062 << CPWL_Utils::GetAP_HalfCircle( |
| 1063 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), | 1063 CPWL_Utils::DeflateRect(rect, fHalfWidth * 0.75f), |
| 1064 PWL_PI * 5 / 4.0f) | 1064 FX_PI * 5 / 4.0f) |
| 1065 << " S\nQ\n"; | 1065 << " S\nQ\n"; |
| 1066 } | 1066 } |
| 1067 } break; | 1067 } break; |
| 1068 } | 1068 } |
| 1069 | 1069 |
| 1070 sAppStream << "Q\n"; | 1070 sAppStream << "Q\n"; |
| 1071 } | 1071 } |
| 1072 | 1072 |
| 1073 return sAppStream.GetByteString(); | 1073 return sAppStream.GetByteString(); |
| 1074 } | 1074 } |
| (...skipping 906 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1981 const CPDF_Rect& crBBox, | 1981 const CPDF_Rect& crBBox, |
| 1982 const PWL_PATH_TYPE type) { | 1982 const PWL_PATH_TYPE type) { |
| 1983 FX_FLOAT fWidth = crBBox.right - crBBox.left; | 1983 FX_FLOAT fWidth = crBBox.right - crBBox.left; |
| 1984 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; | 1984 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; |
| 1985 | 1985 |
| 1986 CPWL_PathData PathArray[] = { | 1986 CPWL_PathData PathArray[] = { |
| 1987 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, | 1987 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 1988 crBBox.bottom + fHeight * 2 / 5.0f), | 1988 crBBox.bottom + fHeight * 2 / 5.0f), |
| 1989 PWLPT_MOVETO), | 1989 PWLPT_MOVETO), |
| 1990 CPWL_PathData( | 1990 CPWL_PathData( |
| 1991 CPWL_Point( | 1991 CPWL_Point(crBBox.left + fWidth / 15.0f + |
| 1992 crBBox.left + fWidth / 15.0f + | 1992 FX_BEZIER * (fWidth / 7.0f - fWidth / 15.0f), |
| 1993 PWL_BEZIER * (fWidth / 7.0f - fWidth / 15.0f), | 1993 crBBox.bottom + fHeight * 2 / 5.0f + |
| 1994 crBBox.bottom + fHeight * 2 / 5.0f + | 1994 FX_BEZIER * (fHeight * 2 / 7.0f - fHeight * 2 / 5.0f)), |
| 1995 PWL_BEZIER * (fHeight * 2 / 7.0f - fHeight * 2 / 5.0f)), | |
| 1996 PWLPT_BEZIERTO), | 1995 PWLPT_BEZIERTO), |
| 1997 CPWL_PathData( | 1996 CPWL_PathData( |
| 1998 CPWL_Point(crBBox.left + fWidth / 4.5f + | 1997 CPWL_Point(crBBox.left + fWidth / 4.5f + |
| 1999 PWL_BEZIER * (fWidth / 5.0f - fWidth / 4.5f), | 1998 FX_BEZIER * (fWidth / 5.0f - fWidth / 4.5f), |
| 2000 crBBox.bottom + fHeight / 16.0f + | 1999 crBBox.bottom + fHeight / 16.0f + |
| 2001 PWL_BEZIER * (fHeight / 5.0f - fHeight / 16.0f)), | 2000 FX_BEZIER * (fHeight / 5.0f - fHeight / 16.0f)), |
| 2002 PWLPT_BEZIERTO), | 2001 PWLPT_BEZIERTO), |
| 2003 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 4.5f, | 2002 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 4.5f, |
| 2004 crBBox.bottom + fHeight / 16.0f), | 2003 crBBox.bottom + fHeight / 16.0f), |
| 2005 PWLPT_BEZIERTO), | 2004 PWLPT_BEZIERTO), |
| 2006 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 4.5f + | 2005 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 4.5f + |
| 2007 PWL_BEZIER * (fWidth / 4.4f - fWidth / 4.5f), | 2006 FX_BEZIER * (fWidth / 4.4f - fWidth / 4.5f), |
| 2008 crBBox.bottom + fHeight / 16.0f - | 2007 crBBox.bottom + fHeight / 16.0f - |
| 2009 PWL_BEZIER * fHeight / 16.0f), | 2008 FX_BEZIER * fHeight / 16.0f), |
| 2010 PWLPT_BEZIERTO), | 2009 PWLPT_BEZIERTO), |
| 2011 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.0f + | 2010 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.0f + |
| 2012 PWL_BEZIER * (fWidth / 4.0f - fWidth / 3.0f), | 2011 FX_BEZIER * (fWidth / 4.0f - fWidth / 3.0f), |
| 2013 crBBox.bottom), | 2012 crBBox.bottom), |
| 2014 PWLPT_BEZIERTO), | 2013 PWLPT_BEZIERTO), |
| 2015 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.0f, crBBox.bottom), | 2014 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.0f, crBBox.bottom), |
| 2016 PWLPT_BEZIERTO), | 2015 PWLPT_BEZIERTO), |
| 2017 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.0f + | 2016 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.0f + |
| 2018 PWL_BEZIER * fWidth * (1 / 7.0f + 2 / 15.0f), | 2017 FX_BEZIER * fWidth * (1 / 7.0f + 2 / 15.0f), |
| 2019 crBBox.bottom + PWL_BEZIER * fHeight * 4 / 5.0f), | 2018 crBBox.bottom + FX_BEZIER * fHeight * 4 / 5.0f), |
| 2020 PWLPT_BEZIERTO), | 2019 PWLPT_BEZIERTO), |
| 2021 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 14 / 15.0f + | 2020 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 14 / 15.0f + |
| 2022 PWL_BEZIER * fWidth * (1 / 7.0f - 7 / 15.0f), | 2021 FX_BEZIER * fWidth * (1 / 7.0f - 7 / 15.0f), |
| 2023 crBBox.bottom + fHeight * 15 / 16.0f + | 2022 crBBox.bottom + fHeight * 15 / 16.0f + |
| 2024 PWL_BEZIER * (fHeight * 4 / 5.0f - | 2023 FX_BEZIER * (fHeight * 4 / 5.0f - |
| 2025 fHeight * 15 / 16.0f)), | 2024 fHeight * 15 / 16.0f)), |
| 2026 PWLPT_BEZIERTO), | 2025 PWLPT_BEZIERTO), |
| 2027 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 14 / 15.0f, | 2026 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 14 / 15.0f, |
| 2028 crBBox.bottom + fHeight * 15 / 16.0f), | 2027 crBBox.bottom + fHeight * 15 / 16.0f), |
| 2029 PWLPT_BEZIERTO), | 2028 PWLPT_BEZIERTO), |
| 2030 CPWL_PathData( | 2029 CPWL_PathData( |
| 2031 CPWL_Point( | 2030 CPWL_Point( |
| 2032 crBBox.left + fWidth * 14 / 15.0f + | 2031 crBBox.left + fWidth * 14 / 15.0f + |
| 2033 PWL_BEZIER * (fWidth * 7 / 15.0f - fWidth * 14 / 15.0f), | 2032 FX_BEZIER * (fWidth * 7 / 15.0f - fWidth * 14 / 15.0f), |
| 2034 crBBox.bottom + fHeight * 15 / 16.0f + | 2033 crBBox.bottom + fHeight * 15 / 16.0f + |
| 2035 PWL_BEZIER * (fHeight * 8 / 7.0f - fHeight * 15 / 16.0f)), | 2034 FX_BEZIER * (fHeight * 8 / 7.0f - fHeight * 15 / 16.0f)), |
| 2036 PWLPT_BEZIERTO), | 2035 PWLPT_BEZIERTO), |
| 2037 CPWL_PathData( | 2036 CPWL_PathData( |
| 2038 CPWL_Point(crBBox.left + fWidth / 3.6f + | 2037 CPWL_Point(crBBox.left + fWidth / 3.6f + |
| 2039 PWL_BEZIER * (fWidth / 3.4f - fWidth / 3.6f), | 2038 FX_BEZIER * (fWidth / 3.4f - fWidth / 3.6f), |
| 2040 crBBox.bottom + fHeight / 3.5f + | 2039 crBBox.bottom + fHeight / 3.5f + |
| 2041 PWL_BEZIER * (fHeight / 3.5f - fHeight / 3.5f)), | 2040 FX_BEZIER * (fHeight / 3.5f - fHeight / 3.5f)), |
| 2042 PWLPT_BEZIERTO), | 2041 PWLPT_BEZIERTO), |
| 2043 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.6f, | 2042 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 3.6f, |
| 2044 crBBox.bottom + fHeight / 3.5f), | 2043 crBBox.bottom + fHeight / 3.5f), |
| 2045 PWLPT_BEZIERTO), | 2044 PWLPT_BEZIERTO), |
| 2046 CPWL_PathData( | 2045 CPWL_PathData( |
| 2047 CPWL_Point(crBBox.left + fWidth / 3.6f, | 2046 CPWL_Point(crBBox.left + fWidth / 3.6f, |
| 2048 crBBox.bottom + fHeight / 3.5f + | 2047 crBBox.bottom + fHeight / 3.5f + |
| 2049 PWL_BEZIER * (fHeight / 4.0f - fHeight / 3.5f)), | 2048 FX_BEZIER * (fHeight / 4.0f - fHeight / 3.5f)), |
| 2050 PWLPT_BEZIERTO), | 2049 PWLPT_BEZIERTO), |
| 2051 CPWL_PathData( | 2050 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f + |
| 2052 CPWL_Point( | 2051 FX_BEZIER * (fWidth / 3.5f - fWidth / 15.0f), |
| 2053 crBBox.left + fWidth / 15.0f + | 2052 crBBox.bottom + fHeight * 2 / 5.0f + |
| 2054 PWL_BEZIER * (fWidth / 3.5f - fWidth / 15.0f), | 2053 FX_BEZIER * (fHeight * 3.5f / 5.0f - |
| 2055 crBBox.bottom + fHeight * 2 / 5.0f + | 2054 fHeight * 2 / 5.0f)), |
| 2056 PWL_BEZIER * (fHeight * 3.5f / 5.0f - fHeight * 2 / 5.0f)), | 2055 PWLPT_BEZIERTO), |
| 2057 PWLPT_BEZIERTO), | |
| 2058 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, | 2056 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2059 crBBox.bottom + fHeight * 2 / 5.0f), | 2057 crBBox.bottom + fHeight * 2 / 5.0f), |
| 2060 PWLPT_BEZIERTO)}; | 2058 PWLPT_BEZIERTO)}; |
| 2061 | 2059 |
| 2062 if (type == PWLPT_STREAM) | 2060 if (type == PWLPT_STREAM) |
| 2063 sPathData = GetAppStreamFromArray(PathArray, 16); | 2061 sPathData = GetAppStreamFromArray(PathArray, 16); |
| 2064 else | 2062 else |
| 2065 GetPathDataFromArray(path, PathArray, 16); | 2063 GetPathDataFromArray(path, PathArray, 16); |
| 2066 } | 2064 } |
| 2067 | 2065 |
| 2068 void CPWL_Utils::GetGraphics_Circle(CFX_ByteString& sPathData, | 2066 void CPWL_Utils::GetGraphics_Circle(CFX_ByteString& sPathData, |
| 2069 CFX_PathData& path, | 2067 CFX_PathData& path, |
| 2070 const CPDF_Rect& crBBox, | 2068 const CPDF_Rect& crBBox, |
| 2071 const PWL_PATH_TYPE type) { | 2069 const PWL_PATH_TYPE type) { |
| 2072 FX_FLOAT fWidth = crBBox.right - crBBox.left; | 2070 FX_FLOAT fWidth = crBBox.right - crBBox.left; |
| 2073 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; | 2071 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; |
| 2074 | 2072 |
| 2075 CPWL_PathData PathArray[] = { | 2073 CPWL_PathData PathArray[] = { |
| 2076 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, | 2074 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2077 crBBox.bottom + fHeight / 2.0f), | 2075 crBBox.bottom + fHeight / 2.0f), |
| 2078 PWLPT_MOVETO), | 2076 PWLPT_MOVETO), |
| 2079 CPWL_PathData( | 2077 CPWL_PathData( |
| 2080 CPWL_Point(crBBox.left + fWidth / 15.0f, | 2078 CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2081 crBBox.bottom + fHeight / 2.0f + | 2079 crBBox.bottom + fHeight / 2.0f + |
| 2082 PWL_BEZIER * (fHeight * 14 / 15.0f - fHeight / 2.0f)), | 2080 FX_BEZIER * (fHeight * 14 / 15.0f - fHeight / 2.0f)), |
| 2083 PWLPT_BEZIERTO), | 2081 PWLPT_BEZIERTO), |
| 2084 CPWL_PathData( | 2082 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f - |
| 2085 CPWL_Point(crBBox.left + fWidth / 2.0f - | 2083 FX_BEZIER * (fWidth / 2.0f - fWidth / 15.0f), |
| 2086 PWL_BEZIER * (fWidth / 2.0f - fWidth / 15.0f), | 2084 crBBox.top - fHeight / 15.0f), |
| 2087 crBBox.top - fHeight / 15.0f), | 2085 PWLPT_BEZIERTO), |
| 2088 PWLPT_BEZIERTO), | |
| 2089 CPWL_PathData( | 2086 CPWL_PathData( |
| 2090 CPWL_Point(crBBox.left + fWidth / 2.0f, crBBox.top - fHeight / 15.0f), | 2087 CPWL_Point(crBBox.left + fWidth / 2.0f, crBBox.top - fHeight / 15.0f), |
| 2091 PWLPT_BEZIERTO), | 2088 PWLPT_BEZIERTO), |
| 2092 CPWL_PathData( | 2089 CPWL_PathData( |
| 2093 CPWL_Point(crBBox.left + fWidth / 2.0f + | 2090 CPWL_Point(crBBox.left + fWidth / 2.0f + |
| 2094 PWL_BEZIER * (fWidth * 14 / 15.0f - fWidth / 2.0f), | 2091 FX_BEZIER * (fWidth * 14 / 15.0f - fWidth / 2.0f), |
| 2095 crBBox.top - fHeight / 15.0f), | 2092 crBBox.top - fHeight / 15.0f), |
| 2096 PWLPT_BEZIERTO), | 2093 PWLPT_BEZIERTO), |
| 2097 CPWL_PathData( | 2094 CPWL_PathData( |
| 2098 CPWL_Point(crBBox.right - fWidth / 15.0f, | 2095 CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2099 crBBox.bottom + fHeight / 2.0f + | 2096 crBBox.bottom + fHeight / 2.0f + |
| 2100 PWL_BEZIER * (fHeight * 14 / 15.0f - fHeight / 2.0f)), | 2097 FX_BEZIER * (fHeight * 14 / 15.0f - fHeight / 2.0f)), |
| 2101 PWLPT_BEZIERTO), | 2098 PWLPT_BEZIERTO), |
| 2102 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, | 2099 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2103 crBBox.bottom + fHeight / 2.0f), | 2100 crBBox.bottom + fHeight / 2.0f), |
| 2104 PWLPT_BEZIERTO), | 2101 PWLPT_BEZIERTO), |
| 2105 CPWL_PathData( | 2102 CPWL_PathData( |
| 2106 CPWL_Point(crBBox.right - fWidth / 15.0f, | 2103 CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2107 crBBox.bottom + fHeight / 2.0f - | 2104 crBBox.bottom + fHeight / 2.0f - |
| 2108 PWL_BEZIER * (fHeight / 2.0f - fHeight / 15.0f)), | 2105 FX_BEZIER * (fHeight / 2.0f - fHeight / 15.0f)), |
| 2109 PWLPT_BEZIERTO), | 2106 PWLPT_BEZIERTO), |
| 2110 CPWL_PathData( | 2107 CPWL_PathData( |
| 2111 CPWL_Point(crBBox.left + fWidth / 2.0f + | 2108 CPWL_Point(crBBox.left + fWidth / 2.0f + |
| 2112 PWL_BEZIER * (fWidth * 14 / 15.0f - fWidth / 2.0f), | 2109 FX_BEZIER * (fWidth * 14 / 15.0f - fWidth / 2.0f), |
| 2113 crBBox.bottom + fHeight / 15.0f), | 2110 crBBox.bottom + fHeight / 15.0f), |
| 2114 PWLPT_BEZIERTO), | 2111 PWLPT_BEZIERTO), |
| 2115 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, | 2112 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, |
| 2116 crBBox.bottom + fHeight / 15.0f), | 2113 crBBox.bottom + fHeight / 15.0f), |
| 2117 PWLPT_BEZIERTO), | 2114 PWLPT_BEZIERTO), |
| 2118 CPWL_PathData( | 2115 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f - |
| 2119 CPWL_Point(crBBox.left + fWidth / 2.0f - | 2116 FX_BEZIER * (fWidth / 2.0f - fWidth / 15.0f), |
| 2120 PWL_BEZIER * (fWidth / 2.0f - fWidth / 15.0f), | 2117 crBBox.bottom + fHeight / 15.0f), |
| 2121 crBBox.bottom + fHeight / 15.0f), | 2118 PWLPT_BEZIERTO), |
| 2122 PWLPT_BEZIERTO), | |
| 2123 CPWL_PathData( | 2119 CPWL_PathData( |
| 2124 CPWL_Point(crBBox.left + fWidth / 15.0f, | 2120 CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2125 crBBox.bottom + fHeight / 2.0f - | 2121 crBBox.bottom + fHeight / 2.0f - |
| 2126 PWL_BEZIER * (fHeight / 2.0f - fHeight / 15.0f)), | 2122 FX_BEZIER * (fHeight / 2.0f - fHeight / 15.0f)), |
| 2127 PWLPT_BEZIERTO), | 2123 PWLPT_BEZIERTO), |
| 2128 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, | 2124 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2129 crBBox.bottom + fHeight / 2.0f), | 2125 crBBox.bottom + fHeight / 2.0f), |
| 2130 PWLPT_BEZIERTO), | 2126 PWLPT_BEZIERTO), |
| 2131 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, | 2127 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, |
| 2132 crBBox.bottom + fHeight / 2.0f), | 2128 crBBox.bottom + fHeight / 2.0f), |
| 2133 PWLPT_MOVETO), | 2129 PWLPT_MOVETO), |
| 2134 CPWL_PathData( | 2130 CPWL_PathData( |
| 2135 CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, | 2131 CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, |
| 2136 crBBox.bottom + fHeight / 2.0f + | 2132 crBBox.bottom + fHeight / 2.0f + |
| 2137 PWL_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), | 2133 FX_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), |
| 2138 PWLPT_BEZIERTO), | 2134 PWLPT_BEZIERTO), |
| 2139 CPWL_PathData( | 2135 CPWL_PathData( |
| 2140 CPWL_Point(crBBox.left + fWidth / 2.0f - | 2136 CPWL_Point(crBBox.left + fWidth / 2.0f - |
| 2141 PWL_BEZIER * (fWidth / 2.0f - fWidth * 3 / 15.0f), | 2137 FX_BEZIER * (fWidth / 2.0f - fWidth * 3 / 15.0f), |
| 2142 crBBox.top - fHeight * 3 / 15.0f), | 2138 crBBox.top - fHeight * 3 / 15.0f), |
| 2143 PWLPT_BEZIERTO), | 2139 PWLPT_BEZIERTO), |
| 2144 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, | 2140 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, |
| 2145 crBBox.top - fHeight * 3 / 15.0f), | 2141 crBBox.top - fHeight * 3 / 15.0f), |
| 2146 PWLPT_BEZIERTO), | 2142 PWLPT_BEZIERTO), |
| 2147 CPWL_PathData( | 2143 CPWL_PathData( |
| 2148 CPWL_Point(crBBox.left + fWidth / 2.0f + | 2144 CPWL_Point(crBBox.left + fWidth / 2.0f + |
| 2149 PWL_BEZIER * (fWidth * 4 / 5.0f - fWidth / 2.0f), | 2145 FX_BEZIER * (fWidth * 4 / 5.0f - fWidth / 2.0f), |
| 2150 crBBox.top - fHeight * 3 / 15.0f), | 2146 crBBox.top - fHeight * 3 / 15.0f), |
| 2151 PWLPT_BEZIERTO), | 2147 PWLPT_BEZIERTO), |
| 2152 CPWL_PathData( | 2148 CPWL_PathData( |
| 2153 CPWL_Point(crBBox.right - fWidth * 3 / 15.0f, | 2149 CPWL_Point(crBBox.right - fWidth * 3 / 15.0f, |
| 2154 crBBox.bottom + fHeight / 2.0f + | 2150 crBBox.bottom + fHeight / 2.0f + |
| 2155 PWL_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), | 2151 FX_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), |
| 2156 PWLPT_BEZIERTO), | 2152 PWLPT_BEZIERTO), |
| 2157 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 3 / 15.0f, | 2153 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 3 / 15.0f, |
| 2158 crBBox.bottom + fHeight / 2.0f), | 2154 crBBox.bottom + fHeight / 2.0f), |
| 2159 PWLPT_BEZIERTO), | 2155 PWLPT_BEZIERTO), |
| 2160 CPWL_PathData( | 2156 CPWL_PathData( |
| 2161 CPWL_Point(crBBox.right - fWidth * 3 / 15.0f, | 2157 CPWL_Point(crBBox.right - fWidth * 3 / 15.0f, |
| 2162 crBBox.bottom + fHeight / 2.0f - | 2158 crBBox.bottom + fHeight / 2.0f - |
| 2163 PWL_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), | 2159 FX_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), |
| 2164 PWLPT_BEZIERTO), | 2160 PWLPT_BEZIERTO), |
| 2165 CPWL_PathData( | 2161 CPWL_PathData( |
| 2166 CPWL_Point(crBBox.left + fWidth / 2.0f + | 2162 CPWL_Point(crBBox.left + fWidth / 2.0f + |
| 2167 PWL_BEZIER * (fWidth * 4 / 5.0f - fWidth / 2.0f), | 2163 FX_BEZIER * (fWidth * 4 / 5.0f - fWidth / 2.0f), |
| 2168 crBBox.bottom + fHeight * 3 / 15.0f), | 2164 crBBox.bottom + fHeight * 3 / 15.0f), |
| 2169 PWLPT_BEZIERTO), | 2165 PWLPT_BEZIERTO), |
| 2170 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, | 2166 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, |
| 2171 crBBox.bottom + fHeight * 3 / 15.0f), | 2167 crBBox.bottom + fHeight * 3 / 15.0f), |
| 2172 PWLPT_BEZIERTO), | 2168 PWLPT_BEZIERTO), |
| 2173 CPWL_PathData( | 2169 CPWL_PathData( |
| 2174 CPWL_Point(crBBox.left + fWidth / 2.0f - | 2170 CPWL_Point(crBBox.left + fWidth / 2.0f - |
| 2175 PWL_BEZIER * (fWidth * 4 / 5.0f - fWidth / 2.0f), | 2171 FX_BEZIER * (fWidth * 4 / 5.0f - fWidth / 2.0f), |
| 2176 crBBox.bottom + fHeight * 3 / 15.0f), | 2172 crBBox.bottom + fHeight * 3 / 15.0f), |
| 2177 PWLPT_BEZIERTO), | 2173 PWLPT_BEZIERTO), |
| 2178 CPWL_PathData( | 2174 CPWL_PathData( |
| 2179 CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, | 2175 CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, |
| 2180 crBBox.bottom + fHeight / 2.0f - | 2176 crBBox.bottom + fHeight / 2.0f - |
| 2181 PWL_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), | 2177 FX_BEZIER * (fHeight * 4 / 5.0f - fHeight / 2.0f)), |
| 2182 PWLPT_BEZIERTO), | 2178 PWLPT_BEZIERTO), |
| 2183 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, | 2179 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 3 / 15.0f, |
| 2184 crBBox.bottom + fHeight / 2.0f), | 2180 crBBox.bottom + fHeight / 2.0f), |
| 2185 PWLPT_BEZIERTO)}; | 2181 PWLPT_BEZIERTO)}; |
| 2186 | 2182 |
| 2187 if (type == PWLPT_STREAM) | 2183 if (type == PWLPT_STREAM) |
| 2188 sPathData = GetAppStreamFromArray(PathArray, 26); | 2184 sPathData = GetAppStreamFromArray(PathArray, 26); |
| 2189 else | 2185 else |
| 2190 GetPathDataFromArray(path, PathArray, 26); | 2186 GetPathDataFromArray(path, PathArray, 26); |
| 2191 } | 2187 } |
| 2192 | 2188 |
| 2193 void CPWL_Utils::GetGraphics_Comment(CFX_ByteString& sPathData, | 2189 void CPWL_Utils::GetGraphics_Comment(CFX_ByteString& sPathData, |
| 2194 CFX_PathData& path, | 2190 CFX_PathData& path, |
| 2195 const CPDF_Rect& crBBox, | 2191 const CPDF_Rect& crBBox, |
| 2196 const PWL_PATH_TYPE type) { | 2192 const PWL_PATH_TYPE type) { |
| 2197 FX_FLOAT fWidth = crBBox.right - crBBox.left; | 2193 FX_FLOAT fWidth = crBBox.right - crBBox.left; |
| 2198 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; | 2194 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; |
| 2199 | 2195 |
| 2200 CPWL_PathData PathArray[] = { | 2196 CPWL_PathData PathArray[] = { |
| 2201 CPWL_PathData( | 2197 CPWL_PathData( |
| 2202 CPWL_Point(crBBox.left + fWidth / 15.0f, crBBox.top - fHeight / 6.0f), | 2198 CPWL_Point(crBBox.left + fWidth / 15.0f, crBBox.top - fHeight / 6.0f), |
| 2203 PWLPT_MOVETO), | 2199 PWLPT_MOVETO), |
| 2204 CPWL_PathData( | 2200 CPWL_PathData( |
| 2205 CPWL_Point(crBBox.left + fWidth / 15.0f, | 2201 CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2206 crBBox.top - fHeight / 6.0f + | 2202 crBBox.top - fHeight / 6.0f + |
| 2207 PWL_BEZIER * (fHeight / 6.0f - fHeight / 10.0f)), | 2203 FX_BEZIER * (fHeight / 6.0f - fHeight / 10.0f)), |
| 2208 PWLPT_BEZIERTO), | 2204 PWLPT_BEZIERTO), |
| 2209 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f - | 2205 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f - |
| 2210 PWL_BEZIER * fWidth / 15.0f, | 2206 FX_BEZIER * fWidth / 15.0f, |
| 2211 crBBox.top - fHeight / 10.0f), | 2207 crBBox.top - fHeight / 10.0f), |
| 2212 PWLPT_BEZIERTO), | 2208 PWLPT_BEZIERTO), |
| 2213 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f, | 2209 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f, |
| 2214 crBBox.top - fHeight / 10.0f), | 2210 crBBox.top - fHeight / 10.0f), |
| 2215 PWLPT_BEZIERTO), | 2211 PWLPT_BEZIERTO), |
| 2216 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f, | 2212 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f, |
| 2217 crBBox.top - fHeight / 10.0f), | 2213 crBBox.top - fHeight / 10.0f), |
| 2218 PWLPT_LINETO), | 2214 PWLPT_LINETO), |
| 2219 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f + | 2215 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f + |
| 2220 PWL_BEZIER * fWidth / 15.0f, | 2216 FX_BEZIER * fWidth / 15.0f, |
| 2221 crBBox.top - fHeight / 10.0f), | 2217 crBBox.top - fHeight / 10.0f), |
| 2222 PWLPT_BEZIERTO), | 2218 PWLPT_BEZIERTO), |
| 2223 CPWL_PathData( | 2219 CPWL_PathData( |
| 2224 CPWL_Point(crBBox.right - fWidth / 15.0f, | 2220 CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2225 crBBox.top - fHeight / 6 + | 2221 crBBox.top - fHeight / 6 + |
| 2226 PWL_BEZIER * (fHeight / 6.0f - fHeight / 10.0f)), | 2222 FX_BEZIER * (fHeight / 6.0f - fHeight / 10.0f)), |
| 2227 PWLPT_BEZIERTO), | 2223 PWLPT_BEZIERTO), |
| 2228 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, | 2224 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2229 crBBox.top - fHeight / 6.0f), | 2225 crBBox.top - fHeight / 6.0f), |
| 2230 PWLPT_BEZIERTO), | 2226 PWLPT_BEZIERTO), |
| 2231 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, | 2227 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2232 crBBox.bottom + fHeight / 3.0f), | 2228 crBBox.bottom + fHeight / 3.0f), |
| 2233 PWLPT_LINETO), | 2229 PWLPT_LINETO), |
| 2234 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, | 2230 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 15.0f, |
| 2235 crBBox.bottom + fHeight * 4 / 15.0f + | 2231 crBBox.bottom + fHeight * 4 / 15.0f + |
| 2236 PWL_BEZIER * fHeight / 15.0f), | 2232 FX_BEZIER * fHeight / 15.0f), |
| 2237 PWLPT_BEZIERTO), | 2233 PWLPT_BEZIERTO), |
| 2238 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f + | 2234 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f + |
| 2239 PWL_BEZIER * fWidth / 15.0f, | 2235 FX_BEZIER * fWidth / 15.0f, |
| 2240 crBBox.bottom + fHeight * 4 / 15.0f), | 2236 crBBox.bottom + fHeight * 4 / 15.0f), |
| 2241 PWLPT_BEZIERTO), | 2237 PWLPT_BEZIERTO), |
| 2242 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f, | 2238 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 2 / 15.0f, |
| 2243 crBBox.bottom + fHeight * 4 / 15.0f), | 2239 crBBox.bottom + fHeight * 4 / 15.0f), |
| 2244 PWLPT_BEZIERTO), | 2240 PWLPT_BEZIERTO), |
| 2245 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 5 / 15.0f, | 2241 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 5 / 15.0f, |
| 2246 crBBox.bottom + fHeight * 4 / 15.0f), | 2242 crBBox.bottom + fHeight * 4 / 15.0f), |
| 2247 PWLPT_LINETO), | 2243 PWLPT_LINETO), |
| 2248 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 5 / 15.0f, | 2244 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 5 / 15.0f, |
| 2249 crBBox.bottom + fHeight * 2 / 15 + | 2245 crBBox.bottom + fHeight * 2 / 15 + |
| 2250 PWL_BEZIER * fHeight * 2 / 15.0f), | 2246 FX_BEZIER * fHeight * 2 / 15.0f), |
| 2251 PWLPT_BEZIERTO), | 2247 PWLPT_BEZIERTO), |
| 2252 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 5 / 15.0f - | 2248 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 5 / 15.0f - |
| 2253 PWL_BEZIER * fWidth * 2 / 15.0f, | 2249 FX_BEZIER * fWidth * 2 / 15.0f, |
| 2254 crBBox.bottom + fHeight * 2 / 15.0f), | 2250 crBBox.bottom + fHeight * 2 / 15.0f), |
| 2255 PWLPT_BEZIERTO), | 2251 PWLPT_BEZIERTO), |
| 2256 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 6 / 30.0f, | 2252 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 6 / 30.0f, |
| 2257 crBBox.bottom + fHeight * 2 / 15.0f), | 2253 crBBox.bottom + fHeight * 2 / 15.0f), |
| 2258 PWLPT_BEZIERTO), | 2254 PWLPT_BEZIERTO), |
| 2259 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 7 / 30.0f + | 2255 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 7 / 30.0f + |
| 2260 PWL_BEZIER * fWidth / 30.0f, | 2256 FX_BEZIER * fWidth / 30.0f, |
| 2261 crBBox.bottom + fHeight * 2 / 15.0f), | 2257 crBBox.bottom + fHeight * 2 / 15.0f), |
| 2262 PWLPT_BEZIERTO), | 2258 PWLPT_BEZIERTO), |
| 2263 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 7 / 30.0f, | 2259 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 7 / 30.0f, |
| 2264 crBBox.bottom + fHeight * 2 / 15.0f + | 2260 crBBox.bottom + fHeight * 2 / 15.0f + |
| 2265 PWL_BEZIER * fHeight * 2 / 15.0f), | 2261 FX_BEZIER * fHeight * 2 / 15.0f), |
| 2266 PWLPT_BEZIERTO), | 2262 PWLPT_BEZIERTO), |
| 2267 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 7 / 30.0f, | 2263 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 7 / 30.0f, |
| 2268 crBBox.bottom + fHeight * 4 / 15.0f), | 2264 crBBox.bottom + fHeight * 4 / 15.0f), |
| 2269 PWLPT_BEZIERTO), | 2265 PWLPT_BEZIERTO), |
| 2270 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f, | 2266 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f, |
| 2271 crBBox.bottom + fHeight * 4 / 15.0f), | 2267 crBBox.bottom + fHeight * 4 / 15.0f), |
| 2272 PWLPT_LINETO), | 2268 PWLPT_LINETO), |
| 2273 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f - | 2269 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f - |
| 2274 PWL_BEZIER * fWidth / 15.0f, | 2270 FX_BEZIER * fWidth / 15.0f, |
| 2275 crBBox.bottom + fHeight * 4 / 15.0f), | 2271 crBBox.bottom + fHeight * 4 / 15.0f), |
| 2276 PWLPT_BEZIERTO), | 2272 PWLPT_BEZIERTO), |
| 2277 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, | 2273 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2278 crBBox.bottom + fHeight / 3.0f - | 2274 crBBox.bottom + fHeight / 3.0f - |
| 2279 PWL_BEZIER * fHeight / 15.0f), | 2275 FX_BEZIER * fHeight / 15.0f), |
| 2280 PWLPT_BEZIERTO), | 2276 PWLPT_BEZIERTO), |
| 2281 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, | 2277 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 15.0f, |
| 2282 crBBox.bottom + fHeight / 3.0f), | 2278 crBBox.bottom + fHeight / 3.0f), |
| 2283 PWLPT_BEZIERTO), | 2279 PWLPT_BEZIERTO), |
| 2284 CPWL_PathData( | 2280 CPWL_PathData( |
| 2285 CPWL_Point(crBBox.left + fWidth / 15.0f, crBBox.top - fHeight / 6.0f), | 2281 CPWL_Point(crBBox.left + fWidth / 15.0f, crBBox.top - fHeight / 6.0f), |
| 2286 PWLPT_LINETO), | 2282 PWLPT_LINETO), |
| 2287 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f, | 2283 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 2 / 15.0f, |
| 2288 crBBox.top - fHeight * 8 / 30.0f), | 2284 crBBox.top - fHeight * 8 / 30.0f), |
| 2289 PWLPT_MOVETO), | 2285 PWLPT_MOVETO), |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2373 FX_FLOAT fWidth = crBBox.right - crBBox.left; | 2369 FX_FLOAT fWidth = crBBox.right - crBBox.left; |
| 2374 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; | 2370 FX_FLOAT fHeight = crBBox.top - crBBox.bottom; |
| 2375 | 2371 |
| 2376 CPWL_PathData PathArray[] = { | 2372 CPWL_PathData PathArray[] = { |
| 2377 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 60.0f, | 2373 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 60.0f, |
| 2378 crBBox.bottom + fHeight / 2.0f), | 2374 crBBox.bottom + fHeight / 2.0f), |
| 2379 PWLPT_MOVETO), | 2375 PWLPT_MOVETO), |
| 2380 CPWL_PathData( | 2376 CPWL_PathData( |
| 2381 CPWL_Point(crBBox.left + fWidth / 60.0f, | 2377 CPWL_Point(crBBox.left + fWidth / 60.0f, |
| 2382 crBBox.bottom + fHeight / 2.0f + | 2378 crBBox.bottom + fHeight / 2.0f + |
| 2383 PWL_BEZIER * (fHeight / 60.0f - fHeight / 2.0f)), | 2379 FX_BEZIER * (fHeight / 60.0f - fHeight / 2.0f)), |
| 2384 PWLPT_BEZIERTO), | 2380 PWLPT_BEZIERTO), |
| 2385 CPWL_PathData( | 2381 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f - |
| 2386 CPWL_Point(crBBox.left + fWidth / 2.0f - | 2382 FX_BEZIER * (fWidth / 2.0f - fWidth / 60.0f), |
| 2387 PWL_BEZIER * (fWidth / 2.0f - fWidth / 60.0f), | 2383 crBBox.bottom + fHeight / 60.0f), |
| 2388 crBBox.bottom + fHeight / 60.0f), | 2384 PWLPT_BEZIERTO), |
| 2389 PWLPT_BEZIERTO), | |
| 2390 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, | 2385 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f, |
| 2391 crBBox.bottom + fHeight / 60.0f), | 2386 crBBox.bottom + fHeight / 60.0f), |
| 2392 PWLPT_BEZIERTO), | 2387 PWLPT_BEZIERTO), |
| 2393 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f + | 2388 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f + |
| 2394 PWL_BEZIER * fWidth * 29 / 60.0f, | 2389 FX_BEZIER * fWidth * 29 / 60.0f, |
| 2395 crBBox.bottom + fHeight / 60.0f), | 2390 crBBox.bottom + fHeight / 60.0f), |
| 2396 PWLPT_BEZIERTO), | 2391 PWLPT_BEZIERTO), |
| 2397 CPWL_PathData( | 2392 CPWL_PathData( |
| 2398 CPWL_Point(crBBox.right - fWidth / 60.0f, | 2393 CPWL_Point(crBBox.right - fWidth / 60.0f, |
| 2399 crBBox.bottom + fHeight / 2.0f + | 2394 crBBox.bottom + fHeight / 2.0f + |
| 2400 PWL_BEZIER * (fHeight / 60.0f - fHeight / 2.0f)), | 2395 FX_BEZIER * (fHeight / 60.0f - fHeight / 2.0f)), |
| 2401 PWLPT_BEZIERTO), | 2396 PWLPT_BEZIERTO), |
| 2402 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 60.0f, | 2397 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 60.0f, |
| 2403 crBBox.bottom + fHeight / 2.0f), | 2398 crBBox.bottom + fHeight / 2.0f), |
| 2404 PWLPT_BEZIERTO), | 2399 PWLPT_BEZIERTO), |
| 2405 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 60.0f, | 2400 CPWL_PathData(CPWL_Point(crBBox.right - fWidth / 60.0f, |
| 2406 crBBox.bottom + fHeight / 2.0f + | 2401 crBBox.bottom + fHeight / 2.0f + |
| 2407 PWL_BEZIER * fHeight * 29 / 60.0f), | 2402 FX_BEZIER * fHeight * 29 / 60.0f), |
| 2408 PWLPT_BEZIERTO), | 2403 PWLPT_BEZIERTO), |
| 2409 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f + | 2404 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f + |
| 2410 PWL_BEZIER * fWidth * 29 / 60.0f, | 2405 FX_BEZIER * fWidth * 29 / 60.0f, |
| 2411 crBBox.top - fHeight / 60.0f), | 2406 crBBox.top - fHeight / 60.0f), |
| 2412 PWLPT_BEZIERTO), | 2407 PWLPT_BEZIERTO), |
| 2413 CPWL_PathData( | 2408 CPWL_PathData( |
| 2414 CPWL_Point(crBBox.left + fWidth / 2.0f, crBBox.top - fHeight / 60.0f), | 2409 CPWL_Point(crBBox.left + fWidth / 2.0f, crBBox.top - fHeight / 60.0f), |
| 2415 PWLPT_BEZIERTO), | 2410 PWLPT_BEZIERTO), |
| 2416 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f - | 2411 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 2.0f - |
| 2417 PWL_BEZIER * fWidth * 29 / 60.0f, | 2412 FX_BEZIER * fWidth * 29 / 60.0f, |
| 2418 crBBox.top - fHeight / 60.0f), | 2413 crBBox.top - fHeight / 60.0f), |
| 2419 PWLPT_BEZIERTO), | 2414 PWLPT_BEZIERTO), |
| 2420 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 60.0f, | 2415 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 60.0f, |
| 2421 crBBox.bottom + fHeight / 2.0f + | 2416 crBBox.bottom + fHeight / 2.0f + |
| 2422 PWL_BEZIER * fHeight * 29 / 60.0f), | 2417 FX_BEZIER * fHeight * 29 / 60.0f), |
| 2423 PWLPT_BEZIERTO), | 2418 PWLPT_BEZIERTO), |
| 2424 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 60.0f, | 2419 CPWL_PathData(CPWL_Point(crBBox.left + fWidth / 60.0f, |
| 2425 crBBox.bottom + fHeight / 2.0f), | 2420 crBBox.bottom + fHeight / 2.0f), |
| 2426 PWLPT_BEZIERTO), | 2421 PWLPT_BEZIERTO), |
| 2427 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.27f, | 2422 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.27f, |
| 2428 crBBox.top - fHeight * 0.36f), | 2423 crBBox.top - fHeight * 0.36f), |
| 2429 PWLPT_MOVETO), | 2424 PWLPT_MOVETO), |
| 2430 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.27f, | 2425 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.27f, |
| 2431 crBBox.top - fHeight * 0.36f + | 2426 crBBox.top - fHeight * 0.36f + |
| 2432 PWL_BEZIER * fHeight * 0.23f), | 2427 FX_BEZIER * fHeight * 0.23f), |
| 2433 PWLPT_BEZIERTO), | 2428 PWLPT_BEZIERTO), |
| 2434 CPWL_PathData( | 2429 CPWL_PathData( |
| 2435 CPWL_Point(crBBox.left + fWidth * 0.5f - PWL_BEZIER * fWidth * 0.23f, | 2430 CPWL_Point(crBBox.left + fWidth * 0.5f - FX_BEZIER * fWidth * 0.23f, |
| 2436 crBBox.bottom + fHeight * 0.87f), | 2431 crBBox.bottom + fHeight * 0.87f), |
| 2437 PWLPT_BEZIERTO), | 2432 PWLPT_BEZIERTO), |
| 2438 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.5f, | 2433 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.5f, |
| 2439 crBBox.bottom + fHeight * 0.87f), | 2434 crBBox.bottom + fHeight * 0.87f), |
| 2440 PWLPT_BEZIERTO), | 2435 PWLPT_BEZIERTO), |
| 2441 CPWL_PathData( | 2436 CPWL_PathData( |
| 2442 CPWL_Point(crBBox.left + fWidth * 0.5f + PWL_BEZIER * fWidth * 0.23f, | 2437 CPWL_Point(crBBox.left + fWidth * 0.5f + FX_BEZIER * fWidth * 0.23f, |
| 2443 crBBox.bottom + fHeight * 0.87f), | 2438 crBBox.bottom + fHeight * 0.87f), |
| 2444 PWLPT_BEZIERTO), | 2439 PWLPT_BEZIERTO), |
| 2445 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.27f, | 2440 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.27f, |
| 2446 crBBox.top - fHeight * 0.36f + | 2441 crBBox.top - fHeight * 0.36f + |
| 2447 PWL_BEZIER * fHeight * 0.23f), | 2442 FX_BEZIER * fHeight * 0.23f), |
| 2448 PWLPT_BEZIERTO), | 2443 PWLPT_BEZIERTO), |
| 2449 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.27f, | 2444 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.27f, |
| 2450 crBBox.top - fHeight * 0.36f), | 2445 crBBox.top - fHeight * 0.36f), |
| 2451 PWLPT_BEZIERTO), | 2446 PWLPT_BEZIERTO), |
| 2452 CPWL_PathData( | 2447 CPWL_PathData( |
| 2453 CPWL_Point(crBBox.right - fWidth * 0.27f - fWidth * 0.08f * 0.2f, | 2448 CPWL_Point(crBBox.right - fWidth * 0.27f - fWidth * 0.08f * 0.2f, |
| 2454 crBBox.top - fHeight * 0.36f - fHeight * 0.15f * 0.7f), | 2449 crBBox.top - fHeight * 0.36f - fHeight * 0.15f * 0.7f), |
| 2455 PWLPT_BEZIERTO), | 2450 PWLPT_BEZIERTO), |
| 2456 CPWL_PathData( | 2451 CPWL_PathData( |
| 2457 CPWL_Point(crBBox.right - fWidth * 0.35f + fWidth * 0.08f * 0.2f, | 2452 CPWL_Point(crBBox.right - fWidth * 0.35f + fWidth * 0.08f * 0.2f, |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2505 PWLPT_BEZIERTO), | 2500 PWLPT_BEZIERTO), |
| 2506 CPWL_PathData( | 2501 CPWL_PathData( |
| 2507 CPWL_Point(crBBox.right - fWidth * 0.37f - fWidth * 0.08f * 0.2f, | 2502 CPWL_Point(crBBox.right - fWidth * 0.37f - fWidth * 0.08f * 0.2f, |
| 2508 crBBox.top - fHeight * 0.36f - fHeight * 0.18f * 0.7f), | 2503 crBBox.top - fHeight * 0.36f - fHeight * 0.18f * 0.7f), |
| 2509 PWLPT_BEZIERTO), | 2504 PWLPT_BEZIERTO), |
| 2510 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.37f, | 2505 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.37f, |
| 2511 crBBox.top - fHeight * 0.36f), | 2506 crBBox.top - fHeight * 0.36f), |
| 2512 PWLPT_BEZIERTO), | 2507 PWLPT_BEZIERTO), |
| 2513 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.37f, | 2508 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.37f, |
| 2514 crBBox.top - fHeight * 0.36f + | 2509 crBBox.top - fHeight * 0.36f + |
| 2515 PWL_BEZIER * fHeight * 0.13f), | 2510 FX_BEZIER * fHeight * 0.13f), |
| 2516 PWLPT_BEZIERTO), | 2511 PWLPT_BEZIERTO), |
| 2517 CPWL_PathData( | 2512 CPWL_PathData( |
| 2518 CPWL_Point(crBBox.left + fWidth * 0.5f + PWL_BEZIER * fWidth * 0.13f, | 2513 CPWL_Point(crBBox.left + fWidth * 0.5f + FX_BEZIER * fWidth * 0.13f, |
| 2519 crBBox.bottom + fHeight * 0.77f), | 2514 crBBox.bottom + fHeight * 0.77f), |
| 2520 PWLPT_BEZIERTO), | 2515 PWLPT_BEZIERTO), |
| 2521 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.5f, | 2516 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.5f, |
| 2522 crBBox.bottom + fHeight * 0.77f), | 2517 crBBox.bottom + fHeight * 0.77f), |
| 2523 PWLPT_BEZIERTO), | 2518 PWLPT_BEZIERTO), |
| 2524 CPWL_PathData( | 2519 CPWL_PathData( |
| 2525 CPWL_Point(crBBox.left + fWidth * 0.5f - PWL_BEZIER * fWidth * 0.13f, | 2520 CPWL_Point(crBBox.left + fWidth * 0.5f - FX_BEZIER * fWidth * 0.13f, |
| 2526 crBBox.bottom + fHeight * 0.77f), | 2521 crBBox.bottom + fHeight * 0.77f), |
| 2527 PWLPT_BEZIERTO), | 2522 PWLPT_BEZIERTO), |
| 2528 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.37f, | 2523 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.37f, |
| 2529 crBBox.top - fHeight * 0.36f + | 2524 crBBox.top - fHeight * 0.36f + |
| 2530 PWL_BEZIER * fHeight * 0.13f), | 2525 FX_BEZIER * fHeight * 0.13f), |
| 2531 PWLPT_BEZIERTO), | 2526 PWLPT_BEZIERTO), |
| 2532 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.37f, | 2527 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.37f, |
| 2533 crBBox.top - fHeight * 0.36f), | 2528 crBBox.top - fHeight * 0.36f), |
| 2534 PWLPT_BEZIERTO), | 2529 PWLPT_BEZIERTO), |
| 2535 CPWL_PathData( | 2530 CPWL_PathData( |
| 2536 CPWL_Point(crBBox.left + fWidth * 0.37f, | 2531 CPWL_Point(crBBox.left + fWidth * 0.37f, |
| 2537 crBBox.top - fHeight * 0.36f - fWidth * 0.1f * 0.6f), | 2532 crBBox.top - fHeight * 0.36f - fWidth * 0.1f * 0.6f), |
| 2538 PWLPT_BEZIERTO), | 2533 PWLPT_BEZIERTO), |
| 2539 CPWL_PathData( | 2534 CPWL_PathData( |
| 2540 CPWL_Point(crBBox.left + fWidth * 0.27f, | 2535 CPWL_Point(crBBox.left + fWidth * 0.27f, |
| 2541 crBBox.top - fHeight * 0.36f - fWidth * 0.1f * 0.6f), | 2536 crBBox.top - fHeight * 0.36f - fWidth * 0.1f * 0.6f), |
| 2542 PWLPT_BEZIERTO), | 2537 PWLPT_BEZIERTO), |
| 2543 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.27f, | 2538 CPWL_PathData(CPWL_Point(crBBox.left + fWidth * 0.27f, |
| 2544 crBBox.top - fHeight * 0.36f), | 2539 crBBox.top - fHeight * 0.36f), |
| 2545 PWLPT_BEZIERTO), | 2540 PWLPT_BEZIERTO), |
| 2546 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, | 2541 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, |
| 2547 crBBox.bottom + fHeight * 0.13f), | 2542 crBBox.bottom + fHeight * 0.13f), |
| 2548 PWLPT_MOVETO), | 2543 PWLPT_MOVETO), |
| 2549 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, | 2544 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, |
| 2550 crBBox.bottom + fHeight * 0.13f + | 2545 crBBox.bottom + fHeight * 0.13f + |
| 2551 PWL_BEZIER * fHeight * 0.055f), | 2546 FX_BEZIER * fHeight * 0.055f), |
| 2552 PWLPT_BEZIERTO), | 2547 PWLPT_BEZIERTO), |
| 2553 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f - | 2548 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f - |
| 2554 PWL_BEZIER * fWidth * 0.095f, | 2549 FX_BEZIER * fWidth * 0.095f, |
| 2555 crBBox.bottom + fHeight * 0.185f), | 2550 crBBox.bottom + fHeight * 0.185f), |
| 2556 PWLPT_BEZIERTO), | 2551 PWLPT_BEZIERTO), |
| 2557 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f, | 2552 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f, |
| 2558 crBBox.bottom + fHeight * 0.185f), | 2553 crBBox.bottom + fHeight * 0.185f), |
| 2559 PWLPT_BEZIERTO), | 2554 PWLPT_BEZIERTO), |
| 2560 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f + | 2555 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f + |
| 2561 PWL_BEZIER * fWidth * 0.065f, | 2556 FX_BEZIER * fWidth * 0.065f, |
| 2562 crBBox.bottom + fHeight * 0.185f), | 2557 crBBox.bottom + fHeight * 0.185f), |
| 2563 PWLPT_BEZIERTO), | 2558 PWLPT_BEZIERTO), |
| 2564 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.44f, | 2559 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.44f, |
| 2565 crBBox.bottom + fHeight * 0.13f + | 2560 crBBox.bottom + fHeight * 0.13f + |
| 2566 PWL_BEZIER * fHeight * 0.055f), | 2561 FX_BEZIER * fHeight * 0.055f), |
| 2567 PWLPT_BEZIERTO), | 2562 PWLPT_BEZIERTO), |
| 2568 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.44f, | 2563 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.44f, |
| 2569 crBBox.bottom + fHeight * 0.13f), | 2564 crBBox.bottom + fHeight * 0.13f), |
| 2570 PWLPT_BEZIERTO), | 2565 PWLPT_BEZIERTO), |
| 2571 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.44f, | 2566 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.44f, |
| 2572 crBBox.bottom + fHeight * 0.13f - | 2567 crBBox.bottom + fHeight * 0.13f - |
| 2573 PWL_BEZIER * fHeight * 0.055f), | 2568 FX_BEZIER * fHeight * 0.055f), |
| 2574 PWLPT_BEZIERTO), | 2569 PWLPT_BEZIERTO), |
| 2575 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f + | 2570 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f + |
| 2576 PWL_BEZIER * fWidth * 0.065f, | 2571 FX_BEZIER * fWidth * 0.065f, |
| 2577 crBBox.bottom + fHeight * 0.075f), | 2572 crBBox.bottom + fHeight * 0.075f), |
| 2578 PWLPT_BEZIERTO), | 2573 PWLPT_BEZIERTO), |
| 2579 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f, | 2574 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f, |
| 2580 crBBox.bottom + fHeight * 0.075f), | 2575 crBBox.bottom + fHeight * 0.075f), |
| 2581 PWLPT_BEZIERTO), | 2576 PWLPT_BEZIERTO), |
| 2582 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f - | 2577 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.505f - |
| 2583 PWL_BEZIER * fWidth * 0.065f, | 2578 FX_BEZIER * fWidth * 0.065f, |
| 2584 crBBox.bottom + fHeight * 0.075f), | 2579 crBBox.bottom + fHeight * 0.075f), |
| 2585 PWLPT_BEZIERTO), | 2580 PWLPT_BEZIERTO), |
| 2586 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, | 2581 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, |
| 2587 crBBox.bottom + fHeight * 0.13f - | 2582 crBBox.bottom + fHeight * 0.13f - |
| 2588 PWL_BEZIER * fHeight * 0.055f), | 2583 FX_BEZIER * fHeight * 0.055f), |
| 2589 PWLPT_BEZIERTO), | 2584 PWLPT_BEZIERTO), |
| 2590 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, | 2585 CPWL_PathData(CPWL_Point(crBBox.right - fWidth * 0.56f, |
| 2591 crBBox.bottom + fHeight * 0.13f), | 2586 crBBox.bottom + fHeight * 0.13f), |
| 2592 PWLPT_BEZIERTO)}; | 2587 PWLPT_BEZIERTO)}; |
| 2593 | 2588 |
| 2594 if (type == PWLPT_STREAM) | 2589 if (type == PWLPT_STREAM) |
| 2595 sPathData = GetAppStreamFromArray(PathArray, 59); | 2590 sPathData = GetAppStreamFromArray(PathArray, 59); |
| 2596 else | 2591 else |
| 2597 GetPathDataFromArray(path, PathArray, 59); | 2592 GetPathDataFromArray(path, PathArray, 59); |
| 2598 } | 2593 } |
| (...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3049 sPathData = GetAppStreamFromArray(PathArray, 5); | 3044 sPathData = GetAppStreamFromArray(PathArray, 5); |
| 3050 else | 3045 else |
| 3051 GetPathDataFromArray(path, PathArray, 5); | 3046 GetPathDataFromArray(path, PathArray, 5); |
| 3052 } | 3047 } |
| 3053 | 3048 |
| 3054 void CPWL_Utils::GetGraphics_Star(CFX_ByteString& sPathData, | 3049 void CPWL_Utils::GetGraphics_Star(CFX_ByteString& sPathData, |
| 3055 CFX_PathData& path, | 3050 CFX_PathData& path, |
| 3056 const CPDF_Rect& crBBox, | 3051 const CPDF_Rect& crBBox, |
| 3057 const PWL_PATH_TYPE type) { | 3052 const PWL_PATH_TYPE type) { |
| 3058 FX_FLOAT fLongRadius = | 3053 FX_FLOAT fLongRadius = |
| 3059 (crBBox.top - crBBox.bottom) / (1 + (FX_FLOAT)cos(PWL_PI / 5.0f)); | 3054 (crBBox.top - crBBox.bottom) / (1 + (FX_FLOAT)cos(FX_PI / 5.0f)); |
| 3060 fLongRadius = fLongRadius * 0.7f; | 3055 fLongRadius = fLongRadius * 0.7f; |
| 3061 FX_FLOAT fShortRadius = fLongRadius * 0.55f; | 3056 FX_FLOAT fShortRadius = fLongRadius * 0.55f; |
| 3062 CPDF_Point ptCenter = CPDF_Point((crBBox.left + crBBox.right) / 2.0f, | 3057 CPDF_Point ptCenter = CPDF_Point((crBBox.left + crBBox.right) / 2.0f, |
| 3063 (crBBox.top + crBBox.bottom) / 2.0f); | 3058 (crBBox.top + crBBox.bottom) / 2.0f); |
| 3064 | 3059 |
| 3065 FX_FLOAT px1[5], py1[5]; | 3060 FX_FLOAT px1[5], py1[5]; |
| 3066 FX_FLOAT px2[5], py2[5]; | 3061 FX_FLOAT px2[5], py2[5]; |
| 3067 | 3062 |
| 3068 FX_FLOAT fAngel = PWL_PI / 10.0f; | 3063 FX_FLOAT fAngel = FX_PI / 10.0f; |
| 3069 | 3064 |
| 3070 for (int32_t i = 0; i < 5; i++) { | 3065 for (int32_t i = 0; i < 5; i++) { |
| 3071 px1[i] = ptCenter.x + fLongRadius * (FX_FLOAT)cos(fAngel); | 3066 px1[i] = ptCenter.x + fLongRadius * (FX_FLOAT)cos(fAngel); |
| 3072 py1[i] = ptCenter.y + fLongRadius * (FX_FLOAT)sin(fAngel); | 3067 py1[i] = ptCenter.y + fLongRadius * (FX_FLOAT)sin(fAngel); |
| 3073 | 3068 |
| 3074 fAngel += PWL_PI * 2 / 5.0f; | 3069 fAngel += FX_PI * 2 / 5.0f; |
| 3075 } | 3070 } |
| 3076 | 3071 |
| 3077 fAngel = PWL_PI / 5.0f + PWL_PI / 10.0f; | 3072 fAngel = FX_PI / 5.0f + FX_PI / 10.0f; |
| 3078 | 3073 |
| 3079 for (int32_t j = 0; j < 5; j++) { | 3074 for (int32_t j = 0; j < 5; j++) { |
| 3080 px2[j] = ptCenter.x + fShortRadius * (FX_FLOAT)cos(fAngel); | 3075 px2[j] = ptCenter.x + fShortRadius * (FX_FLOAT)cos(fAngel); |
| 3081 py2[j] = ptCenter.y + fShortRadius * (FX_FLOAT)sin(fAngel); | 3076 py2[j] = ptCenter.y + fShortRadius * (FX_FLOAT)sin(fAngel); |
| 3082 | 3077 |
| 3083 fAngel += PWL_PI * 2 / 5.0f; | 3078 fAngel += FX_PI * 2 / 5.0f; |
| 3084 } | 3079 } |
| 3085 | 3080 |
| 3086 CPWL_PathData PathArray[11]; | 3081 CPWL_PathData PathArray[11]; |
| 3087 PathArray[0] = CPWL_PathData(CPWL_Point(px1[0], py1[0]), PWLPT_MOVETO); | 3082 PathArray[0] = CPWL_PathData(CPWL_Point(px1[0], py1[0]), PWLPT_MOVETO); |
| 3088 PathArray[1] = CPWL_PathData(CPWL_Point(px2[0], py2[0]), PWLPT_LINETO); | 3083 PathArray[1] = CPWL_PathData(CPWL_Point(px2[0], py2[0]), PWLPT_LINETO); |
| 3089 | 3084 |
| 3090 for (int32_t k = 0; k < 4; k++) { | 3085 for (int32_t k = 0; k < 4; k++) { |
| 3091 PathArray[(k + 1) * 2] = | 3086 PathArray[(k + 1) * 2] = |
| 3092 CPWL_PathData(CPWL_Point(px1[k + 1], py1[k + 1]), PWLPT_LINETO); | 3087 CPWL_PathData(CPWL_Point(px1[k + 1], py1[k + 1]), PWLPT_LINETO); |
| 3093 PathArray[(k + 1) * 2 + 1] = | 3088 PathArray[(k + 1) * 2 + 1] = |
| (...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3578 crInBox.bottom = crBBox.bottom + fOutHeight * 0.08f; | 3573 crInBox.bottom = crBBox.bottom + fOutHeight * 0.08f; |
| 3579 | 3574 |
| 3580 FX_FLOAT fWidth = crInBox.right - crInBox.left; | 3575 FX_FLOAT fWidth = crInBox.right - crInBox.left; |
| 3581 FX_FLOAT fHeight = crInBox.top - crInBox.bottom; | 3576 FX_FLOAT fHeight = crInBox.top - crInBox.bottom; |
| 3582 | 3577 |
| 3583 CPWL_PathData PathArray[] = { | 3578 CPWL_PathData PathArray[] = { |
| 3584 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top), PWLPT_MOVETO), | 3579 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top), PWLPT_MOVETO), |
| 3585 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.45f, crInBox.top), | 3580 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.45f, crInBox.top), |
| 3586 PWLPT_LINETO), | 3581 PWLPT_LINETO), |
| 3587 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.45f, | 3582 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.45f, |
| 3588 crInBox.top - PWL_BEZIER * fHeight * 0.4f), | 3583 crInBox.top - FX_BEZIER * fHeight * 0.4f), |
| 3589 PWLPT_BEZIERTO), | 3584 PWLPT_BEZIERTO), |
| 3590 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.45f - | 3585 CPWL_PathData( |
| 3591 PWL_BEZIER * fWidth * 0.45f, | 3586 CPWL_Point(crInBox.left + fWidth * 0.45f - FX_BEZIER * fWidth * 0.45f, |
| 3592 crInBox.top - fHeight * 0.4f), | 3587 crInBox.top - fHeight * 0.4f), |
| 3593 PWLPT_BEZIERTO), | 3588 PWLPT_BEZIERTO), |
| 3594 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.4f), | 3589 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.4f), |
| 3595 PWLPT_BEZIERTO), | 3590 PWLPT_BEZIERTO), |
| 3596 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top), PWLPT_LINETO), | 3591 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top), PWLPT_LINETO), |
| 3597 | 3592 |
| 3598 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.60f, crInBox.top), | 3593 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.60f, crInBox.top), |
| 3599 PWLPT_MOVETO), | 3594 PWLPT_MOVETO), |
| 3600 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.75f, crInBox.top), | 3595 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.75f, crInBox.top), |
| 3601 PWLPT_LINETO), | 3596 PWLPT_LINETO), |
| 3602 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.75f, | 3597 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.75f, |
| 3603 crInBox.top - PWL_BEZIER * fHeight * 0.7f), | 3598 crInBox.top - FX_BEZIER * fHeight * 0.7f), |
| 3604 PWLPT_BEZIERTO), | 3599 PWLPT_BEZIERTO), |
| 3605 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.75f - | 3600 CPWL_PathData( |
| 3606 PWL_BEZIER * fWidth * 0.75f, | 3601 CPWL_Point(crInBox.left + fWidth * 0.75f - FX_BEZIER * fWidth * 0.75f, |
| 3607 crInBox.top - fHeight * 0.7f), | 3602 crInBox.top - fHeight * 0.7f), |
| 3608 PWLPT_BEZIERTO), | 3603 PWLPT_BEZIERTO), |
| 3609 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.7f), | 3604 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.7f), |
| 3610 PWLPT_BEZIERTO), | 3605 PWLPT_BEZIERTO), |
| 3611 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.55f), | 3606 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.55f), |
| 3612 PWLPT_LINETO), | 3607 PWLPT_LINETO), |
| 3613 CPWL_PathData(CPWL_Point(crInBox.left + PWL_BEZIER * fWidth * 0.60f, | 3608 CPWL_PathData(CPWL_Point(crInBox.left + FX_BEZIER * fWidth * 0.60f, |
| 3614 crInBox.top - fHeight * 0.55f), | 3609 crInBox.top - fHeight * 0.55f), |
| 3615 PWLPT_BEZIERTO), | 3610 PWLPT_BEZIERTO), |
| 3616 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.60f, | 3611 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.60f, |
| 3617 crInBox.top - PWL_BEZIER * fHeight * 0.55f), | 3612 crInBox.top - FX_BEZIER * fHeight * 0.55f), |
| 3618 PWLPT_BEZIERTO), | 3613 PWLPT_BEZIERTO), |
| 3619 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.60f, crInBox.top), | 3614 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.60f, crInBox.top), |
| 3620 PWLPT_BEZIERTO), | 3615 PWLPT_BEZIERTO), |
| 3621 | 3616 |
| 3622 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f, crInBox.top), | 3617 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f, crInBox.top), |
| 3623 PWLPT_MOVETO), | 3618 PWLPT_MOVETO), |
| 3624 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f, | 3619 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f, |
| 3625 crInBox.top - PWL_BEZIER * fHeight * 0.85f), | 3620 crInBox.top - FX_BEZIER * fHeight * 0.85f), |
| 3626 PWLPT_BEZIERTO), | 3621 PWLPT_BEZIERTO), |
| 3627 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f - | 3622 CPWL_PathData( |
| 3628 PWL_BEZIER * fWidth * 0.90f, | 3623 CPWL_Point(crInBox.left + fWidth * 0.90f - FX_BEZIER * fWidth * 0.90f, |
| 3629 crInBox.top - fHeight * 0.85f), | 3624 crInBox.top - fHeight * 0.85f), |
| 3630 PWLPT_BEZIERTO), | 3625 PWLPT_BEZIERTO), |
| 3631 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.85f), | 3626 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.top - fHeight * 0.85f), |
| 3632 PWLPT_BEZIERTO), | 3627 PWLPT_BEZIERTO), |
| 3633 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.bottom), PWLPT_LINETO), | 3628 CPWL_PathData(CPWL_Point(crInBox.left, crInBox.bottom), PWLPT_LINETO), |
| 3634 CPWL_PathData(CPWL_Point(crInBox.right, crInBox.bottom), PWLPT_LINETO), | 3629 CPWL_PathData(CPWL_Point(crInBox.right, crInBox.bottom), PWLPT_LINETO), |
| 3635 CPWL_PathData(CPWL_Point(crInBox.right, crInBox.top), PWLPT_LINETO), | 3630 CPWL_PathData(CPWL_Point(crInBox.right, crInBox.top), PWLPT_LINETO), |
| 3636 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f, crInBox.top), | 3631 CPWL_PathData(CPWL_Point(crInBox.left + fWidth * 0.90f, crInBox.top), |
| 3637 PWLPT_LINETO), | 3632 PWLPT_LINETO), |
| 3638 }; | 3633 }; |
| 3639 | 3634 |
| 3640 if (type == PWLPT_STREAM) | 3635 if (type == PWLPT_STREAM) |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3677 break; | 3672 break; |
| 3678 case COLORTYPE_RGB: | 3673 case COLORTYPE_RGB: |
| 3679 CPWL_Utils::ConvertCMYK2RGB(fColor1, fColor2, fColor3, fColor4, | 3674 CPWL_Utils::ConvertCMYK2RGB(fColor1, fColor2, fColor3, fColor4, |
| 3680 fColor1, fColor2, fColor3); | 3675 fColor1, fColor2, fColor3); |
| 3681 break; | 3676 break; |
| 3682 } | 3677 } |
| 3683 break; | 3678 break; |
| 3684 } | 3679 } |
| 3685 nColorType = other_nColorType; | 3680 nColorType = other_nColorType; |
| 3686 } | 3681 } |
| OLD | NEW |