Style

org.appliedtopology.tda4j.plot.Style
See theStyle companion object
final case class Style(font: String = ..., textScale: Double = ..., markScale: Double = ..., grid: Boolean = ..., legend: Optional[LegendPosition] = ..., transparent: Optional[Boolean] = ...) extends Tweak

The look of a figure that is not its data: the font, the size of the text and of the marks, the gridlines, the legend's place and the background. A style says nothing about what is drawn, so one value serves every figure of a paper or a talk: fig + Style.slides.

A style replaces the figure's whole style; to change one setting of a style, Style.slides.copy(grid = false). (Theme is something else: whether colors are light, dark, or follow the reader.)

Value parameters

font

the CSS font-family of every text

grid

false to draw no gridlines on either axis

legend

where the legend goes; unset, a plot has its own place (beside the plot, or at the lower right of a persistence diagram)

markScale

a factor on the size of markers and the width of lines

textScale

a factor on every text size, and on the margins that make room for text

transparent

true to draw no background anywhere, so that the figure takes the color of the page behind it; false to draw the palette's surface everywhere; unset, a figure shown on a page or in the viewer has it (cream, for the default palette) and a saved .svg has none, as a figure deployed elsewhere should take the color of its new page

Attributes

Companion
object
Experimental
true
Source
Style.scala
Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait Tweak
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def hasBackground(saved: Boolean): Boolean

Whether a figure in this style draws its background, in a saved file (saved) or on a page.

Whether a figure in this style draws its background, in a saved file (saved) or on a page.

Attributes

Source
Style.scala

figure with this change.

figure with this change.

Attributes

Source
Style.scala
override def onScene(s: Scene): Scene

scene with this change: only tweaks of the labels, the size and the look apply to a 3-D scene.

scene with this change: only tweaks of the labels, the size and the look apply to a 3-D scene.

Attributes

Definition Classes
Source
Style.scala

Inherited methods

def +(that: Tweak): Tweak

This change, then that one.

This change, then that one.

Attributes

Inherited from:
Tweak
Source
Tweak.scala
def onBoard(board: Board): Board

board with this change in every figure of it.

board with this change in every figure of it.

Attributes

Inherited from:
Tweak
Source
Tweak.scala

page with this change in every panel of it; a tweak a 3-D panel cannot have leaves that panel as it is.

page with this change in every panel of it; a tweak a 3-D panel cannot have leaves that panel as it is.

Attributes

Inherited from:
Tweak
Source
Tweak.scala
def productElementNames: Iterator[String]

An iterator over the names of all the elements of this product.

An iterator over the names of all the elements of this product.

Attributes

Inherited from:
Product
Source
Product.scala
def productIterator: Iterator[Any]

An iterator over all the elements of this product.

An iterator over all the elements of this product.

Attributes

Returns

in the default implementation, an Iterator[Any]

Inherited from:
Product
Source
Product.scala