diff --git a/Makefile b/Makefile index c6c160e..6d97101 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ all : inkscape-layers -inkscape-layers : inkscape-layers.cpp trim-cpp/trim.hpp +inkscape-layers : inkscape-layers.cpp g++ -std=c++11 $^ `pkg-config libxml++-2.6 --cflags --libs` -o $@ clean : diff --git a/inkscape-layers.cpp b/inkscape-layers.cpp index a6fc3a9..b20c1d8 100644 --- a/inkscape-layers.cpp +++ b/inkscape-layers.cpp @@ -14,7 +14,6 @@ #include #include -#include "trim-cpp/trim.hpp" #define NAME_MODE_DEFAULT 0 #define NAME_MODE_LABEL 1 @@ -212,7 +211,15 @@ Mode if ( outputDirectory.length() == 0 ) outputDirectory = inputFilename.substr(0, pathEnd); outputBaseName = inputFilename.substr(pathEnd, extensionStart - pathEnd); + + /* HACK :( */ + /* commented for filename without prefix layerFilenamePrefix = outputDirectory + outputBaseName + "-"; + */ + + layerFilenamePrefix = outputDirectory; + + /*KCAH :( */ if ( extensionStart == std::string::npos ) { layerFilenameSuffix = ""; @@ -264,7 +271,7 @@ isVisible ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; style = layer->get_attribute_value("style").raw(); - Trim::inPlace(style); + // Trim::inPlace(style); if ( (displayBegin = style.find("display")) == std::string::npos ) return true; if ( (valueBegin = style.find(':', displayBegin)) == std::string::npos ) return true; @@ -273,7 +280,7 @@ isVisible valueLength = valueEnd - valueBegin; value = style.substr(valueBegin, valueLength); - Trim::inPlace(value); + // Trim::inPlace(value); return value.compare("none") != 0; } @@ -290,7 +297,7 @@ makeVisible ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; style = layer->get_attribute_value("style").raw(); - Trim::inPlace(style); + // Trim::inPlace(style); if ( (displayBegin = style.find("display")) == std::string::npos ) return; if ( (valueBegin = style.find(':', displayBegin)) == std::string::npos ) return; diff --git a/trim-cpp b/trim-cpp deleted file mode 160000 index 6933938..0000000 --- a/trim-cpp +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 6933938dec3516a2a67d9899fd3e9124554178e5