Skip to content

Commit

Permalink
Merge branch 'gtklos-doc'
Browse files Browse the repository at this point in the history
  • Loading branch information
egallesio committed Nov 12, 2024
2 parents 08d573b + fb17a98 commit 6844382
Show file tree
Hide file tree
Showing 41 changed files with 4,922 additions and 308 deletions.
3 changes: 2 additions & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -8293,7 +8293,7 @@ fi
ac_config_files="$ac_config_files Makefile src/Makefile src/extraconf.h doc/Makefile doc/refman/Makefile doc/vm/Makefile doc/hacking/Makefile doc/pp/Makefile lib/Makefile utils/Makefile utils/stklos-config utils/stklos-script examples/Makefile examples/C-module/Makefile lib/Match.d/Makefile lib/SILex.d/Makefile lib/Lalr.d/Makefile lib/scheme/Makefile lib/scheme/regex/Makefile lib/scheme/vector/Makefile lib/srfi/Makefile lib/stklos/Makefile lib/streams/Makefile tests/Makefile doc/stklos.1 doc/stklos-config.1 doc/stklos-compile.1 doc/stklos-genlex.1 doc/stklos-pp.1 doc/stklos-script.1 lib/srfi/160/Makefile extensions/Makefile extensions/gtklos/Makefile extensions/gtklos/lib/stklos/Makefile extensions/gtklos/lib/stklos/gtklos-config.h extensions/gtklos/lib/stklos/gtklos.stk extensions/gtklos/demos/Makefile extensions/curl/Makefile extensions/curl/lib/stklos/Makefile extensions/curl/demos/Makefile extensions/curl/doc/Makefile extensions/fuse/Makefile extensions/fuse/lib/stklos/Makefile extensions/fuse/demos/Makefile"
ac_config_files="$ac_config_files Makefile src/Makefile src/extraconf.h doc/Makefile doc/refman/Makefile doc/vm/Makefile doc/hacking/Makefile doc/pp/Makefile lib/Makefile utils/Makefile utils/stklos-config utils/stklos-script examples/Makefile examples/C-module/Makefile lib/Match.d/Makefile lib/SILex.d/Makefile lib/Lalr.d/Makefile lib/scheme/Makefile lib/scheme/regex/Makefile lib/scheme/vector/Makefile lib/srfi/Makefile lib/stklos/Makefile lib/streams/Makefile tests/Makefile doc/stklos.1 doc/stklos-config.1 doc/stklos-compile.1 doc/stklos-genlex.1 doc/stklos-pp.1 doc/stklos-script.1 lib/srfi/160/Makefile extensions/Makefile extensions/gtklos/Makefile extensions/gtklos/doc/Makefile extensions/gtklos/lib/stklos/Makefile extensions/gtklos/lib/stklos/gtklos-config.h extensions/gtklos/lib/stklos/gtklos.stk extensions/gtklos/demos/Makefile extensions/curl/Makefile extensions/curl/lib/stklos/Makefile extensions/curl/demos/Makefile extensions/curl/doc/Makefile extensions/fuse/Makefile extensions/fuse/lib/stklos/Makefile extensions/fuse/demos/Makefile"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
Expand Down Expand Up @@ -9074,6 +9074,7 @@ do
"lib/srfi/160/Makefile") CONFIG_FILES="$CONFIG_FILES lib/srfi/160/Makefile" ;;
"extensions/Makefile") CONFIG_FILES="$CONFIG_FILES extensions/Makefile" ;;
"extensions/gtklos/Makefile") CONFIG_FILES="$CONFIG_FILES extensions/gtklos/Makefile" ;;
"extensions/gtklos/doc/Makefile") CONFIG_FILES="$CONFIG_FILES extensions/gtklos/doc/Makefile" ;;
"extensions/gtklos/lib/stklos/Makefile") CONFIG_FILES="$CONFIG_FILES extensions/gtklos/lib/stklos/Makefile" ;;
"extensions/gtklos/lib/stklos/gtklos-config.h") CONFIG_FILES="$CONFIG_FILES extensions/gtklos/lib/stklos/gtklos-config.h" ;;
"extensions/gtklos/lib/stklos/gtklos.stk") CONFIG_FILES="$CONFIG_FILES extensions/gtklos/lib/stklos/gtklos.stk" ;;
Expand Down
1 change: 1 addition & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -764,6 +764,7 @@ AC_CONFIG_FILES([Makefile src/Makefile src/extraconf.h doc/Makefile
extensions/Makefile
extensions/gtklos/Makefile
extensions/gtklos/doc/Makefile
extensions/gtklos/lib/stklos/Makefile
extensions/gtklos/lib/stklos/gtklos-config.h
extensions/gtklos/lib/stklos/gtklos.stk
Expand Down
5 changes: 4 additions & 1 deletion doc/refman/stklos.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@
:docinfodir: ../lib/theme
:docinfo: shared
:idprefix: doc_
:nofooter: // to have reproducible builds
{{If (equal? doc-fmt "html")}}
:nofooter: // to have reproducible builds
{{End}}


// Load the general adoc library and the refman specific one
{{load "../lib/adoc-lib.stk"}}
Expand Down
25 changes: 13 additions & 12 deletions extensions/gtklos/demos/button.stk
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
;;;;
;;;; button.stk -- GTK demo using buttons
;;;;
;;;; Copyright © 2001-2021 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 2001-2024 Erick Gallesio <eg@stklos.net>
;;;;
;;;;
;;;; This program is free software; you can redistribute it and/or modify
Expand Down Expand Up @@ -36,19 +36,20 @@ various relief can be hardly visible.
")

(define (click w e)
(printf "You have clicked on '~s' button\n" (text w)))
(printf "You have clicked on ~s button\n" (text w)))


(define (main args)
(let* ((win (make <demo-window> #:title "Buttons Demo" #:width 600
#:file "button" #:border-width 5
#:message demo-message))
(b1 (make <button> #:parent win #:text "Normal" #:border-width 5))
(b2 (make <button> #:parent win #:text "None" #:border-width 5
#:relief 'none))
(b3 (make <button> #:parent win #:text "Tooltip" #:border-width 5
#:tooltip (string-append "A long tool-tip using\n"
"several lines\n"
"..."))))
(let ((win (make <demo-window> #:title "Buttons Demo" #:width 600
#:file "button" #:border-width 5
#:message demo-message)))

(make <button> #:parent win #:text "Normal" #:border-width 5 #:command click)
(make <button> #:parent win #:text "None" #:border-width 5 #:command click
#:relief 'none)
(make <button> #:parent win #:text "Tooltip" #:border-width 5 #:command click
#:tooltip (string-append "A long tool-tip using\n"
"several lines\n"
"..."))
(gtk-main)
0))
34 changes: 34 additions & 0 deletions extensions/gtklos/doc/Makefile.am
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# Makefile for producing STklos documentation (not using autoconf stuff)
#
# Author: Erick Gallesio [eg@essi.fr]
# Creation date: 9-Feb-2022 11:46

ADOC=@ASCIIDOCTOR@

TOP =../../..
SPP = $(TOP)/src/stklos -q -I $(TOP)/lib -I ../lib -f $(TOP)/utils/stklos-pp.stk --
MAIN = gtklos
DOCS = buttons.adoc canvases.adoc containers.adoc dialogs.adoc \
displays.adoc events.adoc gtklos.adoc intro.adoc misc.adoc texts.adoc
SCM = gendoc.stk
SRC = $(DOCS) $(SCM)


all: $(MAIN).html $(MAIN).pdf

$(MAIN).html: $(SRC)
$(SPP) -D "doc-fmt: html" $(MAIN).adoc > $(MAIN).tmp
$(ADOC) -v -o $@ $(MAIN).tmp
rm -f $(MAIN).tmp

$(MAIN).pdf: $(SRC)
$(SPP) -D "doc-fmt: pdf" $(MAIN).adoc > $(MAIN).tmp
$(ADOC) -r asciidoctor-pdf -b pdf -v -o tmp.pdf $(MAIN).tmp
gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/prepress \
-dNOPAUSE -dQUIET -dBATCH -sOutputFile=$@ tmp.pdf
rm -f $(MAIN).tmp tmp.pdf

clean:
rm -f $(MAIN).pdf $(MAIN).html $(MAIN).tmp *~

distclean: clean
Loading

0 comments on commit 6844382

Please sign in to comment.