From 2041b11e23742d4e82363ea092291c1bd8ecb707 Mon Sep 17 00:00:00 2001 From: NishiOwO Date: Sat, 4 Oct 2025 22:08:05 +0000 Subject: [PATCH] new git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@171 b9cfdab3-6d41-4d17-bbe4-086880011989 --- GNUmakefile | 2 +- examples/scrollbar.c | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 examples/scrollbar.c diff --git a/GNUmakefile b/GNUmakefile index e781d42..54e74db 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -86,7 +86,7 @@ SO = .dll EXEC = .exe endif -EXAMPLES = examples/example$(EXEC) examples/rotate$(EXEC) examples/image$(EXEC) +EXAMPLES = examples/example$(EXEC) examples/rotate$(EXEC) examples/image$(EXEC) examples/scrollbar$(EXEC) ifeq ($(OPENGL),1) L_OBJS += src/widget/opengl.o diff --git a/examples/scrollbar.c b/examples/scrollbar.c new file mode 100644 index 0000000..76a7100 --- /dev/null +++ b/examples/scrollbar.c @@ -0,0 +1,18 @@ +/* $Id$ */ + +#include + +int main(){ + MwWidget window = MwVaCreateWidget(MwWindowClass, "main", NULL, 0, 0, 500, 500, + MwNtitle, "main", + NULL); + int i; + + for(i = 0; i < 500 / 16; i++){ + MwVaCreateWidget(MwScrollBarClass, "scroll", window, 16 * i, 0, 16, 500, + MwNorientation, MwVERTICAL, + NULL); + } + + MwLoop(window); +}