| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 3 * | 3 * |
| 4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
| 5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
| 6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
| 7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
| 8 * | 8 * |
| 9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 switch (type) { | 84 switch (type) { |
| 85 case StartMarker: | 85 case StartMarker: |
| 86 return markerStart; | 86 return markerStart; |
| 87 case MidMarker: | 87 case MidMarker: |
| 88 return markerMid; | 88 return markerMid; |
| 89 case EndMarker: | 89 case EndMarker: |
| 90 return markerEnd; | 90 return markerEnd; |
| 91 } | 91 } |
| 92 | 92 |
| 93 ASSERT_NOT_REACHED(); | 93 ASSERT_NOT_REACHED(); |
| 94 return 0; | 94 return nullptr; |
| 95 } | 95 } |
| 96 | 96 |
| 97 private: | 97 private: |
| 98 float currentAngle(SVGMarkerType type) const | 98 float currentAngle(SVGMarkerType type) const |
| 99 { | 99 { |
| 100 // For details of this calculation, see: http://www.w3.org/TR/SVG/single
-page.html#painting-MarkerElement | 100 // For details of this calculation, see: http://www.w3.org/TR/SVG/single
-page.html#painting-MarkerElement |
| 101 FloatPoint inSlope(m_inslopePoints[1] - m_inslopePoints[0]); | 101 FloatPoint inSlope(m_inslopePoints[1] - m_inslopePoints[0]); |
| 102 FloatPoint outSlope(m_outslopePoints[1] - m_outslopePoints[0]); | 102 FloatPoint outSlope(m_outslopePoints[1] - m_outslopePoints[0]); |
| 103 | 103 |
| 104 double inAngle = rad2deg(inSlope.slopeAngleRadians()); | 104 double inAngle = rad2deg(inSlope.slopeAngleRadians()); |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 166 FloatPoint m_origin; | 166 FloatPoint m_origin; |
| 167 FloatPoint m_subpathStart; | 167 FloatPoint m_subpathStart; |
| 168 FloatPoint m_inslopePoints[2]; | 168 FloatPoint m_inslopePoints[2]; |
| 169 FloatPoint m_outslopePoints[2]; | 169 FloatPoint m_outslopePoints[2]; |
| 170 bool m_autoStartReverse; | 170 bool m_autoStartReverse; |
| 171 }; | 171 }; |
| 172 | 172 |
| 173 } | 173 } |
| 174 | 174 |
| 175 #endif // SVGMarkerData_h | 175 #endif // SVGMarkerData_h |
| OLD | NEW |