diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2025-03-07 16:56:23 -0500 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2025-03-07 16:56:23 -0500 |
| commit | 2ebe7893fe18c953967f602c73f6d3f32185eeb6 (patch) | |
| tree | 6f2b5b83bc038907d8c387850ee3dd979bad2e71 /stdlib/text.h | |
| parent | 9b485be020b6021f2cb86d97efb5b05166901bdf (diff) | |
Add text padding functions: :left_pad(), :right_pad(), :middle_pad()
Diffstat (limited to 'stdlib/text.h')
| -rw-r--r-- | stdlib/text.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/stdlib/text.h b/stdlib/text.h index d3aba3f3..9923403c 100644 --- a/stdlib/text.h +++ b/stdlib/text.h @@ -68,6 +68,9 @@ Array_t Text$lines(Text_t text); Closure_t Text$by_line(Text_t text); Text_t Text$join(Text_t glue, Array_t pieces); Text_t Text$repeat(Text_t text, Int_t count); +Text_t Text$left_pad(Text_t text, Int_t count, Text_t padding); +Text_t Text$right_pad(Text_t text, Int_t count, Text_t padding); +Text_t Text$middle_pad(Text_t text, Int_t count, Text_t padding); int32_t Text$get_grapheme_fast(TextIter_t *state, int64_t index); uint32_t Text$get_main_grapheme_fast(TextIter_t *state, int64_t index); void Text$serialize(const void *obj, FILE *out, Table_t *, const TypeInfo_t *); |
