eseidel | b8402f9 | 2005-07-09 06:56:18 +0000 | [diff] [blame] | 1 | /* |
eseidel | 044d7d2 | 2005-08-11 11:35:23 +0000 | [diff] [blame] | 2 | Copyright (C) 2004, 2005 Nikolas Zimmermann <wildfox@kde.org> |
| 3 | 2004, 2005 Rob Buis <buis@kde.org> |
eseidel | b8402f9 | 2005-07-09 06:56:18 +0000 | [diff] [blame] | 4 | |
| 5 | This file is part of the KDE project |
| 6 | |
| 7 | This library is free software; you can redistribute it and/or |
| 8 | modify it under the terms of the GNU Library General Public |
| 9 | License as published by the Free Software Foundation; either |
| 10 | version 2 of the License, or (at your option) any later version. |
| 11 | |
| 12 | This library is distributed in the hope that it will be useful, |
| 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 15 | Library General Public License for more details. |
| 16 | |
| 17 | You should have received a copy of the GNU Library General Public License |
| 18 | along with this library; see the file COPYING.LIB. If not, write to |
| 19 | the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
| 20 | Boston, MA 02111-1307, USA. |
| 21 | */ |
| 22 | |
eseidel | 0f4540f | 2005-10-05 05:36:55 +0000 | [diff] [blame] | 23 | #include "config.h" |
eseidel | 05aeca3 | 2006-01-22 14:08:24 +0000 | [diff] [blame] | 24 | #if SVG_SUPPORT |
mjs | 5be25ad | 2006-02-23 00:33:08 +0000 | [diff] [blame] | 25 | #include <QStringList.h> |
eseidel | b8402f9 | 2005-07-09 06:56:18 +0000 | [diff] [blame] | 26 | |
| 27 | #include "SVGMatrixImpl.h" |
| 28 | #include "SVGSVGElementImpl.h" |
| 29 | #include "SVGLengthListImpl.h" |
| 30 | |
eseidel | d76e27b | 2006-02-11 23:54:23 +0000 | [diff] [blame] | 31 | using namespace WebCore; |
eseidel | b8402f9 | 2005-07-09 06:56:18 +0000 | [diff] [blame] | 32 | |
| 33 | SVGLengthListImpl::SVGLengthListImpl(const SVGStyledElementImpl *context) |
| 34 | : SVGList<SVGLengthImpl>(context) |
| 35 | { |
| 36 | } |
| 37 | |
| 38 | SVGLengthListImpl::~SVGLengthListImpl() |
| 39 | { |
| 40 | } |
| 41 | |
| 42 | void SVGLengthListImpl::parse(const QString &value, const SVGStyledElementImpl *context, LengthMode mode) |
| 43 | { |
eseidel | 62607d1 | 2005-09-01 07:35:57 +0000 | [diff] [blame] | 44 | QStringList lengths = QStringList::split(' ', value); |
| 45 | for(unsigned int i = 0;i < lengths.count();i++) |
| 46 | { |
| 47 | SVGLengthImpl *length = new SVGLengthImpl(context, mode); |
eseidel | d76e27b | 2006-02-11 23:54:23 +0000 | [diff] [blame] | 48 | DOMString str(lengths[i]); |
eseidel | 3fdfa78 | 2005-11-21 08:29:43 +0000 | [diff] [blame] | 49 | length->setValueAsString(str.impl()); |
eseidel | 62607d1 | 2005-09-01 07:35:57 +0000 | [diff] [blame] | 50 | appendItem(length); |
| 51 | } |
eseidel | b8402f9 | 2005-07-09 06:56:18 +0000 | [diff] [blame] | 52 | } |
| 53 | |
| 54 | // vim:ts=4:noet |
eseidel | 05aeca3 | 2006-01-22 14:08:24 +0000 | [diff] [blame] | 55 | #endif // SVG_SUPPORT |
| 56 | |