lib/danica/negative.rb in danica-2.0.6 vs lib/danica/negative.rb in danica-2.1.0

- old
+ new

@@ -1,14 +1,15 @@ module Danica class Negative include Common + include BaseOperations include VariablesHolder include ActiveModel::Model attr_accessor :value - default_value :priority, 1 + default_value :priority, 2 default_value :is_grouped?, false delegate :valued?, to: :value def initialize(value) @@ -18,14 +19,14 @@ def to_f -value.to_f end def to_tex - "-#{value.to_tex}" + "-#{wrap_as_group(value).to_tex}" end def to_gnu - "-#{value.to_gnu}" + "-#{wrap_as_group(value).to_gnu}" end def ==(other) return false unless other.class == self.class value == other.value