cushy/examples/nested-scroll.rs
Jonathan Johnson 17847d6947
Various fixes/improvements
- On Linux, `fm-match` is used to query for the default fonts.
- DynamicComponents now have their own trait and can now be specified
  with a constant or dynamic.
- Roboto Flex is now always loaded when the feature is enabled.
  Overriding the default sans serif font prefers the overridden value,
  then roboto, then the result of fc-match/fontdb's default.
- Button now supports background colors being set on a transparent
  button.
2023-12-03 15:35:37 -08:00

23 lines
702 B
Rust

use gooey::styles::components::FontFamily;
use gooey::styles::FontFamilyList;
use gooey::widget::MakeWidget;
use gooey::Run;
use kludgine::cosmic_text::FamilyOwned;
use kludgine::figures::units::Lp;
fn main() -> gooey::Result {
include_str!("./nested-scroll.rs")
.vertical_scroll()
.with(&FontFamily, FontFamilyList::from(FamilyOwned::Monospace))
.height(Lp::inches(3))
.and(
include_str!("./canvas.rs")
.vertical_scroll()
.with(&FontFamily, FontFamilyList::from(FamilyOwned::Monospace))
.height(Lp::inches(3)),
)
.into_rows()
.vertical_scroll()
.expand()
.run()
}