mirror of
https://codeberg.org/unspeaker/tengri.git
synced 2026-01-31 10:56:41 +01:00
0.6.0: add trim_string
This commit is contained in:
parent
ea01deb854
commit
b8ad5dae9f
4 changed files with 26 additions and 12 deletions
|
|
@ -1,12 +1,10 @@
|
|||
use crate::*;
|
||||
use ratatui::prelude::Position;
|
||||
|
||||
macro_rules! impl_content_layout_render {
|
||||
(
|
||||
$Output:ty: |$self:ident: $Struct:ty, $to:ident|
|
||||
layout = $layout:expr;
|
||||
render = $render:expr
|
||||
) => {
|
||||
($Output:ty: |$self:ident: $Struct:ty, $to:ident|
|
||||
layout = $layout:expr;
|
||||
render = $render:expr) =>
|
||||
{
|
||||
impl Content<$Output> for $Struct {
|
||||
fn layout (&$self, $to: [u16;4]) -> [u16;4] { $layout }
|
||||
fn render (&$self, $to: &mut $Output) { $render }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue