class RatatuiRuby::Widgets::BarChart::Bar
A bar in a grouped bar chart.
Examples
BarChart::Bar.new(value: 10, style: Style.new(fg: :red), label: "A")
Attributes
The label of the bar (optional String, Text::Span, or Text::Line for rich styling).
The value of the bar (Integer).
The style of the value (optional Style).
Public Class Methods
Source
# File lib/ratatui_ruby/widgets/bar_chart/bar.rb, line 39 def initialize(value:, label: nil, style: nil, value_style: nil, text_value: nil) super( value: Integer(value), label:, style:, value_style:, text_value: ) end
:attr_reader: text_value The text to display as the value (optional String, Text::Span, or Text::Line for rich styling).
Calls superclass method