[gnome-icon-theme-symbolic/wip/avoid-verbs] avoid verbs for export.
- From: Jakub Steiner <jimmac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-icon-theme-symbolic/wip/avoid-verbs] avoid verbs for export.
- Date: Thu, 3 Apr 2014 14:11:39 +0000 (UTC)
commit 1e42f70ea5c11300670c96d35395f9e162721f27
Author: Jakub Steiner <jimmac gmail com>
Date: Thu Apr 3 15:13:58 2014 +0200
avoid verbs for export.
+ 50 fold speedup
+ no windows popping up
- plain svg doesn't retain classes: https://bugs.launchpad.net/inkscape/+bug/419266
- export-only-id doesn't work: https://bugs.launchpad.net/inkscape/+bug/1191783
r.rb | 9 +++------
1 files changed, 3 insertions(+), 6 deletions(-)
---
diff --git a/r.rb b/r.rb
index c8236a5..8aa14ff 100755
--- a/r.rb
+++ b/r.rb
@@ -4,20 +4,17 @@ require "rexml/document"
require "fileutils"
include REXML
-
INKSCAPE = '/usr/bin/inkscape'
-#INKSCAPE = '/usr/bin/inkscape' # like this works for me, while using `which` inkscape hangs
SRC = "src/gnome-stencils.svg"
PREFIX = "gnome/scalable"
def chopSVG(icon)
FileUtils.mkdir_p(icon[:dir]) unless File.exists?(icon[:dir])
unless (File.exists?(icon[:file]) && !icon[:forcerender])
- FileUtils.cp(SRC,icon[:file])
+ #FileUtils.cp(SRC,icon[:file])
puts " >> #{icon[:name]}"
- cmd = "#{INKSCAPE} -f #{icon[:file]} --select #{icon[:id]} --verb=FitCanvasToSelection
--verb=EditInvertInAllLayers "
- cmd += "--verb=EditDelete --verb=EditSelectAll --verb=SelectionUnGroup
--verb=SelectionUnGroup --verb=SelectionUnGroup --verb=StrokeToPath --verb=FileVacuum "
- cmd += "--verb=FileSave --verb=FileClose > /dev/null 2>&1"
+ cmd = "#{INKSCAPE} -l #{icon[:file]} -i #{icon[:id]} -j #{SRC}"
+ puts "DEBUG #{cmd}"
system(cmd)
#saving as plain SVG gets rid of the classes :/
#cmd = "#{INKSCAPE} -f #{icon[:file]} -z --vacuum-defs -l #{icon[:file]} > /dev/null 2>&1"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]