Hi, a while ago I thought it would be useful, if programs can provide their own AMB (HTML) help files findable by the „help“ command. If I understand correctly, the help command as of now only works for commands contained in the global .AMB help file.
The algorithm for „help appx" would be like this: 1. look for AMB (HTML) help file in appx specific directory, and open it if found 2. if not found, look in global help file for specific command The global help file could then be restricted to the base components, keeping it smaller. Also the individual files can be updated without having to wait for the global help to be updated. Just an idea... Grüße, Bernd > Am 09.07.2023 um 16:59 schrieb Jim Hall via Freedos-devel > <freedos-devel@lists.sourceforge.net>: > > On Sun, Jul 9, 2023 at 6:46 AM Wilhelm Spiegl via Freedos-devel > <freedos-devel@lists.sourceforge.net> wrote: >> >> Till now amb files were created by Mateusz Viste. If I remember right, >> e.g. Hyperlinks within the text look absolutely different. >> > > They were created by Mateusz because AMB was new at the time, so only > Mateusz really understood it well. Mateusz possibly had another tool > to convert HTML files into AMA format, I don't know. But AMB (or > rather, AMA source files) are not that hard to figure out. Here's a > quick primer: > > AMB files are "packed" versions of one or more AMA source files. I'll > give an example with a few AMA source files since that is more similar > to HELP. > > An AMA source file is just a plain text with some special commands of > the format "%x" - that is, a "%" character followed by a single > letter. These are defined in the AMA spec: > https://amb.osdn.io/phpamb.php?fname=archiwum/format-20201216.amb&f=ama.ama > > Every line starts as plain text (%t) by default, so you don't need to > specify %t unless you have changed it otherwise in a line (such as a > link with %l) > > Links to other files are done like this: > %lmore.ama:more info > > That creates a link to a separate AMA file called MORE.AMA, using the > link text "more info" > > If you want to make columns of text, you need to change back to > regular text yourself, like this 2-column example: > %lmore.ama:more info%t %about.ama:about this file > > Note that %l will continue until the end of the line by default, or > you can "end" it by switching to another style like %t > > Text is not "collected" and lines are not "filled" like in HTML or > nroff or LaTeX. Instead, you need to format the AMA source text how it > should appear on the screen. Assume an 80 column screen, and the AMB > reader reserves 1 column width on the left for a border line, and 1 > column width on the right for the scroll bar. So you shouldn't have > displayed lines longer than 78 columns. > > Put your AMA files in a directory. The first file should be called > INDEX.AMA. The other files can be named whatever you like. You also > need a file in that directory called TITLE that contains a single line > description of the "book" - the line should be no longer than 64 > characters long. > > > I wrote a few test files and made an AMB out of it. Here are my files: > > C:\TEMP\AMBPACK>dir /b T > 2.AMA > INDEX.AMA > MORE.AMA > TITLE > > To create an AMB book from this directory, you use "AMBPACK c {dir} > {file.amb}" where "c" means "create." You can get the usage if you run > AMBPACK without options. > > C:\TEMP\AMBPACK>ambpack c T TEST.AMB > Computing the list of files... > Packing files... > index.ama --> TEST.AMB > more.ama --> TEST.AMB > title --> TEST.AMB > 2.ama --> TEST.AMB > OK > > And now I have a TEST.AMB file that works with the AMB viewer. (I > can't include a screenshot on the list, but if I run AMB TEST.AMB, I > can view the file, including navigating to the links). > > > Here are the files: (displayed using the DOS TYPE command, > copied/pasted here as a single DOS session) > > C:\TEMP\AMBPACK>type T\INDEX.AMA > %hTHIS IS THE INDEX FILE > > This is a test of writing an AMA file. Note that text is not "collected" > and "filled" like html or nroff or latex. Intead, the AMA source files > should have text filled and arranged the way you want them displayed. > > This is a new paragraph after a blank line. > > MORE HELP: > > %lmore.ama:link to new file%t %l2.ama:another help file > C:\TEMP\AMBPACK>type T\MORE.AMA > %hMORE HELP > > This file contains more help. > %hA SECOND HELP FILE > > This is another help file called 2.ama > C:\TEMP\AMBPACK>type T\TITLE > A test of creating AMB files from AMA source files > > > _______________________________________________ > Freedos-devel mailing list > Freedos-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/freedos-devel _______________________________________________ Freedos-devel mailing list Freedos-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/freedos-devel