From a7dd2ce1d7b108348fb71fc52d6dc3db28f9e344 Mon Sep 17 00:00:00 2001 From: Philip Minakov Date: Tue, 21 May 2024 20:59:53 +0400 Subject: [PATCH 1/2] Fix doc --- swilib/include/swilib/ui.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/swilib/include/swilib/ui.h b/swilib/include/swilib/ui.h index 69ea9582..21e7999c 100644 --- a/swilib/include/swilib/ui.h +++ b/swilib/include/swilib/ui.h @@ -434,7 +434,7 @@ void *GetHeaderPointer(void *gui) __swi_end(0x2AE, GetHeaderPointer, (gui)); /** - * Get pointer to the UI header. + * Set main text to the UI header. * @param header pointer to the header (#GetHeaderPointer) * @param title new title value * @param malloc_fn result of #malloc_adr() From 3c784233bfd7767f2f976bfc62de827962418291 Mon Sep 17 00:00:00 2001 From: Philip Minakov Date: Tue, 21 May 2024 21:00:35 +0400 Subject: [PATCH 2/2] Add new swi functions void SetHeaderScrollText(void *header, const WSHDR *title, const void *malloc_fn, const void *mfree_fn); void SetHeaderExtraText(void *header, const WSHDR *ws, const void *malloc_fn, const void *mfree_fn); --- swilib/include/swilib/ui.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/swilib/include/swilib/ui.h b/swilib/include/swilib/ui.h index 21e7999c..624d58d9 100644 --- a/swilib/include/swilib/ui.h +++ b/swilib/include/swilib/ui.h @@ -444,6 +444,28 @@ __swi_begin(0x2AF) void SetHeaderText(void *header, const WSHDR *title, const void *malloc_fn, const void *mfree_fn) __swi_end(0x2AF, SetHeaderText, (header, title, malloc_fn, mfree_fn)); +/** + * Set scolled text to the UI header. + * @param header pointer to the header (#GetHeaderPointer) + * @param title new title value + * @param malloc_fn result of #malloc_adr() + * @param mfree_fn result of #mfree_adr() + * */ +__swi_begin(0x3C6) +void SetHeaderScrollText(void *header, const WSHDR *title, const void *malloc_fn, const void *mfree_fn) +__swi_end(0x3C6, SetHeaderScrollText, (header, title, malloc_fn, mfree_fn)); + +/** + * Set extra text to the UI header. + * @param header pointer to the header (#GetHeaderPointer) + * @param ws new extra title value + * @param malloc_fn result of #malloc_adr() + * @param mfree_fn result of #mfree_adr() + * */ +__swi_begin(0x3C7) +void SetHeaderExtraText(void *header, const WSHDR *ws, const void *malloc_fn, const void *mfree_fn) +__swi_end(0x3C7, SetHeaderExtraText, (header, ws, malloc_fn, mfree_fn)); + /** * Get pointer to the UI header. * @param header pointer to the header (#GetHeaderPointer)