diff options
| author | Aaron Spike <aaron@ekips.org> | 2007-06-24 13:17:46 +0000 |
|---|---|---|
| committer | acspike <acspike@users.sourceforge.net> | 2007-06-24 13:17:46 +0000 |
| commit | 202a58068cae7c675b4e36e9bac44e1e6a7214df (patch) | |
| tree | de3b4a25d4d71938568562b21c0b3a5e0dcc7134 /share/extensions/pathalongpath.py | |
| parent | Right clicking on the swatch now correctly sets the outline colour. (diff) | |
| download | inkscape-202a58068cae7c675b4e36e9bac44e1e6a7214df.tar.gz inkscape-202a58068cae7c675b4e36e9bac44e1e6a7214df.zip | |
more pyxml to lxml conversion.
I'd like to get someone else to look at Barcode and the TeX extension.
Some of the big name extensions like pathalongpath.py still don't work but I have started converting (and somehow broke them). committing in case someone wants to help fix. :-)
(bzr r3092)
Diffstat (limited to 'share/extensions/pathalongpath.py')
| -rw-r--r-- | share/extensions/pathalongpath.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/share/extensions/pathalongpath.py b/share/extensions/pathalongpath.py index af42a2dee..3901069c9 100644 --- a/share/extensions/pathalongpath.py +++ b/share/extensions/pathalongpath.py @@ -34,7 +34,7 @@ they move and rotate, deforming the pattern. import inkex, cubicsuperpath, bezmisc
import pathmodifier
-import copy, math, re, random, xml.xpath
+import copy, math, re, random
def flipxy(path):
for pathcomp in path:
@@ -212,15 +212,15 @@ class PathAlongPath(pathmodifier.Diffeo): dx=width+self.options.space
for id, node in self.patterns.iteritems():
- if node.tagName == 'path':
- d = node.attributes.getNamedItem('d')
- p0 = cubicsuperpath.parsePath(d.value)
+ if node.tag == inkex.addNS('path','svg'):
+ d = node.get('d')
+ p0 = cubicsuperpath.parsePath(d)
if self.options.vertical:
flipxy(p0)
newp=[]
for skelnode in self.skeletons.itervalues():
- self.curSekeleton=cubicsuperpath.parsePath(skelnode.getAttribute('d'))
+ self.curSekeleton=cubicsuperpath.parsePath(skelnode.get('d'))
if self.options.vertical:
flipxy(self.curSekeleton)
for comp in self.curSekeleton:
@@ -261,7 +261,7 @@ class PathAlongPath(pathmodifier.Diffeo): flipxy(p)
newp+=p
- d.value = cubicsuperpath.formatPath(newp)
+ node.set('d', cubicsuperpath.formatPath(newp))
e = PathAlongPath()
e.affect()
|
