diff --git a/doc/Makefile.am b/doc/Makefile.am index e5f5d09a..0a599ca9 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -3,7 +3,8 @@ t2t_sources = \ medit.t2t \ prefs-file.t2t \ prefs.t2t \ - user-tools.t2t + user-tools.t2t \ + man-medit.t2t EXTRA_DIST = \ $(t2t_sources) \ @@ -14,11 +15,16 @@ EXTRA_DIST = \ stamp-help \ help-sections.h -BUILT_SOURCES = stamp-help help-sections.h +dist_man_MANS = medit.1 + +BUILT_SOURCES = stamp-help help-sections.h medit.1 help-sections.h: stamp-help build-docs: stamp-help +medit.1: man-medit.t2t + txt2tags --target=man --outfile=medit.1 $(srcdir)/man-medit.t2t + stamp-help: $(t2t_sources) makedocs rm -fr help && \ $(mkdir_p) help && \ @@ -30,6 +36,7 @@ prefs.lo: build-docs prefs-file.lo: build-docs license.lo: build-docs user-tools.lo: build-docs +man-medit.lo: medit.1 install-data-hook: build-docs $(mkdir_p) $(DESTDIR)$(htmldir)/help diff --git a/doc/license.t2t b/doc/license.t2t index 0a4373e2..7934a3b2 100644 --- a/doc/license.t2t +++ b/doc/license.t2t @@ -54,3 +54,4 @@ OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ``` + diff --git a/doc/makedocs b/doc/makedocs index ad4c730a..fd132f80 100755 --- a/doc/makedocs +++ b/doc/makedocs @@ -41,4 +41,4 @@ write_sections () { generate $infile $outfile || exit 1 write_sections $outfile || exit 1 -rm $outfile || exit 1 +# rm $outfile || exit 1 diff --git a/doc/man-medit.t2t b/doc/man-medit.t2t new file mode 100644 index 00000000..fc105f20 --- /dev/null +++ b/doc/man-medit.t2t @@ -0,0 +1,99 @@ +MEDIT + +February 2008 + +%!encoding: UTF-8 + += NAME = + +medit - text editor + + += SYNOPSIS = + +**medit** [//OPTION//]... [//FILES//] + + += DESCRIPTION = + +**medit** is a text editor. + + += OPTIONS = + +: **-n**, **--new-app** +run new instance of **medit**. By default **medit** opens //FILES// +(or creates a new document if none are given) in an existing instance +of application + +: **-s**, **--use-session**[=//yes|no//] +load and save session. By default **medit** does it when **-n** is not used. +If this option is not given on command line then medit uses the corresponding +preferences setting. + +: **--pid** //PID// +use existing instance with process id //PID//. + +: **--app-name** //NAME// +use instance name //NAME//. If an instance with this name is already running, +then it will send files given on the command line to that instance and exit. + +: **--line** //LINE// +open file and position cursor on line //LINE//. Alternatively +line number may be specified with filename, e.g. + medit foo.txt:12 + +: **-w**, **--new-window** +open file in a new window + +: **-t**, **--new-tab** +open file in a new tab + +: **--log**[=//FILE//] +if //FILE// is given, write the debug output into //FILE//. Otherwise, +show debug output in a log window. This option is only useful on Windows + +: **--debug**[=//DOMAINS//] +enable debug output for //DOMAINS// (if **medit** was compiled with +--enable-debug option) + +: **--exec** //STRING// +execute python code in //STRING// in an existing instance + +: **--exec-file** //FILE// +execute python file //FILE// in an existing instance + +: **-h**, **--help** +show summary of options + +: **-v**, **--version** +show program version + +: //FILES// +list of files to open. Filenames may include line numbers after colon, +e.g. /tmp/file.txt:200. Trailing colon is ignored + + += ENVIRONMENT VARIABLES = + +: MEDIT_PID +if set, is used as --pid argument. When medit spawns a process (e.g. a DVI viewer) it sets +MEDIT_PID to its own process id, so the child process may in turn simply use 'medit filename' +to open a file (e.g. for inverse DVI search). + + += CONTACT = + +http://mooedit.sourceforge.net/contact.html + + += AUTHOR = + +Written and maintained by Yevgen Muntyan + + +% = COPYRIGHT = +% +% Copyright (C) 2004-2008 Yevgen Muntyan +% +% medit is a free software. diff --git a/doc/medit.t2t b/doc/medit.t2t index caa3f0bd..a02748d2 100644 --- a/doc/medit.t2t +++ b/doc/medit.t2t @@ -1,9 +1,10 @@ APPNAME APPVERSION Manual -%! Target : html -%! Encoding: UTF-8 -%! Options : --css-sugar +%! Target : html +%! Encoding : UTF-8 +%! Options : --css-sugar +%! Options(html): --mask-email %% 'entities' %! Postproc: APPNAME medit @@ -17,13 +18,17 @@ APPNAME APPVERSION Manual %! Preproc : '^(=+)\s*(.*)\s+\1\[(.*)\]' '\1 !!ANCHOR!!\3!!\2!! \1[\3]' %% Remove t2t-generated '' %! Postproc: '' '' -%% Convert '

!!ANCHOR!!anchor!!Title!!

' to '

Title

' +%% Convert '

!!ANCHOR!!anchor!!Title!!

' to '

Title

', +%% @@anchor@@ is needed for makedocs to generate help-sections.h %! Postproc: '<(H\d)>!!ANCHOR!!(.*)!!(.*)!!' '<\1>\3' %% Convert remaining '!!ANCHOR!!anchor!!Title!!' to 'Title' %! Postproc: '!!ANCHOR!!(.*)!!(.*)!!' '\2' %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%! Postproc: '@em\{(.*?)\}' '\1' +%! Postproc: '@comment\{(.*?)\}' '' + APPNAME APPVERSION Manual %!include: prefs.t2t @@ -33,11 +38,11 @@ APPNAME APPVERSION Manual %% Fake help sections -`` -`` -`` -`` -`` -`` -`` -`` +@comment{@@dialog-replace@@} +@comment{@@dialog-find@@} +@comment{@@prefs-dialog@@} +@comment{@@prefs-plugins@@} +@comment{@@prefs-file-selector@@} +@comment{@@dialog-find-in-files@@} +@comment{@@dialog-find-file@@} +@comment{@@file-selector@@} diff --git a/doc/prefs.t2t b/doc/prefs.t2t index cb5daf58..4e9fd2c5 100644 --- a/doc/prefs.t2t +++ b/doc/prefs.t2t @@ -58,19 +58,19 @@ highlighting language. To set the options in the document text, place the following on the first, second or the last line of the document: ``` --%- options -%- +-%- @em{options} -%- ``` where //options// is the option string ``` -key: value; key: value; ... +@em{key}: @em{value}; @em{key}: @em{value}; ... ``` (the latter is the format used also in the //Preferences// dialog). -Values can be strings, integer numbers, or boolean values. +Values can be strings, integers, or booleans. -Boolean values may be specified using ``yes``, ``no``, ``true``, ``false``, ``1``, ``0``. +Booleans are ``yes``, ``no``, ``true``, ``false``, ``1``, ``0``. -If a string value contains ``:`` character, then the following syntax may be used: ``key=/value/``. +If a string value contains ``:`` character, then the following syntax may be used: ``@em{key}=/@em{value}/``. Any character may be used instead of slash (and it must not occur in the //value//). Example: ``word-chars=@-/:@`` diff --git a/doc/user-tools.t2t b/doc/user-tools.t2t index c12e48d5..4c7c5e68 100644 --- a/doc/user-tools.t2t +++ b/doc/user-tools.t2t @@ -92,7 +92,7 @@ as shell commands. To set parameters for a tool, place them on the first or the second line of the file in the following format: ``` -!! key=value; key=value; ... !! +!! @em{key}=@em{value}; @em{key}=@em{value}; ... !! ``` //key// may be one of the following: diff --git a/medit/Makefile.am b/medit/Makefile.am index d6cb7a1e..393ca791 100644 --- a/medit/Makefile.am +++ b/medit/Makefile.am @@ -8,8 +8,6 @@ EXTRA_DIST = \ medit-app.opag \ medit.rc.in -dist_man_MANS = medit.1 - bin_PROGRAMS = medit medit_SOURCES = medit-credits.h medit-app.c mem-debug.h diff --git a/medit/medit.1 b/medit/medit.1 deleted file mode 100644 index a9333615..00000000 --- a/medit/medit.1 +++ /dev/null @@ -1,83 +0,0 @@ -.\" Hey, EMACS: -*- nroff -*- -.\" First parameter, NAME, should be all caps -.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection -.\" other parameters are allowed: see man(7), man(1) -.TH MEDIT 1 "June 20, 2007" -.\" Please adjust this date whenever revising the manpage. -.\" -.\" Some roff macros, for reference: -.\" .nh disable hyphenation -.\" .hy enable hyphenation -.\" .ad l left justify -.\" .ad b justify to both left and right margins -.\" .nf disable filling -.\" .fi enable filling -.\" .br insert line break -.\" .sp insert n+1 empty lines -.\" for manpage-specific macros, see man(7) -.SH NAME -medit \- text editor -.SH SYNOPSIS -.B medit -.RI [ options ]\ [ files ] -.SH DESCRIPTION -.B medit -is a text editor. -.SH OPTIONS -.TP -.B \-h, \-\-help -Show summary of options. -.TP -.B \-v, \-\-version -Show version of the program. -.TP -.B \-n, \-\-new\-app -Run new instance of \fBmedit\fP. By default \fBmedit\fP opens \fBfiles\fP -in an existing instance of application. -.TP -.B \-s, \-\-use\-session[=yes|no] -Load and save session. By default \fBmedit\fP does it when \-n is not used. -If this option is not given on command line then medit uses the corresponding -preferences setting. -.TP -.B \-\-pid PID -Use existing instance with process id \fBPID\fP. -.TP -.B \-\-app-name NAME -Use instance name \fBNAME\fP. If an instance with this name is already running, -then it will send files given on the command line to that instance and exit. -.TP -.B \-l, \-\-line LINE -Open file and position cursor on line \fBLINE\fP. -.TP -.B \-w, \-\-new-window -Open file in a new window. -.TP -.B \-t, \-\-new-tab -Open file in a new tab. -.TP -.B \-\-log[=FILE] -Show debug output or write it to \fBFILE\fP. -.TP -.B \-\-debug -Run in debug mode. -.TP -.B \-\-exec STRING -Execute python code in an existing instance. -.TP -.B \-\-exec\-file FILE -Execute python file in an existing instance. -.TP -.B files -List of files to open. Filenames may include line numbers after colon, e.g. /tmp/file.txt:200. -Trailing colon is also fine. -.SH ENVIRONMENT -.TP -.B MEDIT_PID -If set, used as --pid argument. When medit spawns a process (e.g. a DVI viewer) it sets MEDIT_PID -to its own process id, so the child process may in turn simply use 'medit filename' to open a file -(e.g. for inverse DVI search). -.SH CONTACT -http://mooedit.sourceforge.net/contact.html. -.SH AUTHOR -medit was written by Yevgen Muntyan .