moonbitlang/pdflite/shape does not have a README file

    PdfRectangle

    A normalized rectangle in PDF user-space coordinates.

    min_x and min_y are always the lower bounds, and max_x and max_y are always the upper bounds. Parsers normalize PDF rectangle arrays whose coordinates are written in the opposite order.

    Point2

    A two-dimensional point in PDF user-space coordinates.

    TransformMatrix

    A PDF affine transform matrix.

    The fields correspond to PDF's six-operand matrix [a b c d e f], where a point is transformed as x' = a*x + c*y + e and y' = b*x + d*y + f.

    PdfDrawnPath

    pub(all) struct PdfDrawnPath {
    stroked : Bool
    filled : Bool
    path : PdfPath
    } derive(Eq, ToJson,
    Debug
    )

    A cpdfcontent drawn path, pairing path geometry with paint flags.

    PdfDrawnPath::content_json

    fn PdfDrawnPath::content_json(self : PdfDrawnPath) -> Json

    Return cpdfcontent's JSON shape for a drawn path.

    PdfDrawnPath::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfDrawnPath::equal(PdfDrawnPath, PdfDrawnPath) -> Bool

    PdfDrawnPath::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfDrawnPath::not_equal(x : PdfDrawnPath, y : PdfDrawnPath) -> Bool

    PdfDrawnPath::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfDrawnPath::to_json(PdfDrawnPath) -> Json

    PdfDrawnPath::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfDrawnPath::to_repr(PdfDrawnPath) ->
    Repr

    PdfPath

    pub(all) struct PdfPath {
    winding_rule : PdfPathWindingRule
    subpaths : Array[PdfPathSubpath]
    } derive(Eq, ToJson,
    Debug
    )

    A cpdf-style path.

    PdfPath::bounds

    Return cpdfcontent's axis-aligned bounding box for a path.

    Empty paths return a zero rectangle, matching cpdfcontent.ml.

    PdfPath::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPath::equal(PdfPath, PdfPath) -> Bool

    PdfPath::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPath::not_equal(x : PdfPath, y : PdfPath) -> Bool

    PdfPath::pdf_path_bounds_optional

    Return the bounds of a path, or None when it has no drawable segments.

    PdfPath::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPath::to_json(PdfPath) -> Json

    PdfPath::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPath::to_repr(PdfPath) ->
    Repr

    PdfPath::transform

    Transform every point in a path.

    PdfPathClosure

    pub(all) enum PdfPathClosure {
    PdfPathClosed
    PdfPathOpen
    } derive(Eq, ToJson,
    Debug
    )

    Whether a subpath is open or closed.

    PdfPathClosure::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathClosure::equal(PdfPathClosure, PdfPathClosure) -> Bool

    PdfPathClosure::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathClosure::not_equal(x : PdfPathClosure, y : PdfPathClosure) -> Bool

    PdfPathClosure::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathClosure::to_json(PdfPathClosure) -> Json

    PdfPathClosure::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathClosure::to_repr(PdfPathClosure) ->
    Repr

    PdfPathHole

    pub(all) enum PdfPathHole {
    PdfPathHole
    PdfPathNotHole
    } derive(Eq, ToJson,
    Debug
    )

    Whether a subpath is a hole in the containing path.

    PdfPathHole::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathHole::equal(PdfPathHole, PdfPathHole) -> Bool

    PdfPathHole::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathHole::not_equal(x : PdfPathHole, y : PdfPathHole) -> Bool

    PdfPathHole::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathHole::to_json(PdfPathHole) -> Json

    PdfPathHole::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathHole::to_repr(PdfPathHole) ->
    Repr

    PdfPathSegment

    One straight or Bezier path segment.

    PdfPathSegment::bounds

    Return cpdfcontent's control-point bounding box for a path segment.

    Bezier bounds intentionally include the two control points rather than solving for curve extrema, matching cpdfcontent.ml's bbox_of_segment.

    PdfPathSegment::content_json

    fn PdfPathSegment::content_json(self : PdfPathSegment) -> Json

    Return cpdfcontent's JSON shape for one path segment.

    PdfPathSegment::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSegment::equal(PdfPathSegment, PdfPathSegment) -> Bool

    PdfPathSegment::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSegment::not_equal(x : PdfPathSegment, y : PdfPathSegment) -> Bool

    PdfPathSegment::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSegment::to_json(PdfPathSegment) -> Json

    PdfPathSegment::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSegment::to_repr(PdfPathSegment) ->
    Repr

    PdfPathSegment::transform

    Transform every point in a path segment.

    PdfPathSubpath

    pub(all) struct PdfPathSubpath {
    hole : PdfPathHole
    closure : PdfPathClosure
    segments : Array[PdfPathSegment]
    } derive(Eq, ToJson,
    Debug
    )

    A cpdf-style subpath.

    PdfPathSubpath::content_json

    fn PdfPathSubpath::content_json(self : PdfPathSubpath) -> Json

    Return cpdfcontent's JSON shape for one subpath.

    The hole flag is intentionally not emitted, matching cpdfcontent.ml.

    PdfPathSubpath::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSubpath::equal(PdfPathSubpath, PdfPathSubpath) -> Bool

    PdfPathSubpath::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSubpath::not_equal(x : PdfPathSubpath, y : PdfPathSubpath) -> Bool

    PdfPathSubpath::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSubpath::to_json(PdfPathSubpath) -> Json

    PdfPathSubpath::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathSubpath::to_repr(PdfPathSubpath) ->
    Repr

    PdfPathWindingRule

    pub(all) enum PdfPathWindingRule {
    PdfPathEvenOdd
    PdfPathNonZero
    } derive(Eq, ToJson,
    Debug
    )

    Fill rule for a cpdf-style path.

    PdfPathWindingRule::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathWindingRule::equal(PdfPathWindingRule, PdfPathWindingRule) -> Bool

    PdfPathWindingRule::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathWindingRule::not_equal(x : PdfPathWindingRule, y : PdfPathWindingRule) -> Bool

    PdfPathWindingRule::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathWindingRule::to_json(PdfPathWindingRule) -> Json

    PdfPathWindingRule::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfPathWindingRule::to_repr(PdfPathWindingRule) ->
    Repr

    pdf_circle

    fn pdf_circle(center_x : Double, center_y : Double, radius : Double) -> PdfPath

    Source-spelled compatibility alias for cpdfshape's circle.

    pdf_drawn_path_content_json

    fn pdf_drawn_path_content_json(path : PdfDrawnPath) -> Json

    Compatibility wrapper for PdfDrawnPath::content_json.

    pdf_kappa

    let pdf_kappa : Double

    Source-spelled compatibility alias for cpdfshape's kappa.

    pdf_path_bounds

    Compatibility wrapper for PdfPath::bounds.

    pdf_path_segment_bounds

    Compatibility wrapper for PdfPathSegment::bounds.

    pdf_path_segment_content_json

    fn pdf_path_segment_content_json(segment : PdfPathSegment) -> Json

    Compatibility wrapper for PdfPathSegment::content_json.

    pdf_path_segment_transform

    Compatibility wrapper for PdfPathSegment::transform.

    pdf_path_subpath_content_json

    fn pdf_path_subpath_content_json(subpath : PdfPathSubpath) -> Json

    Compatibility wrapper for PdfPathSubpath::content_json.

    pdf_path_transform

    Compatibility wrapper for PdfPath::transform.

    pdf_rectangle

    fn pdf_rectangle(x : Double, y : Double, width : Double, height : Double) -> PdfPath

    Source-spelled compatibility alias for cpdfshape's rectangle.

    pdf_restrict_angle

    fn pdf_restrict_angle(step : Double, angle : Double) -> Double

    Restrict an angle to the closest multiple of step, modulo 2 * pi.

    pdf_shape_circle

    fn pdf_shape_circle(center_x : Double, center_y : Double, radius : Double) -> PdfPath

    Build a cpdf-style circular path from four Bezier quarter arcs.

    pdf_shape_kappa

    let pdf_shape_kappa : Double

    Bezier control-line factor used by cpdf for circular arcs.

    pdf_shape_rectangle

    fn pdf_shape_rectangle(x : Double, y : Double, width : Double, height : Double) -> PdfPath

    Build a cpdf-style rectangle path from a top-left point, width, and height.