mirror of
https://codeberg.org/unspeaker/tengri.git
synced 2026-09-18 05:16:44 +02:00
This commit is contained in:
parent
de591addb3
commit
8a6eb19e27
3 changed files with 88 additions and 70 deletions
31
src/lib.rs
31
src/lib.rs
|
|
@ -29,37 +29,6 @@ pub(crate) use ::{
|
|||
std::marker::PhantomData
|
||||
};
|
||||
|
||||
#[cfg(all(feature = "draw", feature = "eval"))]
|
||||
macro_rules! fn_kw_layout {
|
||||
($name:ident |$state:ident, $output: ident, $expr:ident| $body:block) => {
|
||||
#[cfg(all(feature = "draw", feature = "eval"))]
|
||||
pub fn $name <O: Screen, S> (
|
||||
$state: &S, $output: &mut O, $expr: &str
|
||||
) -> Perhaps<XYWH<O::Unit>> where
|
||||
S: Interpret<O, Option<XYWH<O::Unit>>>
|
||||
+ for<'b> Namespace<'b, bool>
|
||||
+ for<'b> Namespace<'b, O::Unit>
|
||||
+ for<'b> Namespace<'b, Option<O::Unit>>
|
||||
$body
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(all(feature = "draw", feature = "eval", feature = "term"))]
|
||||
macro_rules! fn_kw_layout_tui {
|
||||
($name:ident |$state:ident, $output: ident, $expr:ident| $body:block) => {
|
||||
#[cfg(all(feature = "draw", feature = "eval", feature = "term"))]
|
||||
pub fn $name <S> (
|
||||
$state: &S, $output: &mut Tui, $expr: &str
|
||||
) -> Perhaps<XYWH<u16>> where
|
||||
S: Interpret<Tui, Option<XYWH<u16>>>
|
||||
+ for<'b> Namespace<'b, bool>
|
||||
+ for<'b> Namespace<'b, u16>
|
||||
+ for<'b> Namespace<'b, Option<u16>>
|
||||
+ for<'b> Namespace<'b, Color>
|
||||
$body
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "lang")] pub use ::dizzle::{Usually, Perhaps};
|
||||
#[cfg(feature = "lang")] use ::dizzle::*;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue