dgmxjj/moonbit-posterkit/scene does not have a README file

    DocumentStats

    pub(all) struct DocumentStats {
    element_count : Int
    block_count : Int
    text_count : Int
    image_slot_count : Int
    text_characters : Int
    occupied_area : Int
    ids : Array[String]
    } derive(Eq,
    Debug
    )

    DocumentStats::empty

    Element

    pub(all) enum Element {
    Block(id~ : String, rect~ : Rect, fill~ :
    Color
    , radius~ : Int)
    Text(id~ : String, content~ : String, position~ : Point, style~ : TextStyle, max_width~ : Int)
    ImageSlot(id~ : String, asset_id~ : String, rect~ : Rect, label~ : String, fit~ : ImageFit)
    } derive(Eq,
    Debug
    )

    ImageFit

    pub(all) enum ImageFit {
    Cover
    Contain
    } derive(Eq,
    Debug
    )

    Point

    pub(all) struct Point {
    x : Int
    y : Int
    } derive(Eq,
    Debug
    )

    Point::at

    fn Point::at(x : Int, y : Int) -> Point

    PosterDocument

    PosterDocument::push

    fn PosterDocument::push(document : PosterDocument, element : Element) -> PosterDocument

    PosterDocument::push_iter

    fn PosterDocument::push_iter(document : PosterDocument, new_elements : Iter[Element]) -> PosterDocument

    Rect

    pub(all) struct Rect {
    x : Int
    y : Int
    width : Int
    height : Int
    } derive(Eq,
    Debug
    )

    SceneDiagnostic

    pub(all) enum SceneDiagnostic {
    EmptyTitle
    EmptyElementId(index~ : Int)
    DuplicateElementId(id~ : String)
    InvalidRect(id~ : String)
    EmptyAssetId(id~ : String)
    EmptyImageLabel(id~ : String)
    TextOutsideCanvas(id~ : String)
    } derive(Eq,
    Debug
    )

    TextAlign

    pub(all) enum TextAlign {
    Left
    Center
    Right
    } derive(Eq,
    Debug
    )

    TextStyle

    pub(all) struct TextStyle {
    family : String
    size : Int
    weight : Int
    line_height : Int
    align : TextAlign
    color :
    Color

    } derive(Eq,
    Debug
    )

    analyze_document

    fn analyze_document(document : PosterDocument) -> DocumentStats

    diagnostic_code

    fn diagnostic_code(diagnostic : SceneDiagnostic) -> String

    document_without_empty_text

    fn document_without_empty_text(document : PosterDocument) -> PosterDocument

    element_ids

    fn element_ids(document : PosterDocument) -> Array[String]

    element_ids_sorted

    fn element_ids_sorted(document : PosterDocument) -> Array[String]

    find_element

    fn find_element(document : PosterDocument, id : String) -> Element?

    image_slot_count

    fn image_slot_count(document : PosterDocument) -> Int

    normalization_summary

    fn normalization_summary(document : PosterDocument) -> String

    normalize_document_ids

    fn normalize_document_ids(document : PosterDocument) -> PosterDocument

    normalize_for_render

    fn normalize_for_render(document : PosterDocument) -> PosterDocument

    normalized_id

    fn normalized_id(raw : String, fallback : String) -> String

    normalized_title

    fn normalized_title(document : PosterDocument, fallback : String) -> String

    text_character_count

    fn text_character_count(document : PosterDocument) -> Int

    validate_document

    fn validate_document(document : PosterDocument, strict~ : Bool) -> Array[SceneDiagnostic]