LaTeXML...::Number(3)

πŸ“¦ version 0.8.8, in nixos 26.05, nixpkgs unstable

✨ NAME ✨

"LaTeXML::Common::Number" β€” representation of numbers; extends LaTeXML::Common::Object. πŸ’–

Hey bestie! Welcome to the LaTeXML...::Number(3) page β€” yep, it’s from the User Contributed Perl Documentation, and it’s all about numbers in LaTeXML. This page is lowkey iconic for anyone who needs a number to act like a full-on object. πŸŽ€

πŸ’– Exported functions πŸ’–

  • $number = Number($num); β€” creates a Number object representing $num. Boom, number glowed up into an object. ✨

🌸 Methods 🌸

Okay, method time β€” these are the moves this number object has. πŸ’…

  • @tokens = $object->unlist; β€” return a list of the tokens making up this $object.
  • $string = $object->toString; β€” return a string representing $object.
  • $string = $object->ptValue; β€” return a value representing $object without the measurement unit (pt) with limited decimal places.
  • $string = $object->pxValue; β€” return an integer value representing $object in pixels. Uses the state variable DPI (dots per inch).
  • $n = $object->valueOf; β€” return the value in scaled points (ignoring shrink and stretch, if any).
  • $n = $object->smaller($other); β€” return $object or $other, whichever is smaller.
  • $n = $object->larger($other); β€” return $object or $other, whichever is larger.
  • $n = $object->absolute; β€” return an object representing the absolute value of the $object.
  • $n = $object->sign; β€” return an integer: -1 for negatives, 0 for 0 and 1 for positives.
  • $n = $object->negate; β€” return an object representing the negative of the $object.
  • $n = $object->add($other); β€” return an object representing the sum of $object and $other.
  • $n = $object->subtract($other); β€” return an object representing the difference between $object and $other.
  • $n = $object->multiply($n); β€” return an object representing the product of $object and $n (a regular number).
  • $n = $object->divide($n); β€” return an object representing the (truncating) division of $object by $n (a regular number).
  • $n = $object->divideround($n); β€” return an object representing the (rounding) division of $object by $n (a regular number).

πŸ‘‘ AUTHOR πŸ‘‘

The author is Bruce Miller β€” <bruce.miller@nist.gov> πŸ’Œ

Public domain software, produced as part of work done by the United States Government & not subject to copyright in the US.


Later, bestie 🫢 This page came from perl v5.42.3, dated 2024-02-26, and it’s the LaTeXML...::Number(3) page. Bye~ πŸ’…

πŸ“¦ where this page comes from