Make font_matches accessible via function only
This commit is contained in:
parent
808e75a54d
commit
80e0a31188
1 changed files with 5 additions and 1 deletions
|
|
@ -237,7 +237,7 @@ impl TextBufferLine {
|
|||
|
||||
/// A buffer of text that is shaped and laid out
|
||||
pub struct TextBuffer<'a> {
|
||||
pub font_matches: FontMatches<'a>,
|
||||
font_matches: FontMatches<'a>,
|
||||
attrs: Attrs<'a>,
|
||||
lines: Vec<TextBufferLine>,
|
||||
metrics: TextMetrics,
|
||||
|
|
@ -507,6 +507,10 @@ impl<'a> TextBuffer<'a> {
|
|||
self.height / self.metrics.line_height
|
||||
}
|
||||
|
||||
pub fn font_matches(&self) -> &FontMatches<'a> {
|
||||
&self.font_matches
|
||||
}
|
||||
|
||||
pub fn attrs(&self) -> &Attrs<'a> {
|
||||
&self.attrs
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue