aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/Makefile.am7
-rw-r--r--doc/html.init (renamed from doc/Config)13
-rw-r--r--modules/guile/guile.c10
-rw-r--r--src/smapc.c14
4 files changed, 27 insertions, 17 deletions
diff --git a/doc/Makefile.am b/doc/Makefile.am
index f1ac7a9..d67d4ab 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -1,5 +1,5 @@
# This file is part of Smap.
-# Copyright (C) 2010, 2014 Sergey Poznyakoff
+# Copyright (C) 2010, 2014, 2015 Sergey Poznyakoff
#
# Smap is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -59,7 +59,8 @@ final: untabify master-menu
MAKEINFOFLAGS=
-GENDOCS=$(srcdir)/gendocs.sh
+GENDOCS=$(srcdir)/gendocs.sh --no-copy-images --html '--init-file=$(abs_srcdir)/html.init'
+EXTRA_DIST += gendocs.sh
TEXI2DVI=texi2dvi -t '@set $(RENDITION)'
@@ -70,7 +71,7 @@ manual:
TEXINPUTS=$(srcdir):$(top_srcdir)/build-aux:$(TEXINPUTS) \
MAKEINFO="$(MAKEINFO) $(MAKEINFOFLAGS)" \
TEXI2DVI="$(TEXI2DVI) -t @finalout" \
- $(GENDOCS) --no-copy-images $(PACKAGE) '$(PACKAGE_NAME) manual'
+ $(GENDOCS) $(PACKAGE) '$(PACKAGE_NAME) manual'
manual.tar.bz2: manual
tar cf manual.tar manual
diff --git a/doc/Config b/doc/html.init
index 64a7efb..738e2a9 100644
--- a/doc/Config
+++ b/doc/html.init
@@ -78,14 +78,12 @@ set_from_init_file('PROGRAM_NAME_IN_FOOTER',1);
set_from_init_file('DEFAULT_RULE', '');
set_from_init_file('BIG_RULE', '');
-# Turn off footer buttons in section split
-set_from_init_file('SECTION_FOOTER_BUTTONS', undef);
-#set_from_init_file('SECTION_BUTTONS', undef);
-# Turn off navigation bars at the bottom of each section in chapter split mode
+# Turn off navigation bars at the bottom of each section in chapter split mode,
+# or subsection in section split mode.
set_from_init_file('HEADERS', undef)
- if (get_conf('SPLIT') and (get_conf('SPLIT') eq 'chapter'));
-# Use navigation icons
+ if ((get_conf('SPLIT') eq 'chapter') or (get_conf('SPLIT') eq 'section'));
+# Use navigation icons
set_from_init_file('ICONS', 1);
set_from_init_file('ACTIVE_ICONS',
@@ -152,8 +150,11 @@ my @gray_buttons = (\&gray_document_title, ' ',
'FastBack', ' ', 'Up', ' ', 'FastForward', ' ',
'Contents', 'Index' );
+set_from_init_file('TOP_BUTTONS', undef);
set_from_init_file('SECTION_BUTTONS', \@gray_buttons);
set_from_init_file('CHAPTER_BUTTONS', \@gray_buttons);
+set_from_init_file('NODE_FOOTER_BUTTONS', \@gray_buttons);
+set_from_init_file('SECTION_FOOTER_BUTTONS', \@gray_buttons);
set_from_init_file('MISC_BUTTONS',
[\&gray_document_title,
'Contents',
diff --git a/modules/guile/guile.c b/modules/guile/guile.c
index afaeef5..ae63a51 100644
--- a/modules/guile/guile.c
+++ b/modules/guile/guile.c
@@ -1,5 +1,5 @@
/* This file is part of Smap.
- Copyright (C) 2010, 2014 Sergey Poznyakoff
+ Copyright (C) 2010, 2014, 2015 Sergey Poznyakoff
Smap is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -106,10 +106,10 @@ guile_call_proc(SCM *result, SCM proc, SCM arglist)
return 1;
}
- *result = scm_internal_lazy_catch(SCM_BOOL_T,
- eval_catch_body,
- scm_cons(proc, arglist),
- eval_catch_handler, &jmp_env);
+ *result = scm_c_catch(SCM_BOOL_T,
+ eval_catch_body, scm_cons(proc, arglist),
+ eval_catch_handler, &jmp_env,
+ NULL, NULL);
return 0;
}
diff --git a/src/smapc.c b/src/smapc.c
index 3fe930b..3beaa63 100644
--- a/src/smapc.c
+++ b/src/smapc.c
@@ -48,7 +48,8 @@
int smapc_trace_option;
int batch_mode;
struct in_addr source_addr;
-char *prompt = "(smapc) ";
+#define DEFAULT_PROMPT "(smapc) "
+char *prompt;
int cmdprefix = '.';
char *curmap;
char *curserver;
@@ -125,11 +126,15 @@ get_input_line(FILE *fp, int interactive)
static size_t bufsize = 0;
size_t buflevel;
-#ifdef WITH_READLINE
if (interactive) {
+#ifdef WITH_READLINE
return readline(prompt);
- }
+#else
+ fputs(prompt, stdout);
+ fflush(stdout);
#endif
+ }
+
if (bufsize == 0) {
bufsize = sizeof(sbuf);
buf = emalloc(bufsize);
@@ -753,6 +758,9 @@ main(int argc, char **argv)
exit(0);
}
+ if (!prompt)
+ prompt = estrdup(DEFAULT_PROMPT);
+
if (server_option)
smapc_connect(server_option);

Return to:

Send suggestions and report system problems to the System administrator.