- #168 Fix breaking long words with wide utf8 characters
- #167 Offset the line to fit the glyph with negative side bearing
- #165 Relaxed trait bounds on PixelColor
- #164 Internal improvements
- #163 Internal improvements
- #162 Internal improvements
- #161 Internal improvements
- #160 Internal improvements
- #159 Internal improvements
- #158 The following functions can now be called from
const
code:Ansi::new()
- #158 The following types are now
Copy
:Tail
- #158 breaking Update embedded-graphics dependency to 0.8.
- #158 breaking Bump Minimum Supported Rust Version (MSRV) to 1.61.
- #158 breaking The
ansi
feature is no longer enabled by default
- #157 Fixed carrying whitespace to the next line
- #155 Removed
TextBox::fit_height
andTextBox::fit_height_limited
- #148 Added
TextBoxStyleBuilder::leading_spaces()
andTextBoxStyleBuilder::trailing_spaces()
- #148 Added
TextBoxStyle::leading_spaces
andTextBoxStyle::trailing_spaces
- #150 Removed unused
as-slice
dependency
- #133 Added the following
const
functions:TextBoxStyle::default()
TextBoxStyleBuilder::default()
TabSize::default()
- #134
Tail
plugin - #135 Allow using the built-in plugins without the
plugin
feature. - #137 Allow using multiple plugins.
- #136
Cursor
is now public. - #136 Added
TextBox::take_plugins()
. - #138
Ansi
plugin to parse ANSI escape sequences. - #138
Token::MoveCursor
andToken::ChangeTextStyle
- breaking #133
TextBoxStyle
andTextBoxStyleBuilder
no longer implement theDefault
trait. - #136 Replaced
TextBoxProperties::box_height
with inTextBoxProperties::bounding_box
. - #136 Reworked the editor example to support vertical cursor movement and mouse input.
- #140 Fixed an issue where, under certain circumstances no text was rendered.
- #134
Scrolling
vertical alignment
- #130
ChangeTextStyle
token - #114 Added experimental plugin support via the
plugin
Cargo feature. Plugin can be used to modifyTextBox
behaviour.
- #114
TextBox
no longer implementsPartialEq
andEq
- breaking Replaced
{Horizontal, Vertical}TextAlignment
traits with{Horizontal, Vertical}Alignment
enums. Vertical centering option has been renamed toMiddle
. - breaking Moved
VerticalOverdraw
andHeightMode
to thestyle
module. - breaking Replaced type-state
VerticalOverdraw
,HeightMode
with an enum. - breaking Replaced
TextStyle::line_spacing
withline_height
. - breaking Added
#[non_exhaustive]
toTextBoxStyle
. - breaking Need to pass character style to text box constructors.
- breaking Changed
TextBoxStyleBuilder
API to better align with embedded-graphics'TextStyleBuilder
. - breaking Changed measurement of lines that only contain whitespace.
- breaking (developer-facing) Simplified
HorizontalTextAlignment
API. - breaking (developer-facing) Split off
LineCursor
fromCursor
. - breaking The
TabSize
type is now an enum and doesn't depend on a font. - breaking Raised MSRV to 1.43.
- breaking Updated to embedded-graphics 0.7.
Changes in embedded-graphics required changing the type signatures of almost every embedded-text type. For example, former
Font
andPixelColor
type bounds have been replaced byTextRenderer
,CharacterStyle
and theirColor
associated type. - breaking Replaced
style::color::Rgb
withembedded_graphics::pixelcolor::Rgb888
. - ANSI sequence support now requires the
ansi
feature which is enabled by default.
- breaking Removed benchmarks.
- breaking Removed
prelude
. - breaking Removed
Rectangle
extensions. - breaking Removed deprecated
TextBoxStyleBuilder::{text_style, background_color, text_color, from_text_style, underlined, strikethrough}
. UseTextBoxStyleBuilder::character_style
instead. - breaking (developer-facing) The following types and modules have been removed or hidden:
rendering::ansi
,rendering::cursor
,rendering::character
,rendering::decorated_space
,rendering::line
,rendering::line_iter
,rendering::space_config
- Removed
TextBox::into_styled()
interactive_*
examples: fix accidental moving of bounding box.editor
example: cursor now doesn't stick to the text.- The
ansi
feature can now be used inno_std
environments.
- Added
TextBox::vertical_offset
andTextBox::set_vertical_offset
. - Added
TextBoxStyle::paragraph_spacing
andTextBoxStyleBuilder::paragraph_spacing
. - Added
From<&TextBoxStyle>
impl forTextBoxStyleBuilder
TextBox::{with_alignment, with_vertical_alignment}
TextBoxStyle::{with_alignment, with_vertical_alignment}
TextBox::with_textbox_style()
TextBoxStyleBuilder
now implementsDefault
StyledTextBox::draw()
now returns unconsumed text.- Added
interactive_columns
example to show flowing text into multiple columns.
- Updated
ansi-parser
dependency to0.8.0
. - ANSI sequence support now requires the
ansi
feature which is on by default. - Fields of the
style::color::Rgb
struct are now public.
- The
ansi
feature can now be used inno_std
environments.
- Added support for strikethrough and underlined text.
RendererFactory
trait that can be used to create a pixel iterator.- Handle tabs
\t
with configurable tab size. - Added
TabSize
struct and related style builder methodtab_size
. - Added partial support for ANSI escape codes.
Scrolling
vertical alignmentTextBoxStyleBuilder
now implementsCopy
andClone
TextBox
andStyledTextBox
now implementsCopy
,Clone
,Debug
,Eq
,PartialEq
andHash
- breaking Left aligned text now eats a single white space at the end of a wrapped line. This changes some height measurements and rendering output.
- breaking
TextBoxStyle::measure_line
now returns whether the line is underlined. - breaking Renamed
StyledCharacterIterator
toCharacterIterator
- breaking Increase the Minimum Supported Rust Version to
1.41.0
- breaking
rendering::line_iter::State
is no longer public - breaking
rendering::line::State
is no longer public - breaking Removed
StateFactory
- breaking Removed
FontExt::str_width
,FontExt::max_str_width
andFontExt::max_str_width_nocr
- breaking
TextBoxStyle
andTextBoxStyleBuilder
no longer derivesOrd
andPartialOrd
TextBoxStyleBuilder::from_text_style
- Added
HeightMode
to select whether and how theStyledTextBox
height should be aligned to the actual text height. - Added
Hidden
,Visible
andFullRowsOnly
overflow control modes toExact
andShrinkToText
height modes. - Added line spacing support via
TextBoxStyleBuilder::line_spacing
- Soft hyphen character support (
\u{AD}
), rendered as a normal-
.
- Deprecated
TextBoxStyleBuilder::text_style
. UseTextBoxStyleBuilder::from_text_style
instead. - breaking Moved
StyledTextBox
to the root module. - Added
StyledTextBox::fit_height
andStyledTextBox::fit_height_limited
to adjust height to text
- Fix
CenterAligned
andBottomAligned
vertical alignments crashing the program when text is taller than theTextBox
.
- Support for vertical text alignment.
- Added alignment types to
prelude
. - Support for zero-width space character (
\u{200B}
). - Support for nonbreaking space character (
\u{A0}
). - Added optimized measurement function that do not expect carriage returns.
FontExt::measure_line_nocr
FontExt::str_width_nocr
FontExt::max_str_width_nocr
- Support carriage return (
\r
) control characters.
- Fixed an issue where height measurement unexpectedly carried a space that is consumed during drawing.
- Added
TextBoxStyle::from_text_style
- breaking: Renamed
measure_text
tomeasure_text_height
- breaking: Moved
measure_text
fromFontExt
toTextBoxStyle
- breaking: Removed
FontExt
fromprelude
- Fixed an issue where after a line break, the last line was not rendered if the exact height was available.
- Fixed several text height measurement issues and inconsistencies.
- Fixed an issue where text height was measured incorrectly when encountering words wider than line.
- Fixed an issue where characters could be drawn outside of the bounding box when there is not enough space to render a single character.
- Fixed a word wrapping issue where the first space may sometimes be rendered 0 width.
- Crash with
Justified
alignment.
prelude
import- Render fonts with variable character width
FontExt::measure_text
to measure height using a certain width. Implemented for allFont
instances.
- Initial release