Module: Vectory

Defined in:
lib/vectory.rb,
lib/vectory/ps.rb,
lib/vectory/cli.rb,
lib/vectory/emf.rb,
lib/vectory/eps.rb,
lib/vectory/svg.rb,
lib/vectory/image.rb,
lib/vectory/utils.rb,
lib/vectory/vector.rb,
lib/vectory/datauri.rb,
lib/vectory/version.rb,
lib/vectory/file_magic.rb,
lib/vectory/svg_mapping.rb,
lib/vectory/system_call.rb,
lib/vectory/inkscape_converter.rb

Defined Under Namespace

Classes: CLI, ConversionError, Datauri, Emf, Eps, Error, FileMagic, Image, InkscapeConverter, InkscapeNotFoundError, InkscapeQueryError, NotImplementedError, NotWrittenToDiskError, Ps, Svg, SvgMapping, SystemCall, SystemCallError, Utils, Vector

Constant Summary collapse

VERSION =
"0.4.1"

Class Method Summary collapse

Class Method Details

.convert(image, format) ⇒ Object



41
42
43
# File 'lib/vectory.rb', line 41

def self.convert(image, format)
  image.convert(format)
end

.root_pathObject



37
38
39
# File 'lib/vectory.rb', line 37

def self.root_path
  Pathname.new(File.dirname(__dir__))
end

.uiObject



30
31
32
33
34
35
# File 'lib/vectory.rb', line 30

def self.ui
  @ui ||= Logger.new(STDOUT).tap do |logger|
    logger.level = ENV['VECTORY_LOG'] || Logger::WARN
    logger.formatter = proc { |severity, datetime, progname, msg| "#{msg}\n" }
  end
end