diff --git a/.gitmodules b/.gitmodules index 3de13b84..fa4fd377 100644 --- a/.gitmodules +++ b/.gitmodules @@ -12,7 +12,7 @@ url = https://github.com/Drako/SublimeBrainfuck [submodule "vendor/grammars/awk-sublime"] path = vendor/grammars/awk-sublime - url = https://github.com/JohnNilsson/awk-sublime + url = https://github.com/github-linguist/awk-sublime [submodule "vendor/grammars/Sublime-SQF-Language"] path = vendor/grammars/Sublime-SQF-Language url = https://github.com/JonBons/Sublime-SQF-Language @@ -30,7 +30,7 @@ url = https://github.com/SublimeText/ColdFusion [submodule "vendor/grammars/NSIS"] path = vendor/grammars/NSIS - url = https://github.com/SublimeText/NSIS + url = https://github.com/github-linguist/NSIS [submodule "vendor/grammars/NimLime"] path = vendor/grammars/NimLime url = https://github.com/Varriount/NimLime @@ -91,9 +91,6 @@ [submodule "vendor/grammars/bro-sublime"] path = vendor/grammars/bro-sublime url = https://github.com/bro/bro-sublime -[submodule "vendor/grammars/sublime_man_page_support"] - path = vendor/grammars/sublime_man_page_support - url = https://github.com/carsonoid/sublime_man_page_support [submodule "vendor/grammars/sublime-MuPAD"] path = vendor/grammars/sublime-MuPAD url = https://github.com/ccreutzig/sublime-MuPAD @@ -283,9 +280,6 @@ [submodule "vendor/grammars/groovy.tmbundle"] path = vendor/grammars/groovy.tmbundle url = https://github.com/textmate/groovy.tmbundle -[submodule "vendor/grammars/haskell.tmbundle"] - path = vendor/grammars/haskell.tmbundle - url = https://github.com/textmate/haskell.tmbundle [submodule "vendor/grammars/html.tmbundle"] path = vendor/grammars/html.tmbundle url = https://github.com/textmate/html.tmbundle @@ -418,9 +412,9 @@ [submodule "vendor/grammars/oz-tmbundle"] path = vendor/grammars/oz-tmbundle url = https://github.com/eregon/oz-tmbundle -[submodule "vendor/grammars/ebundles"] - path = vendor/grammars/ebundles - url = https://github.com/ericzou/ebundles +[submodule "vendor/grammars/language-batchfile"] + path = vendor/grammars/language-batchfile + url = https://github.com/mmims/language-batchfile [submodule "vendor/grammars/sublime-mask"] path = vendor/grammars/sublime-mask url = https://github.com/tenbits/sublime-mask @@ -565,7 +559,7 @@ url = https://github.com/ShaneWilton/sublime-smali [submodule "vendor/grammars/language-jsoniq"] path = vendor/grammars/language-jsoniq - url = http://github.com/wcandillon/language-jsoniq + url = https://github.com/wcandillon/language-jsoniq [submodule "vendor/grammars/atom-fsharp"] path = vendor/grammars/atom-fsharp url = https://github.com/fsprojects/atom-fsharp @@ -608,9 +602,6 @@ [submodule "vendor/grammars/X10"] path = vendor/grammars/X10 url = https://github.com/x10-lang/x10-highlighting -[submodule "vendor/grammars/language-babel"] - path = vendor/grammars/language-babel - url = https://github.com/gandm/language-babel [submodule "vendor/grammars/UrWeb-Language-Definition"] path = vendor/grammars/UrWeb-Language-Definition url = https://github.com/gwalborn/UrWeb-Language-Definition.git @@ -675,8 +666,8 @@ path = vendor/grammars/pig-latin url = https://github.com/goblindegook/sublime-text-pig-latin [submodule "vendor/grammars/sourcepawn"] -path = vendor/grammars/sourcepawn -url = https://github.com/austinwagner/sublime-sourcepawn + path = vendor/grammars/sourcepawn + url = https://github.com/github-linguist/sublime-sourcepawn [submodule "vendor/grammars/gdscript"] path = vendor/grammars/gdscript url = https://github.com/beefsack/GDScript-sublime @@ -755,3 +746,48 @@ url = https://github.com/austinwagner/sublime-sourcepawn [submodule "vendor/grammars/SublimeGDB"] path = vendor/grammars/SublimeGDB url = https://github.com/quarnster/SublimeGDB +[submodule "vendor/grammars/language-roff"] + path = vendor/grammars/language-roff + url = https://github.com/Alhadis/language-roff +[submodule "vendor/grammars/language-haskell"] + path = vendor/grammars/language-haskell + url = https://github.com/atom-haskell/language-haskell +[submodule "vendor/grammars/language-asn1"] + path = vendor/grammars/language-asn1 + url = https://github.com/ajLangley12/language-asn1 +[submodule "vendor/grammars/atom-language-1c-bsl"] + path = vendor/grammars/atom-language-1c-bsl + url = https://github.com/xDrivenDevelopment/atom-language-1c-bsl.git +[submodule "vendor/grammars/sublime-rexx"] + path = vendor/grammars/sublime-rexx + url = https://github.com/mblocker/rexx-sublime +[submodule "vendor/grammars/blitzmax"] + path = vendor/grammars/blitzmax + url = https://github.com/textmate/blitzmax.tmbundle +[submodule "vendor/grammars/cython"] + path = vendor/grammars/cython + url = https://github.com/textmate/cython.tmbundle +[submodule "vendor/grammars/forth"] + path = vendor/grammars/forth + url = https://github.com/textmate/forth.tmbundle +[submodule "vendor/grammars/parrot"] + path = vendor/grammars/parrot + url = https://github.com/textmate/parrot.tmbundle +[submodule "vendor/grammars/secondlife-lsl"] + path = vendor/grammars/secondlife-lsl + url = https://github.com/textmate/secondlife-lsl.tmbundle +[submodule "vendor/grammars/vhdl"] + path = vendor/grammars/vhdl + url = https://github.com/textmate/vhdl.tmbundle +[submodule "vendor/grammars/xquery"] + path = vendor/grammars/xquery + url = https://github.com/textmate/xquery.tmbundle +[submodule "vendor/grammars/language-rpm-spec"] + path = vendor/grammars/language-rpm-spec + url = https://github.com/waveclaw/language-rpm-spec +[submodule "vendor/grammars/language-emacs-lisp"] + path = vendor/grammars/language-emacs-lisp + url = https://github.com/Alhadis/language-emacs-lisp +[submodule "vendor/grammars/language-babel"] + path = vendor/grammars/language-babel + url = https://github.com/github-linguist/language-babel diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 638867c5..eb7532e0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -28,11 +28,12 @@ We try only to add languages once they have some usage on GitHub. In most cases To add support for a new language: 0. Add an entry for your language to [`languages.yml`][languages]. -0. Add a grammar for your language. Please only add grammars that have a license that permits redistribution. +0. Add a grammar for your language. Please only add grammars that have [one of these licenses](https://github.com/github/linguist/blob/257425141d4e2a5232786bf0b13c901ada075f93/vendor/licenses/config.yml#L2-L11). 0. Add your grammar as a submodule: `git submodule add https://github.com/JaneSmith/MyGrammar vendor/grammars/MyGrammar`. 0. Add your grammar to [`grammars.yml`][grammars] by running `script/convert-grammars --add vendor/grammars/MyGrammar`. 0. Download the license for the grammar: `script/licensed`. Be careful to only commit the file for the new grammar, as this script may update licenses for other grammars as well. 0. Add samples for your language to the [samples directory][samples] in the correct subdirectory. +0. Add a `language_id` for your language. See `script/set-language-ids` for more information. **You should only ever need to run `script/set-language-ids --update`. Anything other than this risks breaking GitHub search :cry:** 0. Open a pull request, linking to a [GitHub search result](https://github.com/search?utf8=%E2%9C%93&q=extension%3Aboot+NOT+nothack&type=Code&ref=searchresults) showing in-the-wild usage. In addition, if your new language defines an extension that's already listed in [`languages.yml`][languages] (such as `.foo`) then sometimes a few more steps will need to be taken: @@ -84,7 +85,7 @@ Linguist is maintained with :heart: by: - @arfon (GitHub Staff) - @larsbrinkhoff - @pchaigno - + As Linguist is a production dependency for GitHub we have a couple of workflow restrictions: - Anyone with commit rights can merge Pull Requests provided that there is a :+1: from a GitHub member of staff diff --git a/bin/git-linguist b/bin/git-linguist index 9e525bb5..d390530e 100755 --- a/bin/git-linguist +++ b/bin/git-linguist @@ -23,7 +23,7 @@ class GitLinguist if @incremental && stats = load_language_stats old_commit_oid, old_stats = stats - # A cache with NULL oid means that we want to froze + # A cache with NULL oid means that we want to freeze # these language stats in place and stop computing # them (for performance reasons) return old_stats if old_commit_oid == NULL_OID @@ -111,7 +111,7 @@ def git_linguist(args) parser.parse!(args) git_dir = `git rev-parse --git-dir`.strip - raise "git-linguist must be ran in a Git repository (#{Dir.pwd})" unless $?.success? + raise "git-linguist must be run in a Git repository (#{Dir.pwd})" unless $?.success? wrapper = GitLinguist.new(git_dir, commit, incremental) case args.pop diff --git a/grammars.yml b/grammars.yml index 4c720b39..e51e8848 100755 --- a/grammars.yml +++ b/grammars.yml @@ -1,20 +1,6 @@ --- http://svn.edgewall.org/repos/genshi/contrib/textmate/Genshi.tmbundle/Syntaxes/Markup%20Template%20%28XML%29.tmLanguage: - text.xml.genshi -http://svn.textmate.org/trunk/Review/Bundles/BlitzMax.tmbundle: -- source.blitzmax -http://svn.textmate.org/trunk/Review/Bundles/Cython.tmbundle: -- source.cython -http://svn.textmate.org/trunk/Review/Bundles/Forth.tmbundle: -- source.forth -http://svn.textmate.org/trunk/Review/Bundles/Parrot.tmbundle: -- source.parrot.pir -http://svn.textmate.org/trunk/Review/Bundles/SecondLife%20LSL.tmbundle: -- source.lsl -http://svn.textmate.org/trunk/Review/Bundles/VHDL.tmbundle: -- source.vhdl -http://svn.textmate.org/trunk/Review/Bundles/XQuery.tmbundle: -- source.xquery https://bitbucket.org/Clams/sublimesystemverilog/get/default.tar.gz: - source.systemverilog - source.ucfconstraints @@ -22,9 +8,9 @@ vendor/grammars/Agda.tmbundle: - source.agda vendor/grammars/Alloy.tmbundle: - source.alloy -vendor/grammars/AutoHotkey/: +vendor/grammars/AutoHotkey: - source.ahk -vendor/grammars/BrightScript.tmbundle/: +vendor/grammars/BrightScript.tmbundle: - source.brightauthorproject - source.brightscript vendor/grammars/ColdFusion: @@ -34,11 +20,13 @@ vendor/grammars/ColdFusion: - text.html.cfm vendor/grammars/Docker.tmbundle: - source.dockerfile -vendor/grammars/Elm/: +vendor/grammars/Elm/Syntaxes: - source.elm +- text.html.mediawiki.elm-build-output +- text.html.mediawiki.elm-documentation vendor/grammars/FreeMarker.tmbundle: - text.html.ftl -vendor/grammars/G-Code/: +vendor/grammars/G-Code: - source.LS - source.MCPOST - source.MOD @@ -51,7 +39,7 @@ vendor/grammars/IDL-Syntax: vendor/grammars/Isabelle.tmbundle: - source.isabelle.root - source.isabelle.theory -vendor/grammars/JSyntax/: +vendor/grammars/JSyntax: - source.j vendor/grammars/Julia.tmbundle: - source.julia @@ -62,7 +50,7 @@ vendor/grammars/LiveScript.tmbundle: vendor/grammars/MagicPython: - source.python - source.regexp.python -vendor/grammars/Modelica/: +vendor/grammars/Modelica: - source.modelica vendor/grammars/NSIS: - source.nsis @@ -72,7 +60,7 @@ vendor/grammars/NimLime: - source.nimcfg vendor/grammars/PHP-Twig.tmbundle: - text.html.twig -vendor/grammars/PogoScript.tmbundle/: +vendor/grammars/PogoScript.tmbundle: - source.pogoscript vendor/grammars/RDoc.tmbundle: - text.rdoc @@ -87,10 +75,10 @@ vendor/grammars/Scalate.tmbundle: - text.html.ssp vendor/grammars/Slash.tmbundle: - text.html.slash -vendor/grammars/Stata.tmbundle/: +vendor/grammars/Stata.tmbundle: - source.mata - source.stata -vendor/grammars/Stylus/: +vendor/grammars/Stylus: - source.stylus vendor/grammars/Sublime-Coq: - source.coq @@ -100,7 +88,7 @@ vendor/grammars/Sublime-Lasso: - file.lasso vendor/grammars/Sublime-Loom: - source.loomscript -vendor/grammars/Sublime-Modula-2/: +vendor/grammars/Sublime-Modula-2: - source.modula2 vendor/grammars/Sublime-Nit: - source.nit @@ -119,22 +107,22 @@ vendor/grammars/Sublime-VimL: - source.viml vendor/grammars/SublimeBrainfuck: - source.bf -vendor/grammars/SublimeClarion/: +vendor/grammars/SublimeClarion: - source.clarion -vendor/grammars/SublimeGDB/: +vendor/grammars/SublimeGDB: - source.disasm - source.gdb - source.gdb.session - source.gdbregs -vendor/grammars/SublimePapyrus/: +vendor/grammars/SublimePapyrus: - source.papyrus.skyrim -vendor/grammars/SublimePuppet/: +vendor/grammars/SublimePuppet: - source.puppet vendor/grammars/SublimeXtend: - source.xtend vendor/grammars/TLA: - source.tla -vendor/grammars/TXL/: +vendor/grammars/TXL: - source.txl vendor/grammars/Textmate-Gosu-Bundle: - source.gosu.2 @@ -163,36 +151,39 @@ vendor/grammars/antlr.tmbundle: vendor/grammars/apache.tmbundle: - source.apache-config - source.apache-config.mod_perl -vendor/grammars/api-blueprint-sublime-plugin/: +vendor/grammars/api-blueprint-sublime-plugin: - text.html.markdown.source.gfm.apib - text.html.markdown.source.gfm.mson vendor/grammars/applescript.tmbundle: - source.applescript -vendor/grammars/asciidoc.tmbundle/: +vendor/grammars/asciidoc.tmbundle: - text.html.asciidoc vendor/grammars/asp.tmbundle: - source.asp - text.html.asp -vendor/grammars/assembly/: +vendor/grammars/assembly: - objdump.x86asm - source.x86asm -vendor/grammars/atom-fsharp/: +vendor/grammars/atom-fsharp: - source.fsharp - source.fsharp.fsi - source.fsharp.fsl - source.fsharp.fsx +vendor/grammars/atom-language-1c-bsl: +- source.bsl +- source.sdbl vendor/grammars/atom-language-clean: - source.clean -vendor/grammars/atom-language-purescript/: +vendor/grammars/atom-language-purescript: - source.purescript vendor/grammars/atom-language-srt: - text.srt -vendor/grammars/atom-language-stan/: +vendor/grammars/atom-language-stan: - source.stan vendor/grammars/atom-salt: - source.python.salt - source.yaml.salt -vendor/grammars/atomic-dreams/: +vendor/grammars/atomic-dreams: - source.dm - source.dmf vendor/grammars/ats: @@ -201,7 +192,9 @@ vendor/grammars/awk-sublime: - source.awk vendor/grammars/bison.tmbundle: - source.bison -vendor/grammars/boo/: +vendor/grammars/blitzmax: +- source.blitzmax +vendor/grammars/boo: - source.boo vendor/grammars/bro-sublime: - source.bro @@ -226,13 +219,15 @@ vendor/grammars/cool-tmbundle: vendor/grammars/cpp-qt.tmbundle: - source.c++.qt - source.qmake -vendor/grammars/creole/: +vendor/grammars/creole: - text.html.creole vendor/grammars/css.tmbundle: - source.css vendor/grammars/cucumber-tmbundle: - source.ruby.rspec.cucumber.steps - text.gherkin.feature +vendor/grammars/cython: +- source.cython vendor/grammars/d.tmbundle: - source.d vendor/grammars/dart-sublime-bundle: @@ -248,9 +243,7 @@ vendor/grammars/dylan.tmbundle: - source.dylan - source.lid - source.makegen -vendor/grammars/ebundles/Bundles/MSDOS batch file.tmbundle: -- source.dosbatch -vendor/grammars/ec.tmbundle/: +vendor/grammars/ec.tmbundle: - source.c.ec vendor/grammars/eiffel.tmbundle: - source.eiffel @@ -270,12 +263,14 @@ vendor/grammars/fancy-tmbundle: - source.fancy vendor/grammars/fish-tmbundle: - source.fish +vendor/grammars/forth: +- source.forth vendor/grammars/fortran.tmbundle: - source.fortran - source.fortran.modern -vendor/grammars/gap-tmbundle/: +vendor/grammars/gap-tmbundle: - source.gap -vendor/grammars/gdscript/: +vendor/grammars/gdscript: - source.gdscript vendor/grammars/gettext.tmbundle: - source.po @@ -291,9 +286,6 @@ vendor/grammars/graphviz.tmbundle: - source.dot vendor/grammars/groovy.tmbundle: - source.groovy -vendor/grammars/haskell.tmbundle: -- source.haskell -- text.tex.latex.haskell vendor/grammars/haxe-sublime-bundle: - source.erazor - source.haxe.2 @@ -306,7 +298,7 @@ vendor/grammars/idl.tmbundle: - source.idl - source.idl-dlm - text.idl-idldoc -vendor/grammars/idris/: +vendor/grammars/idris: - source.idris vendor/grammars/ini.tmbundle: - source.ini @@ -336,12 +328,16 @@ vendor/grammars/language-agc: - source.agc vendor/grammars/language-apl: - source.apl -vendor/grammars/language-babel/: +vendor/grammars/language-asn1: +- source.asn +vendor/grammars/language-babel: - source.js.jsx - source.regexp.babel -vendor/grammars/language-blade/: +vendor/grammars/language-batchfile: +- source.batchfile +vendor/grammars/language-blade: - text.html.php.blade -vendor/grammars/language-click/: +vendor/grammars/language-click: - source.click vendor/grammars/language-clojure: - source.clojure @@ -360,10 +356,21 @@ vendor/grammars/language-csound: - source.csound - source.csound-document - source.csound-score +vendor/grammars/language-emacs-lisp: +- source.emacs.lisp vendor/grammars/language-gfm: - source.gfm vendor/grammars/language-graphql: - source.graphql +vendor/grammars/language-haskell: +- hint.haskell +- hint.message.haskell +- hint.type.haskell +- source.c2hs +- source.cabal +- source.haskell +- source.hsc2hs +- text.tex.latex.haskell vendor/grammars/language-hy: - source.hy vendor/grammars/language-inform7: @@ -372,10 +379,10 @@ vendor/grammars/language-javascript: - source.js - source.js.regexp - source.js.regexp.replacement -vendor/grammars/language-jsoniq/: +vendor/grammars/language-jsoniq: - source.jq - source.xq -vendor/grammars/language-less/: +vendor/grammars/language-less: - source.css.less vendor/grammars/language-maxscript: - source.maxscript @@ -390,6 +397,14 @@ vendor/grammars/language-renpy: - source.renpy vendor/grammars/language-restructuredtext: - text.restructuredtext +vendor/grammars/language-roff: +- source.ideal +- source.pic +- text.roff +- text.runoff +vendor/grammars/language-rpm-spec: +- source.changelogs.rpm-spec +- source.rpm-spec vendor/grammars/language-shellscript: - source.shell - text.shell-session @@ -406,7 +421,7 @@ vendor/grammars/language-xbase: - source.harbour vendor/grammars/language-yaml: - source.yaml -vendor/grammars/language-yang/: +vendor/grammars/language-yang: - source.yang vendor/grammars/latex.tmbundle: - text.bibtex @@ -440,11 +455,11 @@ vendor/grammars/matlab.tmbundle: - source.octave vendor/grammars/maven.tmbundle: - text.xml.pom -vendor/grammars/mediawiki.tmbundle/: +vendor/grammars/mediawiki.tmbundle: - text.html.mediawiki vendor/grammars/mercury-tmlanguage: - source.mercury -vendor/grammars/monkey/: +vendor/grammars/monkey: - source.monkey vendor/grammars/moonscript-tmbundle: - source.moonscript @@ -474,11 +489,13 @@ vendor/grammars/opa.tmbundle: - source.opa vendor/grammars/oz-tmbundle/Syntaxes/Oz.tmLanguage: - source.oz +vendor/grammars/parrot: +- source.parrot.pir vendor/grammars/pascal.tmbundle: - source.pascal -vendor/grammars/pawn-sublime-language/: +vendor/grammars/pawn-sublime-language: - source.pawn -vendor/grammars/perl.tmbundle/: +vendor/grammars/perl.tmbundle: - source.perl - source.perl.6 vendor/grammars/perl6fe: @@ -489,7 +506,7 @@ vendor/grammars/php-smarty.tmbundle: - text.html.smarty vendor/grammars/php.tmbundle: - text.html.php -vendor/grammars/pig-latin/: +vendor/grammars/pig-latin: - source.pig_latin vendor/grammars/pike-textmate: - source.pike @@ -526,11 +543,13 @@ vendor/grammars/scheme.tmbundle: - source.scheme vendor/grammars/scilab.tmbundle: - source.scilab -vendor/grammars/smali-sublime/smali.tmLanguage: +vendor/grammars/secondlife-lsl: +- source.lsl +vendor/grammars/smali-sublime: - source.smali vendor/grammars/smalltalk-tmbundle: - source.smalltalk -vendor/grammars/sourcepawn/: +vendor/grammars/sourcepawn: - source.sp vendor/grammars/sql.tmbundle: - source.sql @@ -541,9 +560,9 @@ vendor/grammars/standard-ml.tmbundle: - source.ml vendor/grammars/sublime-MuPAD: - source.mupad -vendor/grammars/sublime-aspectj/: +vendor/grammars/sublime-aspectj: - source.aspectj -vendor/grammars/sublime-autoit/: +vendor/grammars/sublime-autoit: - source.autoit vendor/grammars/sublime-befunge: - source.befunge @@ -551,12 +570,12 @@ vendor/grammars/sublime-bsv: - source.bsv vendor/grammars/sublime-cirru: - source.cirru -vendor/grammars/sublime-clips/: +vendor/grammars/sublime-clips: - source.clips vendor/grammars/sublime-glsl: - source.essl - source.glsl -vendor/grammars/sublime-golo/: +vendor/grammars/sublime-golo: - source.golo vendor/grammars/sublime-mask: - source.mask @@ -565,27 +584,31 @@ vendor/grammars/sublime-netlinx: - source.netlinx.erb vendor/grammars/sublime-nginx: - source.nginx -vendor/grammars/sublime-opal/: +vendor/grammars/sublime-opal: - source.opal - source.opalsysdefs vendor/grammars/sublime-pony: - source.pony +vendor/grammars/sublime-rexx: +- source.rexx vendor/grammars/sublime-robot-plugin: - text.robot vendor/grammars/sublime-rust: - source.rust -vendor/grammars/sublime-spintools/: +vendor/grammars/sublime-spintools: - source.regexp.spin - source.spin vendor/grammars/sublime-tea: - source.tea vendor/grammars/sublime-terra: - source.terra -vendor/grammars/sublime-text-ox/: +vendor/grammars/sublime-text-ox: - source.ox -vendor/grammars/sublime-typescript/: +vendor/grammars/sublime-typescript: - source.ts - source.tsx +- text.error-list +- text.find-refs vendor/grammars/sublime-varnish: - source.varnish.vcl vendor/grammars/sublime_cobol: @@ -593,12 +616,9 @@ vendor/grammars/sublime_cobol: - source.cobol - source.jcl - source.opencobol -vendor/grammars/sublime_man_page_support: -- source.man -- text.groff -vendor/grammars/sublimeassembly/: +vendor/grammars/sublimeassembly: - source.assembly -vendor/grammars/sublimeprolog/: +vendor/grammars/sublimeprolog: - source.prolog - source.prolog.eclipse vendor/grammars/sublimetext-cuda-cpp: @@ -617,12 +637,16 @@ vendor/grammars/turtle.tmbundle: - source.turtle vendor/grammars/verilog.tmbundle: - source.verilog +vendor/grammars/vhdl: +- source.vhdl vendor/grammars/vue-syntax-highlight: - text.html.vue -vendor/grammars/xc.tmbundle/: +vendor/grammars/xc.tmbundle: - source.xc vendor/grammars/xml.tmbundle: - text.xml - text.xml.xsl +vendor/grammars/xquery: +- source.xquery vendor/grammars/zephir-sublime: - source.php.zephir diff --git a/lib/linguist/heuristics.rb b/lib/linguist/heuristics.rb index 6f4ff997..1d5196f4 100644 --- a/lib/linguist/heuristics.rb +++ b/lib/linguist/heuristics.rb @@ -144,10 +144,22 @@ module Linguist end end - disambiguate ".for", ".f" do |data| + fortran_rx = /^([c*][^abd-z]| (subroutine|program|end|data)\s|\s*!)/i + + disambiguate ".f" do |data| if /^: /.match(data) Language["Forth"] - elsif /^([c*][^abd-z]| (subroutine|program|end)\s|\s*!)/i.match(data) + elsif data.include?("flowop") + Language["Filebench WML"] + elsif fortran_rx.match(data) + Language["FORTRAN"] + end + end + + disambiguate ".for" do |data| + if /^: /.match(data) + Language["Forth"] + elsif fortran_rx.match(data) Language["FORTRAN"] end end @@ -354,11 +366,19 @@ module Linguist disambiguate ".r" do |data| if /\bRebol\b/i.match(data) Language["Rebol"] - elsif data.include?("<-") + elsif /<-|^\s*#/.match(data) Language["R"] end end + disambiguate ".rno" do |data| + if /^\.!|^\.end lit(?:eral)?\b/i.match(data) + Language["RUNOFF"] + elsif /^\.\\" /.match(data) + Language["Groff"] + end + end + disambiguate ".rpy" do |data| if /(^(import|from|class|def)\s)/m.match(data) Language["Python"] @@ -422,7 +442,7 @@ module Linguist end disambiguate ".ts" do |data| - if data.include?("") + if data.include?(" [#] + # + # Returns the matching Language + def self.find_by_id(language_id) + @language_id_index[language_id.to_i] + end # Public: Look up Language by its name. # @@ -289,6 +305,9 @@ module Linguist # Set legacy search term @search_term = attributes[:search_term] || default_alias_name + # Set the language_id + @language_id = attributes[:language_id] + # Set extensions or default to []. @extensions = attributes[:extensions] || [] @interpreters = attributes[:interpreters] || [] @@ -351,6 +370,17 @@ module Linguist # Returns the name String attr_reader :search_term + # Public: Get language_id (used in GitHub search) + # + # Examples + # + # # => "1" + # # => "2" + # # => "3" + # + # Returns the integer language_id + attr_reader :language_id + # Public: Get the name of a TextMate-compatible scope # # Returns the scope @@ -547,6 +577,7 @@ module Linguist :group_name => options['group'], :searchable => options.fetch('searchable', true), :search_term => options['search_term'], + :language_id => options['language_id'], :extensions => Array(options['extensions']), :interpreters => options['interpreters'].sort, :filenames => options['filenames'], diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index 56df19f3..861a7efa 100755 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -12,8 +12,11 @@ # listed alphabetically) # interpreters - An Array of associated interpreters # searchable - Boolean flag to enable searching (defaults to true) -# search_term - Deprecated: Some languages maybe indexed under a +# search_term - Deprecated: Some languages may be indexed under a # different alias. Avoid defining new exceptions. +# language_id - Integer used as a language-name-independent indexed field so that we can rename +# languages in Linguist without reindexing all the code on GitHub. Must not be +# changed for existing languages without the explicit permission of GitHub staff. # color - CSS hex color to represent the language. # tm_scope - The TextMate scope that represents this programming # language. This should match one of the scopes listed in @@ -23,65 +26,84 @@ # in the statistics as the parent language. # # Any additions or modifications (even trivial) should have corresponding -# test change in `test/test_blob.rb`. +# test changes in `test/test_blob.rb`. # -# Please keep this list alphabetized. Capitalization comes before lower case. +# Please keep this list alphabetized. Capitalization comes before lowercase. +--- +1C Enterprise: + type: programming + color: "#814CCC" + extensions: + - ".bsl" + - ".os" + tm_scope: source.bsl + ace_mode: text + language_id: 0 ABAP: type: programming color: "#E8274B" extensions: - - .abap + - ".abap" ace_mode: abap - + language_id: 1 AGS Script: type: programming color: "#B9D9FF" aliases: - ags extensions: - - .asc - - .ash + - ".asc" + - ".ash" tm_scope: source.c++ ace_mode: c_cpp - + language_id: 2 AMPL: type: programming color: "#E6EFBB" extensions: - - .ampl - - .mod + - ".ampl" + - ".mod" tm_scope: source.ampl ace_mode: text - + language_id: 3 ANTLR: type: programming color: "#9DC3FF" extensions: - - .g4 + - ".g4" ace_mode: text - + language_id: 4 API Blueprint: type: markup color: "#2ACCA8" ace_mode: markdown extensions: - - .apib + - ".apib" tm_scope: text.html.markdown.source.gfm.apib - + language_id: 5 APL: type: programming color: "#5A8164" extensions: - - .apl - - .dyalog + - ".apl" + - ".dyalog" interpreters: - apl - aplx - dyalog tm_scope: source.apl ace_mode: text - + language_id: 6 +ASN.1: + type: data + color: "#aeead0" + extensions: + - ".asn" + - ".asn1" + tm_scope: source.asn + ace_mode: text + language_id: 7 ASP: type: programming color: "#6a40fd" @@ -91,27 +113,27 @@ ASP: - aspx - aspx-vb extensions: - - .asp - - .asax - - .ascx - - .ashx - - .asmx - - .aspx - - .axd + - ".asp" + - ".asax" + - ".ascx" + - ".ashx" + - ".asmx" + - ".aspx" + - ".axd" ace_mode: text - + language_id: 8 ATS: type: programming color: "#1ac620" aliases: - ats2 extensions: - - .dats - - .hats - - .sats + - ".dats" + - ".hats" + - ".sats" tm_scope: source.ats ace_mode: ocaml - + language_id: 9 ActionScript: type: programming tm_scope: source.actionscript.3 @@ -122,35 +144,35 @@ ActionScript: - actionscript3 - as3 extensions: - - .as + - ".as" ace_mode: actionscript - + language_id: 10 Ada: type: programming color: "#02f88c" extensions: - - .adb - - .ada - - .ads + - ".adb" + - ".ada" + - ".ads" aliases: - ada95 - ada2005 ace_mode: ada - + language_id: 11 Agda: type: programming color: "#315665" extensions: - - .agda + - ".agda" ace_mode: text - + language_id: 12 Alloy: - type: programming # 'modeling' would be more appropiate + type: programming color: "#64C800" extensions: - - .als + - ".als" ace_mode: text - + language_id: 13 Alpine Abuild: type: programming group: Shell @@ -161,7 +183,7 @@ Alpine Abuild: - APKBUILD tm_scope: source.shell ace_mode: sh - + language_id: 14 Ant Build System: type: data tm_scope: text.xml.ant @@ -169,80 +191,80 @@ Ant Build System: - ant.xml - build.xml ace_mode: xml - + language_id: 15 ApacheConf: type: markup aliases: - aconf - apache extensions: - - .apacheconf - - .vhost + - ".apacheconf" + - ".vhost" tm_scope: source.apache-config ace_mode: apache_conf - + language_id: 16 Apex: type: programming extensions: - - .cls + - ".cls" tm_scope: source.java ace_mode: java - + language_id: 17 Apollo Guidance Computer: type: programming color: "#0B3D91" group: Assembly extensions: - - .agc + - ".agc" tm_scope: source.agc ace_mode: assembly_x86 - + language_id: 18 AppleScript: type: programming aliases: - osascript extensions: - - .applescript - - .scpt + - ".applescript" + - ".scpt" interpreters: - osascript ace_mode: applescript color: "#101F1F" - + language_id: 19 Arc: type: programming color: "#aa2afe" extensions: - - .arc + - ".arc" tm_scope: none ace_mode: text - + language_id: 20 Arduino: type: programming color: "#bd79d1" extensions: - - .ino + - ".ino" tm_scope: source.c++ ace_mode: c_cpp - + language_id: 21 AsciiDoc: type: prose ace_mode: asciidoc wrap: true extensions: - - .asciidoc - - .adoc - - .asc + - ".asciidoc" + - ".adoc" + - ".asc" tm_scope: text.html.asciidoc - + language_id: 22 AspectJ: type: programming color: "#a957b0" extensions: - - .aj + - ".aj" tm_scope: source.aspectj ace_mode: text - + language_id: 23 Assembly: type: programming color: "#6E4C13" @@ -250,31 +272,31 @@ Assembly: aliases: - nasm extensions: - - .asm - - .a51 - - .inc - - .nasm + - ".asm" + - ".a51" + - ".inc" + - ".nasm" tm_scope: source.assembly ace_mode: assembly_x86 - + language_id: 24 Augeas: type: programming extensions: - - .aug + - ".aug" tm_scope: none ace_mode: text - + language_id: 25 AutoHotkey: type: programming color: "#6594b9" aliases: - ahk extensions: - - .ahk - - .ahkl + - ".ahk" + - ".ahkl" tm_scope: source.ahk ace_mode: autohotkey - + language_id: 26 AutoIt: type: programming color: "#1C3552" @@ -283,25 +305,25 @@ AutoIt: - AutoIt3 - AutoItScript extensions: - - .au3 + - ".au3" tm_scope: source.autoit ace_mode: autohotkey - + language_id: 27 Awk: type: programming extensions: - - .awk - - .auk - - .gawk - - .mawk - - .nawk + - ".awk" + - ".auk" + - ".gawk" + - ".mawk" + - ".nawk" interpreters: - awk - gawk - mawk - nawk ace_mode: text - + language_id: 28 Batchfile: type: programming search_term: bat @@ -311,43 +333,43 @@ Batchfile: - dosbatch - winbatch extensions: - - .bat - - .cmd - tm_scope: source.dosbatch + - ".bat" + - ".cmd" + tm_scope: source.batchfile ace_mode: batchfile color: "#C1F12E" - + language_id: 29 Befunge: type: programming extensions: - - .befunge + - ".befunge" ace_mode: text - + language_id: 30 Bison: type: programming group: Yacc tm_scope: source.bison extensions: - - .bison + - ".bison" ace_mode: text color: "#6A463F" - + language_id: 31 BitBake: type: programming tm_scope: none extensions: - - .bb + - ".bb" ace_mode: text - + language_id: 32 Blade: type: markup group: HTML extensions: - - .blade - - .blade.php + - ".blade" + - ".blade.php" tm_scope: text.html.php.blade ace_mode: text - + language_id: 33 BlitzBasic: type: programming aliases: @@ -356,70 +378,70 @@ BlitzBasic: - blitzplus - bplus extensions: - - .bb - - .decls + - ".bb" + - ".decls" tm_scope: source.blitzmax ace_mode: text - + language_id: 34 BlitzMax: type: programming color: "#cd6400" extensions: - - .bmx + - ".bmx" aliases: - bmax ace_mode: text - + language_id: 35 Bluespec: type: programming extensions: - - .bsv + - ".bsv" tm_scope: source.bsv ace_mode: verilog - + language_id: 36 Boo: type: programming color: "#d4bec1" extensions: - - .boo + - ".boo" ace_mode: text tm_scope: source.boo - + language_id: 37 Brainfuck: type: programming color: "#2F2530" extensions: - - .b - - .bf + - ".b" + - ".bf" tm_scope: source.bf ace_mode: text - + language_id: 38 Brightscript: type: programming extensions: - - .brs + - ".brs" tm_scope: source.brightscript ace_mode: text - + language_id: 39 Bro: type: programming extensions: - - .bro + - ".bro" ace_mode: text - + language_id: 40 C: type: programming color: "#555555" extensions: - - .c - - .cats - - .h - - .idc - - .w + - ".c" + - ".cats" + - ".h" + - ".idc" + - ".w" interpreters: - tcc ace_mode: c_cpp - + language_id: 41 C#: type: programming ace_mode: csharp @@ -429,11 +451,11 @@ C#: aliases: - csharp extensions: - - .cs - - .cake - - .cshtml - - .csx - + - ".cs" + - ".cake" + - ".cshtml" + - ".csx" + language_id: 42 C++: type: programming ace_mode: c_cpp @@ -442,181 +464,181 @@ C++: aliases: - cpp extensions: - - .cpp - - .c++ - - .cc - - .cp - - .cxx - - .h - - .h++ - - .hh - - .hpp - - .hxx - - .inc - - .inl - - .ipp - - .tcc - - .tpp - + - ".cpp" + - ".c++" + - ".cc" + - ".cp" + - ".cxx" + - ".h" + - ".h++" + - ".hh" + - ".hpp" + - ".hxx" + - ".inc" + - ".inl" + - ".ipp" + - ".tcc" + - ".tpp" + language_id: 43 C-ObjDump: type: data extensions: - - .c-objdump + - ".c-objdump" tm_scope: objdump.x86asm ace_mode: assembly_x86 - + language_id: 44 C2hs Haskell: type: programming group: Haskell aliases: - c2hs extensions: - - .chs + - ".chs" tm_scope: source.haskell ace_mode: haskell - + language_id: 45 CLIPS: type: programming extensions: - - .clp + - ".clp" tm_scope: source.clips ace_mode: text - + language_id: 46 CMake: type: programming extensions: - - .cmake - - .cmake.in + - ".cmake" + - ".cmake.in" filenames: - CMakeLists.txt ace_mode: text - + language_id: 47 COBOL: type: programming extensions: - - .cob - - .cbl - - .ccp - - .cobol - - .cpy + - ".cob" + - ".cbl" + - ".ccp" + - ".cobol" + - ".cpy" ace_mode: cobol - + language_id: 48 COLLADA: type: data extensions: - - .dae + - ".dae" tm_scope: text.xml ace_mode: xml - + language_id: 49 CSS: type: markup tm_scope: source.css ace_mode: css color: "#563d7c" extensions: - - .css - + - ".css" + language_id: 50 CSV: type: data ace_mode: text tm_scope: none extensions: - - .csv - + - ".csv" + language_id: 51 Cap'n Proto: type: programming tm_scope: source.capnp extensions: - - .capnp + - ".capnp" ace_mode: text - + language_id: 52 CartoCSS: type: programming aliases: - Carto extensions: - - .mss + - ".mss" ace_mode: text tm_scope: source.css.mss - + language_id: 53 Ceylon: type: programming extensions: - - .ceylon + - ".ceylon" ace_mode: text - + language_id: 54 Chapel: type: programming color: "#8dc63f" aliases: - chpl extensions: - - .chpl + - ".chpl" ace_mode: text - + language_id: 55 Charity: type: programming extensions: - - .ch + - ".ch" tm_scope: none ace_mode: text - + language_id: 56 ChucK: type: programming extensions: - - .ck + - ".ck" tm_scope: source.java ace_mode: java - + language_id: 57 Cirru: type: programming color: "#ccccff" ace_mode: cirru extensions: - - .cirru - + - ".cirru" + language_id: 58 Clarion: type: programming color: "#db901e" ace_mode: text extensions: - - .clw + - ".clw" tm_scope: source.clarion - + language_id: 59 Clean: type: programming color: "#3F85AF" extensions: - - .icl - - .dcl + - ".icl" + - ".dcl" tm_scope: source.clean ace_mode: text - + language_id: 60 Click: type: programming color: "#E4E6F3" extensions: - - .click + - ".click" tm_scope: source.click ace_mode: text - + language_id: 61 Clojure: type: programming ace_mode: clojure color: "#db5855" extensions: - - .clj - - .boot - - .cl2 - - .cljc - - .cljs - - .cljs.hl - - .cljscm - - .cljx - - .hic + - ".clj" + - ".boot" + - ".cl2" + - ".cljc" + - ".cljs" + - ".cljs.hl" + - ".cljscm" + - ".cljx" + - ".hic" filenames: - riemann.config - + language_id: 62 CoffeeScript: type: programming tm_scope: source.coffee @@ -626,17 +648,17 @@ CoffeeScript: - coffee - coffee-script extensions: - - .coffee - - ._coffee - - .cake - - .cjsx - - .cson - - .iced + - ".coffee" + - "._coffee" + - ".cake" + - ".cjsx" + - ".cson" + - ".iced" filenames: - Cakefile interpreters: - coffee - + language_id: 63 ColdFusion: type: programming group: ColdFusion @@ -648,10 +670,10 @@ ColdFusion: - cfml - coldfusion html extensions: - - .cfm - - .cfml + - ".cfm" + - ".cfml" tm_scope: text.html.cfm - + language_id: 64 ColdFusion CFC: type: programming group: ColdFusion @@ -661,9 +683,9 @@ ColdFusion CFC: aliases: - cfc extensions: - - .cfc + - ".cfc" tm_scope: source.cfscript - + language_id: 65 Common Lisp: type: programming tm_scope: source.lisp @@ -671,14 +693,14 @@ Common Lisp: aliases: - lisp extensions: - - .lisp - - .asd - - .cl - - .l - - .lsp - - .ny - - .podsl - - .sexp + - ".lisp" + - ".asd" + - ".cl" + - ".l" + - ".lsp" + - ".ny" + - ".podsl" + - ".sexp" interpreters: - lisp - sbcl @@ -686,363 +708,364 @@ Common Lisp: - clisp - ecl ace_mode: lisp - + language_id: 66 Component Pascal: type: programming color: "#B0CE4E" extensions: - - .cp - - .cps + - ".cp" + - ".cps" tm_scope: source.pascal aliases: - delphi - objectpascal ace_mode: pascal - + language_id: 67 Cool: type: programming extensions: - - .cl + - ".cl" tm_scope: source.cool ace_mode: text - + language_id: 68 Coq: type: programming extensions: - - .coq - - .v + - ".coq" + - ".v" ace_mode: text - + language_id: 69 Cpp-ObjDump: type: data extensions: - - .cppobjdump - - .c++-objdump - - .c++objdump - - .cpp-objdump - - .cxx-objdump + - ".cppobjdump" + - ".c++-objdump" + - ".c++objdump" + - ".cpp-objdump" + - ".cxx-objdump" tm_scope: objdump.x86asm aliases: - c++-objdump ace_mode: assembly_x86 - + language_id: 70 Creole: type: prose wrap: true extensions: - - .creole + - ".creole" tm_scope: text.html.creole ace_mode: text - + language_id: 71 Crystal: type: programming color: "#776791" extensions: - - .cr + - ".cr" ace_mode: ruby tm_scope: source.crystal interpreters: - crystal - + language_id: 72 Csound: type: programming aliases: - csound-orc extensions: - - .orc - - .udo + - ".orc" + - ".udo" tm_scope: source.csound ace_mode: text - + language_id: 73 Csound Document: type: programming aliases: - csound-csd extensions: - - .csd + - ".csd" tm_scope: source.csound-document ace_mode: text - + language_id: 74 Csound Score: type: programming aliases: - csound-sco extensions: - - .sco + - ".sco" tm_scope: source.csound-score ace_mode: text - + language_id: 75 Cucumber: type: programming extensions: - - .feature + - ".feature" tm_scope: text.gherkin.feature aliases: - gherkin ace_mode: text color: "#5B2063" - + language_id: 76 Cuda: type: programming extensions: - - .cu - - .cuh + - ".cu" + - ".cuh" tm_scope: source.cuda-c++ ace_mode: c_cpp color: "#3A4E3A" - + language_id: 77 Cycript: type: programming extensions: - - .cy + - ".cy" tm_scope: source.js ace_mode: javascript - + language_id: 78 Cython: type: programming group: Python extensions: - - .pyx - - .pxd - - .pxi + - ".pyx" + - ".pxd" + - ".pxi" aliases: - pyrex ace_mode: text - + language_id: 79 D: type: programming color: "#ba595e" extensions: - - .d - - .di + - ".d" + - ".di" ace_mode: d - + language_id: 80 D-ObjDump: type: data extensions: - - .d-objdump + - ".d-objdump" tm_scope: objdump.x86asm ace_mode: assembly_x86 - + language_id: 81 DIGITAL Command Language: type: programming aliases: - dcl extensions: - - .com + - ".com" tm_scope: none ace_mode: text - + language_id: 82 DM: type: programming color: "#447265" extensions: - - .dm + - ".dm" aliases: - byond tm_scope: source.dm ace_mode: c_cpp - + language_id: 83 DNS Zone: type: data extensions: - - .zone - - .arpa + - ".zone" + - ".arpa" tm_scope: text.zone_file ace_mode: text - + language_id: 84 DTrace: type: programming aliases: - dtrace-script extensions: - - .d + - ".d" interpreters: - dtrace tm_scope: source.c ace_mode: c_cpp - + language_id: 85 Darcs Patch: type: data search_term: dpatch aliases: - dpatch extensions: - - .darcspatch - - .dpatch + - ".darcspatch" + - ".dpatch" tm_scope: none ace_mode: text - + language_id: 86 Dart: type: programming color: "#00B4AB" extensions: - - .dart + - ".dart" interpreters: - dart ace_mode: dart - + language_id: 87 Diff: type: data extensions: - - .diff - - .patch + - ".diff" + - ".patch" aliases: - udiff tm_scope: source.diff ace_mode: diff - + language_id: 88 Dockerfile: type: data tm_scope: source.dockerfile extensions: - - .dockerfile + - ".dockerfile" filenames: - Dockerfile ace_mode: dockerfile - + language_id: 89 Dogescript: type: programming color: "#cca760" extensions: - - .djs + - ".djs" tm_scope: none ace_mode: text - + language_id: 90 Dylan: type: programming color: "#6c616e" extensions: - - .dylan - - .dyl - - .intr - - .lid + - ".dylan" + - ".dyl" + - ".intr" + - ".lid" ace_mode: text - + language_id: 91 E: type: programming color: "#ccce35" extensions: - - .E + - ".E" interpreters: - rune tm_scope: none ace_mode: text - + language_id: 92 ECL: type: programming color: "#8a1267" extensions: - - .ecl - - .eclxml + - ".ecl" + - ".eclxml" tm_scope: none ace_mode: text - + language_id: 93 ECLiPSe: type: programming group: prolog extensions: - - .ecl + - ".ecl" tm_scope: source.prolog.eclipse ace_mode: prolog - + language_id: 94 EJS: type: markup color: "#a91e50" group: HTML extensions: - - .ejs + - ".ejs" tm_scope: text.html.js ace_mode: ejs - + language_id: 95 EQ: type: programming color: "#a78649" extensions: - - .eq + - ".eq" tm_scope: source.cs ace_mode: csharp - + language_id: 96 Eagle: type: markup color: "#814C05" extensions: - - .sch - - .brd + - ".sch" + - ".brd" tm_scope: text.xml ace_mode: xml - + language_id: 97 Ecere Projects: type: data group: JavaScript extensions: - - .epj + - ".epj" tm_scope: source.json ace_mode: json - + language_id: 98 Eiffel: type: programming color: "#946d57" extensions: - - .e + - ".e" ace_mode: eiffel - + language_id: 99 Elixir: type: programming color: "#6e4a7e" extensions: - - .ex - - .exs + - ".ex" + - ".exs" ace_mode: elixir filenames: - mix.lock interpreters: - elixir - + language_id: 100 Elm: type: programming color: "#60B5CC" extensions: - - .elm + - ".elm" tm_scope: source.elm ace_mode: elm - + language_id: 101 Emacs Lisp: type: programming - tm_scope: source.lisp + tm_scope: source.emacs.lisp color: "#c065db" aliases: - elisp - emacs filenames: - - .emacs - - .emacs.desktop + - ".emacs" + - ".emacs.desktop" + - ".spacemacs" extensions: - - .el - - .emacs - - .emacs.desktop + - ".el" + - ".emacs" + - ".emacs.desktop" ace_mode: lisp - + language_id: 102 EmberScript: type: programming color: "#FFF4F3" extensions: - - .em - - .emberscript + - ".em" + - ".emberscript" tm_scope: source.coffee ace_mode: coffee - + language_id: 103 Erlang: type: programming color: "#B83998" extensions: - - .erl - - .app.src - - .es - - .escript - - .hrl - - .xrl - - .yrl + - ".erl" + - ".app.src" + - ".es" + - ".escript" + - ".hrl" + - ".xrl" + - ".yrl" filenames: - rebar.config - rebar.config.lock @@ -1050,7 +1073,7 @@ Erlang: ace_mode: erlang interpreters: - escript - + language_id: 104 F#: type: programming color: "#b845fc" @@ -1058,225 +1081,232 @@ F#: aliases: - fsharp extensions: - - .fs - - .fsi - - .fsx + - ".fs" + - ".fsi" + - ".fsx" tm_scope: source.fsharp ace_mode: text - + language_id: 105 FLUX: type: programming color: "#88ccff" extensions: - - .fx - - .flux + - ".fx" + - ".flux" tm_scope: none ace_mode: text - + language_id: 106 FORTRAN: type: programming color: "#4d41b1" extensions: - - .f90 - - .f - - .f03 - - .f08 - - .f77 - - .f95 - - .for - - .fpp + - ".f90" + - ".f" + - ".f03" + - ".f08" + - ".f77" + - ".f95" + - ".for" + - ".fpp" tm_scope: source.fortran.modern ace_mode: text - + language_id: 107 Factor: type: programming color: "#636746" extensions: - - .factor + - ".factor" filenames: - - .factor-boot-rc - - .factor-rc + - ".factor-boot-rc" + - ".factor-rc" ace_mode: text - + language_id: 108 Fancy: type: programming color: "#7b9db4" extensions: - - .fy - - .fancypack + - ".fy" + - ".fancypack" filenames: - Fakefile ace_mode: text - + language_id: 109 Fantom: type: programming color: "#dbded5" extensions: - - .fan + - ".fan" tm_scope: none ace_mode: text - + language_id: 110 +Filebench WML: + type: programming + extensions: + - ".f" + tm_scope: none + ace_mode: text + language_id: 111 Filterscript: type: programming group: RenderScript extensions: - - .fs + - ".fs" tm_scope: none ace_mode: text - + language_id: 112 Formatted: type: data extensions: - - .for - - .eam.fs + - ".for" + - ".eam.fs" tm_scope: none ace_mode: text - + language_id: 113 Forth: type: programming color: "#341708" extensions: - - .fth - - .4th - - .f - - .for - - .forth - - .fr - - .frt - - .fs + - ".fth" + - ".4th" + - ".f" + - ".for" + - ".forth" + - ".fr" + - ".frt" + - ".fs" ace_mode: forth - + language_id: 114 FreeMarker: type: programming color: "#0050b2" aliases: - ftl extensions: - - .ftl + - ".ftl" tm_scope: text.html.ftl ace_mode: ftl - + language_id: 115 Frege: type: programming color: "#00cafe" extensions: - - .fr + - ".fr" tm_scope: source.haskell ace_mode: haskell - + language_id: 116 G-code: type: data extensions: - - .g - - .gco - - .gcode + - ".g" + - ".gco" + - ".gcode" tm_scope: source.gcode ace_mode: gcode - + language_id: 117 GAMS: type: programming extensions: - - .gms + - ".gms" tm_scope: none ace_mode: text - + language_id: 118 GAP: type: programming extensions: - - .g - - .gap - - .gd - - .gi - - .tst + - ".g" + - ".gap" + - ".gd" + - ".gi" + - ".tst" tm_scope: source.gap ace_mode: text - + language_id: 119 GAS: type: programming group: Assembly extensions: - - .s - - .ms + - ".s" + - ".ms" tm_scope: source.assembly ace_mode: assembly_x86 - + language_id: 120 GCC Machine Description: type: programming extensions: - - .md + - ".md" tm_scope: source.lisp ace_mode: lisp - + language_id: 121 GDB: type: programming extensions: - - .gdb - - .gdbinit + - ".gdb" + - ".gdbinit" tm_scope: source.gdb ace_mode: text - + language_id: 122 GDScript: type: programming extensions: - - .gd + - ".gd" tm_scope: source.gdscript ace_mode: text - + language_id: 123 GLSL: type: programming extensions: - - .glsl - - .fp - - .frag - - .frg - - .fs - - .fsh - - .fshader - - .geo - - .geom - - .glslv - - .gshader - - .shader - - .vert - - .vrx - - .vsh - - .vshader + - ".glsl" + - ".fp" + - ".frag" + - ".frg" + - ".fs" + - ".fsh" + - ".fshader" + - ".geo" + - ".geom" + - ".glslv" + - ".gshader" + - ".shader" + - ".vert" + - ".vrx" + - ".vsh" + - ".vshader" ace_mode: glsl - + language_id: 124 Game Maker Language: type: programming color: "#8fb200" extensions: - - .gml + - ".gml" tm_scope: source.c++ ace_mode: c_cpp - + language_id: 125 Genshi: type: programming extensions: - - .kid + - ".kid" tm_scope: text.xml.genshi aliases: - xml+genshi - xml+kid ace_mode: xml - + language_id: 126 Gentoo Ebuild: type: programming group: Shell extensions: - - .ebuild + - ".ebuild" tm_scope: source.shell ace_mode: sh - + language_id: 127 Gentoo Eclass: type: programming group: Shell extensions: - - .eclass + - ".eclass" tm_scope: source.shell ace_mode: sh - + language_id: 128 Gettext Catalog: type: prose search_term: pot @@ -1284,152 +1314,157 @@ Gettext Catalog: aliases: - pot extensions: - - .po - - .pot + - ".po" + - ".pot" tm_scope: source.po ace_mode: text - + language_id: 129 Glyph: type: programming color: "#e4cc98" extensions: - - .glf + - ".glf" tm_scope: source.tcl ace_mode: tcl - + language_id: 130 Gnuplot: type: programming color: "#f0a9f0" extensions: - - .gp - - .gnu - - .gnuplot - - .plot - - .plt + - ".gp" + - ".gnu" + - ".gnuplot" + - ".plot" + - ".plt" interpreters: - gnuplot ace_mode: text - + language_id: 131 Go: type: programming color: "#375eab" extensions: - - .go + - ".go" ace_mode: golang - + language_id: 132 Golo: type: programming color: "#88562A" extensions: - - .golo + - ".golo" tm_scope: source.golo ace_mode: text - + language_id: 133 Gosu: type: programming color: "#82937f" extensions: - - .gs - - .gst - - .gsx - - .vark + - ".gs" + - ".gst" + - ".gsx" + - ".vark" tm_scope: source.gosu.2 ace_mode: text - + language_id: 134 Grace: type: programming extensions: - - .grace + - ".grace" tm_scope: source.grace ace_mode: text - + language_id: 135 Gradle: type: data extensions: - - .gradle + - ".gradle" tm_scope: source.groovy.gradle ace_mode: text - + language_id: 136 Grammatical Framework: type: programming aliases: - gf wrap: false extensions: - - .gf + - ".gf" searchable: true color: "#79aa7a" tm_scope: source.haskell ace_mode: haskell - + language_id: 137 Graph Modeling Language: type: data extensions: - - .gml + - ".gml" tm_scope: none ace_mode: text - + language_id: 138 GraphQL: type: data extensions: - - .graphql + - ".graphql" tm_scope: source.graphql ace_mode: text - + language_id: 139 Graphviz (DOT): type: data tm_scope: source.dot extensions: - - .dot - - .gv + - ".dot" + - ".gv" ace_mode: text - + language_id: 140 Groff: type: markup color: "#ecdebe" extensions: - - .man - - '.1' - - .1in - - .1m - - .1x - - '.2' - - '.3' - - .3in - - .3m - - .3qt - - .3x - - '.4' - - '.5' - - '.6' - - '.7' - - '.8' - - '.9' - - .l - - .me - - .ms - - .n - - .rno - - .roff - tm_scope: text.groff + - ".man" + - ".1" + - ".1in" + - ".1m" + - ".1x" + - ".2" + - ".3" + - ".3in" + - ".3m" + - ".3qt" + - ".3x" + - ".4" + - ".5" + - ".6" + - ".7" + - ".8" + - ".9" + - ".l" + - ".me" + - ".ms" + - ".n" + - ".rno" + - ".roff" + - ".tmac" + filenames: + - mmn + - mmt + tm_scope: text.roff aliases: - nroff + - troff ace_mode: text - + language_id: 141 Groovy: type: programming ace_mode: groovy color: "#e69f56" extensions: - - .groovy - - .grt - - .gtpl - - .gvy + - ".groovy" + - ".grt" + - ".gtpl" + - ".gvy" interpreters: - groovy filenames: - Jenkinsfile - + language_id: 142 Groovy Server Pages: type: programming group: Groovy @@ -1437,28 +1472,28 @@ Groovy Server Pages: - gsp - java server page extensions: - - .gsp + - ".gsp" tm_scope: text.html.jsp ace_mode: jsp - + language_id: 143 HCL: type: programming extensions: - - .hcl - - .tf + - ".hcl" + - ".tf" ace_mode: ruby tm_scope: source.ruby - + language_id: 144 HLSL: type: programming extensions: - - .hlsl - - .fx - - .fxh - - .hlsli + - ".hlsl" + - ".fx" + - ".fxh" + - ".hlsli" ace_mode: text tm_scope: none - + language_id: 145 HTML: type: markup tm_scope: text.html.basic @@ -1467,28 +1502,28 @@ HTML: aliases: - xhtml extensions: - - .html - - .htm - - .html.hl - - .inc - - .st - - .xht - - .xhtml - + - ".html" + - ".htm" + - ".html.hl" + - ".inc" + - ".st" + - ".xht" + - ".xhtml" + language_id: 146 HTML+Django: type: markup tm_scope: text.html.django group: HTML extensions: - - .mustache - - .jinja + - ".mustache" + - ".jinja" aliases: - django - html+django/jinja - html+jinja - htmldjango ace_mode: django - + language_id: 147 HTML+ECR: type: markup tm_scope: text.html.ecr @@ -1496,9 +1531,9 @@ HTML+ECR: aliases: - ecr extensions: - - .ecr + - ".ecr" ace_mode: text - + language_id: 148 HTML+EEX: type: markup tm_scope: text.html.elixir @@ -1506,9 +1541,9 @@ HTML+EEX: aliases: - eex extensions: - - .eex + - ".eex" ace_mode: text - + language_id: 149 HTML+ERB: type: markup tm_scope: text.html.erb @@ -1516,43 +1551,43 @@ HTML+ERB: aliases: - erb extensions: - - .erb - - .erb.deface + - ".erb" + - ".erb.deface" ace_mode: text - + language_id: 150 HTML+PHP: type: markup tm_scope: text.html.php group: HTML extensions: - - .phtml + - ".phtml" ace_mode: php - + language_id: 151 HTTP: type: data extensions: - - .http + - ".http" tm_scope: source.httpspec ace_mode: text - + language_id: 152 Hack: type: programming ace_mode: php extensions: - - .hh - - .php + - ".hh" + - ".php" tm_scope: text.html.php color: "#878787" - + language_id: 153 Haml: group: HTML type: markup extensions: - - .haml - - .haml.deface + - ".haml" + - ".haml.deface" ace_mode: haml color: "#ECE2A9" - + language_id: 154 Handlebars: type: markup color: "#01a9d6" @@ -1561,86 +1596,86 @@ Handlebars: - hbs - htmlbars extensions: - - .handlebars - - .hbs + - ".handlebars" + - ".hbs" tm_scope: text.html.handlebars ace_mode: handlebars - + language_id: 155 Harbour: type: programming color: "#0e60e3" extensions: - - .hb + - ".hb" tm_scope: source.harbour ace_mode: text - + language_id: 156 Haskell: type: programming color: "#29b544" extensions: - - .hs - - .hsc + - ".hs" + - ".hsc" interpreters: - runhaskell ace_mode: haskell - + language_id: 157 Haxe: type: programming ace_mode: haxe color: "#df7900" extensions: - - .hx - - .hxsl + - ".hx" + - ".hxsl" tm_scope: source.haxe.2 - + language_id: 158 Hy: type: programming ace_mode: text color: "#7790B2" extensions: - - .hy + - ".hy" aliases: - hylang tm_scope: source.hy - + language_id: 159 HyPhy: type: programming ace_mode: text extensions: - - .bf + - ".bf" tm_scope: none - + language_id: 160 IDL: type: programming color: "#a3522f" extensions: - - .pro - - .dlm + - ".pro" + - ".dlm" ace_mode: text - + language_id: 161 IGOR Pro: type: programming extensions: - - .ipf + - ".ipf" aliases: - igor - igorpro tm_scope: none ace_mode: text - + language_id: 162 INI: type: data extensions: - - .ini - - .cfg - - .prefs - - .pro - - .properties + - ".ini" + - ".cfg" + - ".prefs" + - ".pro" + - ".properties" tm_scope: source.ini aliases: - dosini ace_mode: ini - + language_id: 163 IRC log: type: data search_term: irc @@ -1648,64 +1683,64 @@ IRC log: - irc - irc logs extensions: - - .irclog - - .weechatlog + - ".irclog" + - ".weechatlog" tm_scope: none ace_mode: text - + language_id: 164 Idris: type: programming extensions: - - .idr - - .lidr + - ".idr" + - ".lidr" ace_mode: text tm_scope: source.idris - + language_id: 165 Inform 7: type: programming wrap: true extensions: - - .ni - - .i7x + - ".ni" + - ".i7x" tm_scope: source.inform7 aliases: - i7 - inform7 ace_mode: text - + language_id: 166 Inno Setup: type: programming extensions: - - .iss + - ".iss" tm_scope: none ace_mode: text - + language_id: 167 Io: type: programming color: "#a9188d" extensions: - - .io + - ".io" interpreters: - io ace_mode: io - + language_id: 168 Ioke: type: programming color: "#078193" extensions: - - .ik + - ".ik" interpreters: - ioke ace_mode: text - + language_id: 169 Isabelle: type: programming color: "#FEFE00" extensions: - - .thy + - ".thy" tm_scope: source.isabelle.theory ace_mode: text - + language_id: 170 Isabelle ROOT: type: programming group: Isabelle @@ -1713,27 +1748,27 @@ Isabelle ROOT: - ROOT tm_scope: source.isabelle.root ace_mode: text - + language_id: 171 J: type: programming color: "#9EEDFF" extensions: - - .ijs + - ".ijs" interpreters: - jconsole tm_scope: source.j ace_mode: text - + language_id: 172 JFlex: type: programming color: "#DBCA00" group: Lex extensions: - - .flex - - .jflex + - ".flex" + - ".jflex" tm_scope: source.jflex ace_mode: text - + language_id: 173 JSON: type: data tm_scope: source.json @@ -1741,70 +1776,70 @@ JSON: ace_mode: json searchable: false extensions: - - .json - - .geojson - - .JSON-tmLanguage - - .topojson + - ".json" + - ".geojson" + - ".JSON-tmLanguage" + - ".topojson" filenames: - - .arcconfig - - .jshintrc + - ".arcconfig" + - ".jshintrc" - composer.lock - mcmod.info - + language_id: 174 JSON5: type: data extensions: - - .json5 + - ".json5" tm_scope: source.js ace_mode: javascript - + language_id: 175 JSONLD: type: data group: JavaScript ace_mode: javascript extensions: - - .jsonld + - ".jsonld" tm_scope: source.js - + language_id: 176 JSONiq: color: "#40d47e" type: programming ace_mode: jsoniq extensions: - - .jq + - ".jq" tm_scope: source.jq - + language_id: 177 JSX: type: programming group: JavaScript extensions: - - .jsx + - ".jsx" tm_scope: source.js.jsx ace_mode: javascript - + language_id: 178 Jade: group: HTML type: markup extensions: - - .jade - - .pug + - ".jade" + - ".pug" tm_scope: text.jade ace_mode: jade - + language_id: 179 Jasmin: type: programming ace_mode: java extensions: - - .j + - ".j" tm_scope: source.jasmin - + language_id: 180 Java: type: programming ace_mode: java color: "#b07219" extensions: - - .java - + - ".java" + language_id: 181 Java Server Pages: type: programming group: Java @@ -1812,10 +1847,10 @@ Java Server Pages: aliases: - jsp extensions: - - .jsp + - ".jsp" tm_scope: text.html.jsp ace_mode: jsp - + language_id: 182 JavaScript: type: programming tm_scope: source.js @@ -1825,247 +1860,246 @@ JavaScript: - js - node extensions: - - .js - - ._js - - .bones - - .es - - .es6 - - .frag - - .gs - - .jake - - .jsb - - .jscad - - .jsfl - - .jsm - - .jss - - .njs - - .pac - - .sjs - - .ssjs - - .sublime-build - - .sublime-commands - - .sublime-completions - - .sublime-keymap - - .sublime-macro - - .sublime-menu - - .sublime-mousemap - - .sublime-project - - .sublime-settings - - .sublime-theme - - .sublime-workspace - - .sublime_metrics - - .sublime_session - - .xsjs - - .xsjslib + - ".js" + - "._js" + - ".bones" + - ".es" + - ".es6" + - ".frag" + - ".gs" + - ".jake" + - ".jsb" + - ".jscad" + - ".jsfl" + - ".jsm" + - ".jss" + - ".njs" + - ".pac" + - ".sjs" + - ".ssjs" + - ".sublime-build" + - ".sublime-commands" + - ".sublime-completions" + - ".sublime-keymap" + - ".sublime-macro" + - ".sublime-menu" + - ".sublime-mousemap" + - ".sublime-project" + - ".sublime-settings" + - ".sublime-theme" + - ".sublime-workspace" + - ".sublime_metrics" + - ".sublime_session" + - ".xsjs" + - ".xsjslib" filenames: - Jakefile interpreters: - node - + language_id: 183 Julia: type: programming extensions: - - .jl + - ".jl" color: "#a270ba" ace_mode: julia - + language_id: 184 Jupyter Notebook: type: markup ace_mode: json tm_scope: source.json color: "#DA5B0B" extensions: - - .ipynb + - ".ipynb" filenames: - Notebook aliases: - IPython Notebook - + language_id: 185 KRL: type: programming color: "#28431f" extensions: - - .krl + - ".krl" tm_scope: none ace_mode: text - + language_id: 186 KiCad: type: programming extensions: - - .sch - - .brd - - .kicad_pcb + - ".sch" + - ".brd" + - ".kicad_pcb" tm_scope: none ace_mode: text - + language_id: 187 Kit: type: markup ace_mode: html extensions: - - .kit + - ".kit" tm_scope: text.html.basic - + language_id: 188 Kotlin: type: programming color: "#F18E33" extensions: - - .kt - - .ktm - - .kts + - ".kt" + - ".ktm" + - ".kts" tm_scope: source.Kotlin ace_mode: text - + language_id: 189 LFE: type: programming extensions: - - .lfe + - ".lfe" color: "#004200" group: Erlang tm_scope: source.lisp ace_mode: lisp - + language_id: 190 LLVM: type: programming extensions: - - .ll + - ".ll" ace_mode: text color: "#185619" - + language_id: 191 LOLCODE: type: programming extensions: - - .lol + - ".lol" color: "#cc9900" tm_scope: none ace_mode: text - + language_id: 192 LSL: type: programming ace_mode: lsl extensions: - - .lsl - - .lslp + - ".lsl" + - ".lslp" interpreters: - lsl - color: '#3d9970' - + color: "#3d9970" + language_id: 193 LabVIEW: type: programming extensions: - - .lvproj + - ".lvproj" tm_scope: text.xml ace_mode: xml - + language_id: 194 Lasso: type: programming color: "#999999" extensions: - - .lasso - - .las - - .lasso8 - - .lasso9 - - .ldml + - ".lasso" + - ".las" + - ".lasso8" + - ".lasso9" + - ".ldml" tm_scope: file.lasso aliases: - lassoscript ace_mode: text - + language_id: 195 Latte: type: markup color: "#A8FF97" group: HTML extensions: - - .latte + - ".latte" tm_scope: text.html.smarty ace_mode: smarty - + language_id: 196 Lean: type: programming extensions: - - .lean - - .hlean + - ".lean" + - ".hlean" ace_mode: text - + language_id: 197 Less: type: markup group: CSS extensions: - - .less + - ".less" tm_scope: source.css.less ace_mode: less color: "#A1D9A1" - + language_id: 198 Lex: type: programming color: "#DBCA00" aliases: - flex extensions: - - .l - - .lex + - ".l" + - ".lex" tm_scope: none ace_mode: text - + language_id: 199 LilyPond: type: programming extensions: - - .ly - - .ily + - ".ly" + - ".ily" ace_mode: text - + language_id: 200 Limbo: type: programming extensions: - - .b - - .m + - ".b" + - ".m" tm_scope: none ace_mode: text - + language_id: 201 Linker Script: type: data extensions: - - .ld - - .lds + - ".ld" + - ".lds" filenames: - ld.script tm_scope: none ace_mode: text - + language_id: 202 Linux Kernel Module: type: data extensions: - - .mod + - ".mod" tm_scope: none ace_mode: text - + language_id: 203 Liquid: type: markup extensions: - - .liquid + - ".liquid" tm_scope: text.html.liquid ace_mode: liquid - + language_id: 204 Literate Agda: type: programming group: Agda extensions: - - .lagda + - ".lagda" tm_scope: none ace_mode: text - + language_id: 205 Literate CoffeeScript: type: programming tm_scope: source.litcoffee group: CoffeeScript - ace_mode: markdown + ace_mode: text wrap: true search_term: litcoffee aliases: - litcoffee extensions: - - .litcoffee - ace_mode: text - + - ".litcoffee" + language_id: 206 Literate Haskell: type: programming group: Haskell @@ -2074,10 +2108,10 @@ Literate Haskell: - lhaskell - lhs extensions: - - .lhs + - ".lhs" tm_scope: text.tex.latex.haskell ace_mode: text - + language_id: 207 LiveScript: type: programming color: "#499886" @@ -2085,112 +2119,112 @@ LiveScript: - live-script - ls extensions: - - .ls - - ._ls + - ".ls" + - "._ls" filenames: - Slakefile ace_mode: livescript - + language_id: 208 Logos: type: programming extensions: - - .xm - - .x - - .xi + - ".xm" + - ".x" + - ".xi" ace_mode: text tm_scope: source.logos - + language_id: 209 Logtalk: type: programming extensions: - - .lgt - - .logtalk + - ".lgt" + - ".logtalk" ace_mode: text - + language_id: 210 LookML: type: programming ace_mode: yaml color: "#652B81" extensions: - - .lookml + - ".lookml" tm_scope: source.yaml - + language_id: 211 LoomScript: type: programming extensions: - - .ls + - ".ls" tm_scope: source.loomscript ace_mode: text - + language_id: 212 Lua: type: programming ace_mode: lua color: "#000080" extensions: - - .lua - - .fcgi - - .nse - - .pd_lua - - .rbxs - - .wlua + - ".lua" + - ".fcgi" + - ".nse" + - ".pd_lua" + - ".rbxs" + - ".wlua" interpreters: - lua - + language_id: 213 M: type: programming aliases: - mumps extensions: - - .mumps - - .m + - ".mumps" + - ".m" tm_scope: source.lisp ace_mode: lisp - + language_id: 214 M4: type: programming extensions: - - .m4 + - ".m4" tm_scope: none ace_mode: text - + language_id: 215 M4Sugar: type: programming group: M4 aliases: - autoconf extensions: - - .m4 + - ".m4" filenames: - configure.ac tm_scope: none ace_mode: text - + language_id: 216 MAXScript: type: programming color: "#00a6a6" extensions: - - .ms - - .mcr + - ".ms" + - ".mcr" tm_scope: source.maxscript ace_mode: text - + language_id: 217 MTML: type: markup color: "#b7e1f4" extensions: - - .mtml + - ".mtml" tm_scope: text.html.basic ace_mode: html - + language_id: 218 MUF: type: programming group: Forth extensions: - - .muf - - .m + - ".muf" + - ".m" tm_scope: none ace_mode: forth - + language_id: 219 Makefile: type: programming color: "#427819" @@ -2199,10 +2233,10 @@ Makefile: - make - mf extensions: - - .mak - - .d - - .mk - - .mkfile + - ".mak" + - ".d" + - ".mk" + - ".mkfile" filenames: - BSDmakefile - GNUmakefile @@ -2218,69 +2252,69 @@ Makefile: interpreters: - make ace_mode: makefile - + language_id: 220 Mako: type: programming extensions: - - .mako - - .mao + - ".mako" + - ".mao" tm_scope: text.html.mako ace_mode: text - + language_id: 221 Markdown: type: prose ace_mode: markdown wrap: true extensions: - - .md - - .markdown - - .mkd - - .mkdn - - .mkdown - - .ron + - ".md" + - ".markdown" + - ".mkd" + - ".mkdn" + - ".mkdown" + - ".ron" tm_scope: source.gfm - + language_id: 222 Mask: type: markup color: "#f97732" ace_mode: mask extensions: - - .mask + - ".mask" tm_scope: source.mask - + language_id: 223 Mathematica: type: programming extensions: - - .mathematica - - .cdf - - .m - - .ma - - .mt - - .nb - - .nbp - - .wl - - .wlt + - ".mathematica" + - ".cdf" + - ".m" + - ".ma" + - ".mt" + - ".nb" + - ".nbp" + - ".wl" + - ".wlt" aliases: - mma ace_mode: text - + language_id: 224 Matlab: type: programming color: "#bb92ac" aliases: - octave extensions: - - .matlab - - .m + - ".matlab" + - ".m" ace_mode: matlab - + language_id: 225 Maven POM: type: data tm_scope: text.xml.pom filenames: - pom.xml ace_mode: xml - + language_id: 226 Max: type: programming color: "#c4a79c" @@ -2289,23 +2323,23 @@ Max: - maxmsp search_term: max/msp extensions: - - .maxpat - - .maxhelp - - .maxproj - - .mxt - - .pat + - ".maxpat" + - ".maxhelp" + - ".maxproj" + - ".mxt" + - ".pat" tm_scope: source.json ace_mode: json - + language_id: 227 MediaWiki: type: prose wrap: true extensions: - - .mediawiki - - .wiki + - ".mediawiki" + - ".wiki" tm_scope: text.html.mediawiki ace_mode: text - + language_id: 228 Mercury: type: programming color: "#ff2b2b" @@ -2313,166 +2347,165 @@ Mercury: interpreters: - mmi extensions: - - .m - - .moo + - ".m" + - ".moo" tm_scope: source.mercury - ace_mode: prolog - + language_id: 229 Metal: type: programming color: "#8f14e9" extensions: - - .metal + - ".metal" tm_scope: source.c++ ace_mode: c_cpp - -MiniD: # Legacy + language_id: 230 +MiniD: type: programming searchable: false extensions: - - .minid # Dummy extension + - ".minid" tm_scope: none ace_mode: text - + language_id: 231 Mirah: type: programming search_term: mirah color: "#c7a938" extensions: - - .druby - - .duby - - .mir - - .mirah + - ".druby" + - ".duby" + - ".mir" + - ".mirah" tm_scope: source.ruby ace_mode: ruby - + language_id: 232 Modelica: type: programming extensions: - - .mo + - ".mo" tm_scope: source.modelica ace_mode: text - + language_id: 233 Modula-2: type: programming extensions: - - .mod + - ".mod" tm_scope: source.modula2 ace_mode: text - + language_id: 234 Module Management System: type: programming extensions: - - .mms - - .mmk + - ".mms" + - ".mmk" filenames: - descrip.mmk - descrip.mms tm_scope: none ace_mode: text - + language_id: 235 Monkey: type: programming extensions: - - .monkey + - ".monkey" ace_mode: text tm_scope: source.monkey - + language_id: 236 Moocode: type: programming extensions: - - .moo + - ".moo" tm_scope: none ace_mode: text - + language_id: 237 MoonScript: type: programming extensions: - - .moon + - ".moon" interpreters: - moon ace_mode: text - + language_id: 238 Myghty: type: programming extensions: - - .myt + - ".myt" tm_scope: none ace_mode: text - + language_id: 239 NCL: type: programming color: "#28431f" extensions: - - .ncl + - ".ncl" tm_scope: source.ncl ace_mode: text - + language_id: 240 NL: type: data extensions: - - .nl + - ".nl" tm_scope: none ace_mode: text - + language_id: 241 NSIS: type: programming extensions: - - .nsi - - .nsh + - ".nsi" + - ".nsh" ace_mode: text - + language_id: 242 Nemerle: type: programming color: "#3d3c6e" extensions: - - .n + - ".n" ace_mode: text - + language_id: 243 NetLinx: type: programming color: "#0aa0ff" extensions: - - .axs - - .axi + - ".axs" + - ".axi" tm_scope: source.netlinx ace_mode: text - + language_id: 244 NetLinx+ERB: type: programming color: "#747faa" extensions: - - .axs.erb - - .axi.erb + - ".axs.erb" + - ".axi.erb" tm_scope: source.netlinx.erb ace_mode: text - + language_id: 245 NetLogo: type: programming color: "#ff6375" extensions: - - .nlogo + - ".nlogo" tm_scope: source.lisp ace_mode: lisp - + language_id: 246 NewLisp: type: programming lexer: NewLisp color: "#87AED7" extensions: - - .nl - - .lisp - - .lsp + - ".nl" + - ".lisp" + - ".lsp" interpreters: - newlisp tm_scope: source.lisp ace_mode: lisp - + language_id: 247 Nginx: type: markup extensions: - - .nginxconf - - .vhost + - ".nginxconf" + - ".vhost" filenames: - nginx.conf tm_scope: source.nginx @@ -2480,91 +2513,91 @@ Nginx: - nginx configuration file ace_mode: text color: "#9469E9" - + language_id: 248 Nimrod: type: programming color: "#37775b" extensions: - - .nim - - .nimrod + - ".nim" + - ".nimrod" ace_mode: text tm_scope: source.nim - + language_id: 249 Ninja: type: data tm_scope: source.ninja extensions: - - .ninja + - ".ninja" ace_mode: text - + language_id: 250 Nit: type: programming color: "#009917" extensions: - - .nit + - ".nit" tm_scope: source.nit ace_mode: text - + language_id: 251 Nix: type: programming color: "#7e7eff" extensions: - - .nix + - ".nix" aliases: - nixos tm_scope: source.nix ace_mode: nix - + language_id: 252 Nu: type: programming color: "#c9df40" aliases: - nush extensions: - - .nu + - ".nu" filenames: - Nukefile tm_scope: source.nu ace_mode: scheme interpreters: - nush - + language_id: 253 NumPy: type: programming group: Python extensions: - - .numpy - - .numpyw - - .numsc + - ".numpy" + - ".numpyw" + - ".numsc" tm_scope: none ace_mode: text color: "#9C8AF9" - + language_id: 254 OCaml: type: programming ace_mode: ocaml color: "#3be133" extensions: - - .ml - - .eliom - - .eliomi - - .ml4 - - .mli - - .mll - - .mly + - ".ml" + - ".eliom" + - ".eliomi" + - ".ml4" + - ".mli" + - ".mll" + - ".mly" interpreters: - ocaml - ocamlrun - ocamlscript tm_scope: source.ocaml - + language_id: 255 ObjDump: type: data extensions: - - .objdump + - ".objdump" tm_scope: objdump.x86asm ace_mode: assembly_x86 - + language_id: 256 Objective-C: type: programming tm_scope: source.objc @@ -2574,10 +2607,10 @@ Objective-C: - objc - objectivec extensions: - - .m - - .h + - ".m" + - ".h" ace_mode: objectivec - + language_id: 257 Objective-C++: type: programming tm_scope: source.objc++ @@ -2587,9 +2620,9 @@ Objective-C++: - objc++ - objectivec++ extensions: - - .mm + - ".mm" ace_mode: objectivec - + language_id: 258 Objective-J: type: programming color: "#ff0c5a" @@ -2598,42 +2631,42 @@ Objective-J: - objectivej - objj extensions: - - .j - - .sj + - ".j" + - ".sj" tm_scope: source.js.objj ace_mode: text - + language_id: 259 Omgrofl: type: programming extensions: - - .omgrofl + - ".omgrofl" color: "#cabbff" tm_scope: none ace_mode: text - + language_id: 260 Opa: type: programming extensions: - - .opa + - ".opa" ace_mode: text - + language_id: 261 Opal: type: programming color: "#f7ede0" extensions: - - .opal + - ".opal" tm_scope: source.opal ace_mode: text - + language_id: 262 OpenCL: type: programming group: C extensions: - - .cl - - .opencl + - ".cl" + - ".opencl" tm_scope: source.c ace_mode: c_cpp - + language_id: 263 OpenEdge ABL: type: programming aliases: @@ -2641,11 +2674,11 @@ OpenEdge ABL: - openedge - abl extensions: - - .p - - .cls + - ".p" + - ".cls" tm_scope: source.abl ace_mode: text - + language_id: 264 OpenRC runscript: type: programming group: Shell @@ -2655,148 +2688,146 @@ OpenRC runscript: - openrc-run tm_scope: source.shell ace_mode: sh - + language_id: 265 OpenSCAD: type: programming extensions: - - .scad + - ".scad" tm_scope: none ace_mode: scad - + language_id: 266 Org: type: prose wrap: true extensions: - - .org + - ".org" tm_scope: none ace_mode: text - + language_id: 267 Ox: type: programming extensions: - - .ox - - .oxh - - .oxo + - ".ox" + - ".oxh" + - ".oxo" tm_scope: source.ox ace_mode: text - + language_id: 268 Oxygene: type: programming color: "#cdd0e3" extensions: - - .oxygene + - ".oxygene" tm_scope: none ace_mode: text - + language_id: 269 Oz: type: programming color: "#fab738" extensions: - - .oz + - ".oz" tm_scope: source.oz ace_mode: text - + language_id: 270 PAWN: type: programming color: "#dbb284" extensions: - - .pwn - - .inc + - ".pwn" + - ".inc" tm_scope: source.pawn ace_mode: text - + language_id: 271 PHP: type: programming tm_scope: text.html.php ace_mode: php color: "#4F5D95" extensions: - - .php - - .aw - - .ctp - - .fcgi - - .inc - - .php3 - - .php4 - - .php5 - - .phps - - .phpt + - ".php" + - ".aw" + - ".ctp" + - ".fcgi" + - ".inc" + - ".php3" + - ".php4" + - ".php5" + - ".phps" + - ".phpt" filenames: - Phakefile interpreters: - php aliases: - inc - -#Oracle + language_id: 272 PLSQL: type: programming ace_mode: sql tm_scope: none color: "#dad8d8" extensions: - - .pls - - .pck - - .pkb - - .pks - - .plb - - .plsql - - .sql - -#Postgres + - ".pls" + - ".pck" + - ".pkb" + - ".pks" + - ".plb" + - ".plsql" + - ".sql" + language_id: 273 PLpgSQL: type: programming ace_mode: pgsql tm_scope: source.sql extensions: - - .sql - + - ".sql" + language_id: 274 POV-Ray SDL: type: programming aliases: - pov-ray - povray extensions: - - .pov - - .inc + - ".pov" + - ".inc" ace_mode: text - + language_id: 275 Pan: type: programming - color: '#cc0000' + color: "#cc0000" extensions: - - .pan + - ".pan" tm_scope: none ace_mode: text - + language_id: 276 Papyrus: type: programming color: "#6600cc" extensions: - - .psc + - ".psc" tm_scope: source.papyrus.skyrim ace_mode: text - + language_id: 277 Parrot: type: programming color: "#f3ca0a" extensions: - - .parrot # Dummy extension + - ".parrot" tm_scope: none ace_mode: text - + language_id: 278 Parrot Assembly: group: Parrot type: programming aliases: - pasm extensions: - - .pasm + - ".pasm" interpreters: - parrot tm_scope: none ace_mode: text - + language_id: 279 Parrot Internal Representation: group: Parrot tm_scope: source.parrot.pir @@ -2804,247 +2835,260 @@ Parrot Internal Representation: aliases: - pir extensions: - - .pir + - ".pir" interpreters: - parrot ace_mode: text - + language_id: 280 Pascal: type: programming color: "#E3F171" extensions: - - .pas - - .dfm - - .dpr - - .inc - - .lpr - - .pascal - - .pp + - ".pas" + - ".dfm" + - ".dpr" + - ".inc" + - ".lpr" + - ".pascal" + - ".pp" interpreters: - instantfpc ace_mode: pascal - + language_id: 281 Perl: type: programming tm_scope: source.perl ace_mode: perl color: "#0298c3" extensions: - - .pl - - .al - - .cgi - - .fcgi - - .perl - - .ph - - .plx - - .pm - - .pod - - .psgi - - .t + - ".pl" + - ".al" + - ".cgi" + - ".fcgi" + - ".perl" + - ".ph" + - ".plx" + - ".pm" + - ".pod" + - ".psgi" + - ".t" interpreters: - perl - + language_id: 282 Perl6: type: programming color: "#0000fb" extensions: - - .6pl - - .6pm - - .nqp - - .p6 - - .p6l - - .p6m - - .pl - - .pl6 - - .pm - - .pm6 - - .t + - ".6pl" + - ".6pm" + - ".nqp" + - ".p6" + - ".p6l" + - ".p6m" + - ".pl" + - ".pl6" + - ".pm" + - ".pm6" + - ".t" filenames: - Rexfile interpreters: - perl6 tm_scope: source.perl6fe ace_mode: perl - + language_id: 283 Pickle: type: data extensions: - - .pkl + - ".pkl" tm_scope: none ace_mode: text - + language_id: 284 PicoLisp: type: programming extensions: - - .l + - ".l" interpreters: - picolisp - pil tm_scope: source.lisp ace_mode: lisp - + language_id: 285 PigLatin: type: programming color: "#fcd7de" extensions: - - .pig + - ".pig" tm_scope: source.pig_latin ace_mode: text - + language_id: 286 Pike: type: programming color: "#005390" extensions: - - .pike - - .pmod + - ".pike" + - ".pmod" interpreters: - pike ace_mode: text - + language_id: 287 Pod: type: prose ace_mode: perl wrap: true extensions: - - .pod + - ".pod" tm_scope: none - + language_id: 288 PogoScript: type: programming color: "#d80074" extensions: - - .pogo + - ".pogo" tm_scope: source.pogoscript ace_mode: text - + language_id: 289 Pony: type: programming extensions: - - .pony + - ".pony" tm_scope: source.pony ace_mode: text - + language_id: 290 PostScript: type: markup + color: "#da291c" extensions: - - .ps - - .eps + - ".ps" + - ".eps" tm_scope: source.postscript aliases: - postscr ace_mode: text - + language_id: 291 +PowerBuilder: + type: programming + color: "#8f0f8d" + extensions: + - ".pbt" + - ".sra" + - ".sru" + - ".srw" + tm_scope: none + ace_mode: text + language_id: 292 PowerShell: type: programming ace_mode: powershell aliases: - posh extensions: - - .ps1 - - .psd1 - - .psm1 - + - ".ps1" + - ".psd1" + - ".psm1" + language_id: 293 Processing: type: programming color: "#0096D8" extensions: - - .pde + - ".pde" ace_mode: text - + language_id: 294 Prolog: type: programming color: "#74283c" extensions: - - .pl - - .pro - - .prolog - - .yap + - ".pl" + - ".pro" + - ".prolog" + - ".yap" interpreters: - swipl - yap tm_scope: source.prolog ace_mode: prolog - + language_id: 295 Propeller Spin: type: programming color: "#7fa2a7" extensions: - - .spin + - ".spin" tm_scope: source.spin ace_mode: text - + language_id: 296 Protocol Buffer: type: markup aliases: - protobuf - Protocol Buffers extensions: - - .proto + - ".proto" tm_scope: source.protobuf ace_mode: protobuf - + language_id: 297 Public Key: type: data extensions: - - .asc - - .pub + - ".asc" + - ".pub" tm_scope: none ace_mode: text - + language_id: 298 Puppet: type: programming color: "#302B6D" extensions: - - .pp + - ".pp" filenames: - Modulefile ace_mode: text tm_scope: source.puppet - + language_id: 299 Pure Data: type: programming color: "#91de79" extensions: - - .pd + - ".pd" tm_scope: none ace_mode: text - + language_id: 300 PureBasic: type: programming color: "#5a6986" extensions: - - .pb - - .pbi + - ".pb" + - ".pbi" tm_scope: none ace_mode: text - + language_id: 301 PureScript: type: programming color: "#1D222D" extensions: - - .purs + - ".purs" tm_scope: source.purescript ace_mode: haskell - + language_id: 302 Python: type: programming ace_mode: python color: "#3572A5" extensions: - - .py - - .bzl - - .cgi - - .fcgi - - .gyp - - .lmi - - .pyde - - .pyp - - .pyt - - .pyw - - .rpy - - .tac - - .wsgi - - .xpy + - ".py" + - ".bzl" + - ".cgi" + - ".fcgi" + - ".gyp" + - ".lmi" + - ".pyde" + - ".pyp" + - ".pyt" + - ".pyw" + - ".rpy" + - ".spec" + - ".tac" + - ".wsgi" + - ".xpy" filenames: - BUCK - BUILD @@ -3058,34 +3102,34 @@ Python: - python3 aliases: - rusthon - + language_id: 303 Python traceback: type: data group: Python searchable: false extensions: - - .pytb + - ".pytb" tm_scope: text.python.traceback ace_mode: text - + language_id: 304 QML: type: programming color: "#44a51c" extensions: - - .qml - - .qbs + - ".qml" + - ".qbs" tm_scope: source.qml ace_mode: text - + language_id: 305 QMake: type: programming extensions: - - .pro - - .pri + - ".pro" + - ".pri" interpreters: - qmake ace_mode: text - + language_id: 306 R: type: programming color: "#198CE7" @@ -3094,159 +3138,187 @@ R: - Rscript - splus extensions: - - .r - - .rd - - .rsx + - ".r" + - ".rd" + - ".rsx" filenames: - - .Rprofile + - ".Rprofile" interpreters: - Rscript ace_mode: r - + language_id: 307 RAML: type: markup ace_mode: yaml tm_scope: source.yaml color: "#77d9fb" extensions: - - .raml - + - ".raml" + language_id: 308 RDoc: type: prose ace_mode: rdoc wrap: true extensions: - - .rdoc + - ".rdoc" tm_scope: text.rdoc - + language_id: 309 REALbasic: type: programming extensions: - - .rbbas - - .rbfrm - - .rbmnu - - .rbres - - .rbtbar - - .rbuistate + - ".rbbas" + - ".rbfrm" + - ".rbmnu" + - ".rbres" + - ".rbtbar" + - ".rbuistate" tm_scope: source.vbnet ace_mode: text - + language_id: 310 +REXX: + type: programming + aliases: + - arexx + extensions: + - ".rexx" + - ".pprx" + - ".rex" + tm_scope: source.rexx + ace_mode: text + language_id: 311 RHTML: type: markup group: HTML extensions: - - .rhtml + - ".rhtml" tm_scope: text.html.erb aliases: - html+ruby ace_mode: rhtml - + language_id: 312 RMarkdown: type: prose wrap: true ace_mode: markdown extensions: - - .rmd + - ".rmd" tm_scope: source.gfm - + language_id: 313 +RPM Spec: + type: data + tm_scope: source.rpm-spec + extensions: + - ".spec" + aliases: + - specfile + ace_mode: text + language_id: 314 +RUNOFF: + type: markup + color: "#665a4e" + extensions: + - ".rnh" + - ".rno" + tm_scope: text.runoff + ace_mode: text + language_id: 315 Racket: type: programming color: "#22228f" extensions: - - .rkt - - .rktd - - .rktl - - .scrbl + - ".rkt" + - ".rktd" + - ".rktl" + - ".scrbl" interpreters: - racket tm_scope: source.racket ace_mode: lisp - + language_id: 316 Ragel in Ruby Host: type: programming color: "#9d5200" extensions: - - .rl + - ".rl" aliases: - ragel-rb - ragel-ruby tm_scope: none ace_mode: text - + language_id: 317 Raw token data: type: data search_term: raw aliases: - raw extensions: - - .raw + - ".raw" tm_scope: none ace_mode: text - + language_id: 318 Rebol: type: programming color: "#358a5b" extensions: - - .reb - - .r - - .r2 - - .r3 - - .rebol + - ".reb" + - ".r" + - ".r2" + - ".r3" + - ".rebol" ace_mode: text tm_scope: source.rebol - + language_id: 319 Red: type: programming - color: "#ee0000" + color: "#f50000" extensions: - - .red - - .reds + - ".red" + - ".reds" aliases: - red/system tm_scope: source.red ace_mode: text - + language_id: 320 Redcode: type: programming extensions: - - .cw + - ".cw" tm_scope: none ace_mode: text - + language_id: 321 Ren'Py: type: programming aliases: - renpy color: "#ff7f7f" extensions: - - .rpy + - ".rpy" tm_scope: source.renpy ace_mode: python - + language_id: 322 RenderScript: type: programming extensions: - - .rs - - .rsh + - ".rs" + - ".rsh" tm_scope: none ace_mode: text - + language_id: 323 RobotFramework: type: programming extensions: - - .robot - # - .txt + - ".robot" tm_scope: text.robot ace_mode: text - + language_id: 324 Rouge: type: programming ace_mode: clojure color: "#cc0088" extensions: - - .rg + - ".rg" tm_scope: source.clojure - + language_id: 325 Ruby: type: programming ace_mode: ruby @@ -3258,25 +3330,26 @@ Ruby: - rb - rbx extensions: - - .rb - - .builder - - .fcgi - - .gemspec - - .god - - .irbrc - - .jbuilder - - .mspec - - .pluginspec - - .podspec - - .rabl - - .rake - - .rbuild - - .rbw - - .rbx - - .ru - - .ruby - - .thor - - .watchr + - ".rb" + - ".builder" + - ".fcgi" + - ".gemspec" + - ".god" + - ".irbrc" + - ".jbuilder" + - ".mspec" + - ".pluginspec" + - ".podspec" + - ".rabl" + - ".rake" + - ".rbuild" + - ".rbw" + - ".rbx" + - ".ru" + - ".ruby" + - ".spec" + - ".thor" + - ".watchr" interpreters: - ruby - macruby @@ -3284,7 +3357,7 @@ Ruby: - jruby - rbx filenames: - - .pryrc + - ".pryrc" - Appraisals - Berksfile - Brewfile @@ -3302,37 +3375,37 @@ Ruby: - Thorfile - Vagrantfile - buildfile - + language_id: 326 Rust: type: programming color: "#dea584" extensions: - - .rs - - .rs.in + - ".rs" + - ".rs.in" ace_mode: rust - + language_id: 327 SAS: type: programming color: "#B34936" extensions: - - .sas + - ".sas" tm_scope: source.sas ace_mode: text - + language_id: 328 SCSS: type: markup tm_scope: source.scss group: CSS ace_mode: scss extensions: - - .scss + - ".scss" color: "#CF649A" - + language_id: 329 SMT: type: programming extensions: - - .smt2 - - .smt + - ".smt2" + - ".smt" interpreters: - boolector - cvc4 @@ -3346,79 +3419,78 @@ SMT: - z3 tm_scope: source.smt ace_mode: text - + language_id: 330 SPARQL: type: data tm_scope: source.sparql ace_mode: text extensions: - - .sparql - - .rq - + - ".sparql" + - ".rq" + language_id: 331 SQF: type: programming color: "#3F3F3F" extensions: - - .sqf - - .hqf + - ".sqf" + - ".hqf" tm_scope: source.sqf ace_mode: text - + language_id: 332 SQL: type: data tm_scope: source.sql ace_mode: sql extensions: - - .sql - - .cql - - .ddl - - .inc - - .prc - - .tab - - .udf - - .viw - -#IBM DB2 + - ".sql" + - ".cql" + - ".ddl" + - ".inc" + - ".prc" + - ".tab" + - ".udf" + - ".viw" + language_id: 333 SQLPL: type: programming ace_mode: sql tm_scope: source.sql extensions: - - .sql - - .db2 - + - ".sql" + - ".db2" + language_id: 334 SRecode Template: type: markup color: "#348a34" tm_scope: source.lisp ace_mode: lisp extensions: - - .srt - + - ".srt" + language_id: 335 STON: type: data group: Smalltalk extensions: - - .ston + - ".ston" tm_scope: source.smalltalk ace_mode: text - + language_id: 336 SVG: type: data extensions: - - .svg + - ".svg" tm_scope: text.xml ace_mode: xml - + language_id: 337 Sage: type: programming group: Python extensions: - - .sage - - .sagews + - ".sage" + - ".sagews" tm_scope: source.python ace_mode: python - + language_id: 338 SaltStack: type: programming color: "#646464" @@ -3426,47 +3498,47 @@ SaltStack: - saltstate - salt extensions: - - .sls + - ".sls" tm_scope: source.yaml.salt ace_mode: yaml - + language_id: 339 Sass: type: markup tm_scope: source.sass group: CSS extensions: - - .sass + - ".sass" ace_mode: sass color: "#CF649A" - + language_id: 340 Scala: type: programming ace_mode: scala - color: "#DC322F" + color: "#c22d40" extensions: - - .scala - - .sbt - - .sc + - ".scala" + - ".sbt" + - ".sc" interpreters: - scala - + language_id: 341 Scaml: group: HTML type: markup extensions: - - .scaml + - ".scaml" tm_scope: source.scaml ace_mode: text - + language_id: 342 Scheme: type: programming color: "#1e4aec" extensions: - - .scm - - .sld - - .sls - - .sps - - .ss + - ".scm" + - ".sld" + - ".sls" + - ".sps" + - ".ss" interpreters: - guile - bigloo @@ -3475,23 +3547,23 @@ Scheme: - gosh - r6rs ace_mode: scheme - + language_id: 343 Scilab: type: programming extensions: - - .sci - - .sce - - .tst + - ".sci" + - ".sce" + - ".tst" ace_mode: text - + language_id: 344 Self: type: programming color: "#0579aa" extensions: - - .self + - ".self" tm_scope: none ace_mode: text - + language_id: 345 Shell: type: programming search_term: bash @@ -3502,22 +3574,22 @@ Shell: - bash - zsh extensions: - - .sh - - .bash - - .bats - - .cgi - - .command - - .fcgi - - .ksh - - .sh.in - - .tmux - - .tool - - .zsh + - ".sh" + - ".bash" + - ".bats" + - ".cgi" + - ".command" + - ".fcgi" + - ".ksh" + - ".sh.in" + - ".tmux" + - ".tool" + - ".zsh" filenames: - - .bash_history - - .bash_logout - - .bash_profile - - .bashrc + - ".bash_history" + - ".bash_logout" + - ".bash_profile" + - ".bashrc" - PKGBUILD - gradlew interpreters: @@ -3526,204 +3598,204 @@ Shell: - sh - zsh ace_mode: sh - + language_id: 346 ShellSession: type: programming extensions: - - .sh-session + - ".sh-session" aliases: - bash session - console tm_scope: text.shell-session ace_mode: sh - + language_id: 347 Shen: type: programming color: "#120F14" extensions: - - .shen + - ".shen" tm_scope: none ace_mode: text - + language_id: 348 Slash: type: programming color: "#007eff" extensions: - - .sl + - ".sl" tm_scope: text.html.slash ace_mode: text - + language_id: 349 Slim: group: HTML type: markup color: "#ff8f77" extensions: - - .slim + - ".slim" tm_scope: text.slim ace_mode: text - + language_id: 350 Smali: type: programming extensions: - - .smali + - ".smali" ace_mode: text tm_scope: source.smali - + language_id: 351 Smalltalk: type: programming color: "#596706" extensions: - - .st - - .cs + - ".st" + - ".cs" aliases: - squeak ace_mode: text - + language_id: 352 Smarty: type: programming extensions: - - .tpl + - ".tpl" ace_mode: smarty tm_scope: text.html.smarty - + language_id: 353 SourcePawn: type: programming color: "#5c7611" aliases: - sourcemod extensions: - - .sp - - .inc - - .sma + - ".sp" + - ".inc" + - ".sma" tm_scope: source.sp ace_mode: text - + language_id: 354 Squirrel: type: programming color: "#800000" extensions: - - .nut + - ".nut" tm_scope: source.c++ ace_mode: c_cpp - + language_id: 355 Stan: type: programming color: "#b2011d" extensions: - - .stan + - ".stan" ace_mode: text tm_scope: source.stan - + language_id: 356 Standard ML: type: programming color: "#dc566d" aliases: - sml extensions: - - .ML - - .fun - - .sig - - .sml + - ".ML" + - ".fun" + - ".sig" + - ".sml" tm_scope: source.ml ace_mode: text - + language_id: 357 Stata: type: programming extensions: - - .do - - .ado - - .doh - - .ihlp - - .mata - - .matah - - .sthlp + - ".do" + - ".ado" + - ".doh" + - ".ihlp" + - ".mata" + - ".matah" + - ".sthlp" ace_mode: text - + language_id: 358 Stylus: type: markup group: CSS extensions: - - .styl + - ".styl" tm_scope: source.stylus ace_mode: stylus - + language_id: 359 SubRip Text: type: data extensions: - - .srt + - ".srt" ace_mode: text tm_scope: text.srt - + language_id: 360 SuperCollider: type: programming color: "#46390b" extensions: - - .sc - - .scd + - ".sc" + - ".scd" interpreters: - sclang - scsynth tm_scope: source.supercollider ace_mode: text - + language_id: 361 Swift: type: programming color: "#ffac45" extensions: - - .swift + - ".swift" ace_mode: text - + language_id: 362 SystemVerilog: type: programming color: "#DAE1C2" extensions: - - .sv - - .svh - - .vh + - ".sv" + - ".svh" + - ".vh" ace_mode: verilog - + language_id: 363 TLA: type: programming extensions: - - .tla + - ".tla" tm_scope: source.tla ace_mode: text - + language_id: 364 TOML: type: data extensions: - - .toml + - ".toml" tm_scope: source.toml ace_mode: toml - + language_id: 365 TXL: type: programming extensions: - - .txl + - ".txl" tm_scope: source.txl ace_mode: text - + language_id: 366 Tcl: type: programming color: "#e4cc98" extensions: - - .tcl - - .adp - - .tm + - ".tcl" + - ".adp" + - ".tm" interpreters: - tclsh - wish ace_mode: tcl - + language_id: 367 Tcsh: type: programming group: Shell extensions: - - .tcsh - - .csh + - ".tcsh" + - ".csh" tm_scope: source.shell ace_mode: sh - + language_id: 368 TeX: type: markup color: "#3D6117" @@ -3732,49 +3804,49 @@ TeX: aliases: - latex extensions: - - .tex - - .aux - - .bbx - - .bib - - .cbx - - .cls - - .dtx - - .ins - - .lbx - - .ltx - - .mkii - - .mkiv - - .mkvi - - .sty - - .toc - + - ".tex" + - ".aux" + - ".bbx" + - ".bib" + - ".cbx" + - ".cls" + - ".dtx" + - ".ins" + - ".lbx" + - ".ltx" + - ".mkii" + - ".mkiv" + - ".mkvi" + - ".sty" + - ".toc" + language_id: 369 Tea: type: markup extensions: - - .tea + - ".tea" tm_scope: source.tea ace_mode: text - + language_id: 370 Terra: type: programming extensions: - - .t + - ".t" color: "#00004c" ace_mode: lua interpreters: - lua - + language_id: 371 Text: type: prose wrap: true aliases: - fundamental extensions: - - .txt - - .fr - - .nb - - .ncl - - .no + - ".txt" + - ".fr" + - ".nb" + - ".ncl" + - ".no" filenames: - COPYING - INSTALL @@ -3789,142 +3861,142 @@ Text: - test.me tm_scope: none ace_mode: text - + language_id: 372 Textile: type: prose ace_mode: textile wrap: true extensions: - - .textile + - ".textile" tm_scope: none - + language_id: 373 Thrift: type: programming tm_scope: source.thrift extensions: - - .thrift + - ".thrift" ace_mode: text - + language_id: 374 Turing: type: programming color: "#cf142b" extensions: - - .t - - .tu + - ".t" + - ".tu" tm_scope: source.turing ace_mode: text - + language_id: 375 Turtle: type: data extensions: - - .ttl + - ".ttl" tm_scope: source.turtle ace_mode: text - + language_id: 376 Twig: type: markup group: HTML extensions: - - .twig + - ".twig" tm_scope: text.html.twig ace_mode: twig - + language_id: 377 TypeScript: type: programming color: "#2b7489" aliases: - ts extensions: - - .ts - - .tsx + - ".ts" + - ".tsx" tm_scope: source.ts ace_mode: typescript - + language_id: 378 Unified Parallel C: type: programming group: C ace_mode: c_cpp color: "#4e3617" extensions: - - .upc + - ".upc" tm_scope: source.c - + language_id: 379 Unity3D Asset: type: data ace_mode: yaml extensions: - - .anim - - .asset - - .mat - - .meta - - .prefab - - .unity + - ".anim" + - ".asset" + - ".mat" + - ".meta" + - ".prefab" + - ".unity" tm_scope: source.yaml - + language_id: 380 Uno: type: programming extensions: - - .uno + - ".uno" ace_mode: csharp tm_scope: source.cs - + language_id: 381 UnrealScript: type: programming color: "#a54c4d" extensions: - - .uc + - ".uc" tm_scope: source.java ace_mode: java - + language_id: 382 UrWeb: type: programming aliases: - Ur/Web - Ur extensions: - - .ur - - .urs + - ".ur" + - ".urs" tm_scope: source.ur ace_mode: text - + language_id: 383 VCL: group: Perl type: programming extensions: - - .vcl + - ".vcl" tm_scope: source.varnish.vcl ace_mode: text - + language_id: 384 VHDL: type: programming color: "#adb2cb" extensions: - - .vhdl - - .vhd - - .vhf - - .vhi - - .vho - - .vhs - - .vht - - .vhw + - ".vhdl" + - ".vhd" + - ".vhf" + - ".vhi" + - ".vho" + - ".vhs" + - ".vht" + - ".vhw" ace_mode: vhdl - + language_id: 385 Vala: type: programming color: "#fbe5cd" extensions: - - .vala - - .vapi + - ".vala" + - ".vapi" ace_mode: vala - + language_id: 386 Verilog: type: programming color: "#b2b7f8" extensions: - - .v - - .veo + - ".v" + - ".veo" ace_mode: verilog - + language_id: 387 VimL: type: programming color: "#199f4b" @@ -3933,104 +4005,104 @@ VimL: - vim - nvim extensions: - - .vim + - ".vim" filenames: - - .nvimrc - - .vimrc + - ".nvimrc" + - ".vimrc" - _vimrc - gvimrc - nvimrc - vimrc ace_mode: text - + language_id: 388 Visual Basic: type: programming color: "#945db7" extensions: - - .vb - - .bas - - .cls - - .frm - - .frx - - .vba - - .vbhtml - - .vbs + - ".vb" + - ".bas" + - ".cls" + - ".frm" + - ".frx" + - ".vba" + - ".vbhtml" + - ".vbs" tm_scope: source.vbnet aliases: - vb.net - vbnet ace_mode: text - + language_id: 389 Volt: type: programming color: "#1F1F1F" extensions: - - .volt + - ".volt" tm_scope: source.d ace_mode: d - + language_id: 390 Vue: type: markup color: "#2c3e50" extensions: - - .vue + - ".vue" tm_scope: text.html.vue ace_mode: html - + language_id: 391 Wavefront Material: type: data extensions: - - .mtl + - ".mtl" tm_scope: source.wavefront.mtl ace_mode: text - + language_id: 392 Wavefront Object: type: data extensions: - - .obj + - ".obj" tm_scope: source.wavefront.obj ace_mode: text - + language_id: 393 Web Ontology Language: type: markup color: "#9cc9dd" extensions: - - .owl + - ".owl" tm_scope: text.xml ace_mode: xml - + language_id: 394 WebIDL: type: programming extensions: - - .webidl + - ".webidl" tm_scope: source.webidl ace_mode: text - + language_id: 395 World of Warcraft Addon Data: type: data extensions: - - .toc + - ".toc" tm_scope: source.toc ace_mode: text - + language_id: 396 X10: type: programming aliases: - xten ace_mode: text extensions: - - .x10 + - ".x10" color: "#4B6BEF" tm_scope: source.x10 - + language_id: 397 XC: type: programming color: "#99DA07" extensions: - - .xc + - ".xc" tm_scope: source.xc ace_mode: c_cpp - + language_id: 398 XML: type: data ace_mode: xml @@ -4039,93 +4111,94 @@ XML: - xsd - wsdl extensions: - - .xml - - .ant - - .axml - - .builds - - .ccxml - - .clixml - - .cproject - - .csl - - .csproj - - .ct - - .dita - - .ditamap - - .ditaval - - .dll.config - - .dotsettings - - .filters - - .fsproj - - .fxml - - .glade - - .gml - - .grxml - - .iml - - .ivy - - .jelly - - .jsproj - - .kml - - .launch - - .mdpolicy - - .mm - - .mod - - .mxml - - .nproj - - .nuspec - - .odd - - .osm - - .pkgproj - - .plist - - .pluginspec - - .props - - .ps1xml - - .psc1 - - .pt - - .rdf - - .resx - - .rss - - .scxml - - .sfproj - - .srdf - - .storyboard - - .stTheme - - .sublime-snippet - - .targets - - .tmCommand - - .tml - - .tmLanguage - - .tmPreferences - - .tmSnippet - - .tmTheme - - .ts - - .tsx - - .ui - - .urdf - - .ux - - .vbproj - - .vcxproj - - .vssettings - - .vxml - - .wsdl - - .wsf - - .wxi - - .wxl - - .wxs - - .x3d - - .xacro - - .xaml - - .xib - - .xlf - - .xliff - - .xmi - - .xml.dist - - .xproj - - .xsd - - .xul - - .zcml + - ".xml" + - ".ant" + - ".axml" + - ".builds" + - ".ccxml" + - ".clixml" + - ".cproject" + - ".csl" + - ".csproj" + - ".ct" + - ".dita" + - ".ditamap" + - ".ditaval" + - ".dll.config" + - ".dotsettings" + - ".filters" + - ".fsproj" + - ".fxml" + - ".glade" + - ".gml" + - ".grxml" + - ".iml" + - ".ivy" + - ".jelly" + - ".jsproj" + - ".kml" + - ".launch" + - ".mdpolicy" + - ".mm" + - ".mod" + - ".mxml" + - ".nproj" + - ".nuspec" + - ".odd" + - ".osm" + - ".pkgproj" + - ".plist" + - ".pluginspec" + - ".props" + - ".ps1xml" + - ".psc1" + - ".pt" + - ".rdf" + - ".resx" + - ".rss" + - ".sch" + - ".scxml" + - ".sfproj" + - ".srdf" + - ".storyboard" + - ".stTheme" + - ".sublime-snippet" + - ".targets" + - ".tmCommand" + - ".tml" + - ".tmLanguage" + - ".tmPreferences" + - ".tmSnippet" + - ".tmTheme" + - ".ts" + - ".tsx" + - ".ui" + - ".urdf" + - ".ux" + - ".vbproj" + - ".vcxproj" + - ".vssettings" + - ".vxml" + - ".wsdl" + - ".wsf" + - ".wxi" + - ".wxl" + - ".wxs" + - ".x3d" + - ".xacro" + - ".xaml" + - ".xib" + - ".xlf" + - ".xliff" + - ".xmi" + - ".xml.dist" + - ".xproj" + - ".xsd" + - ".xul" + - ".zcml" filenames: - - .classpath - - .project + - ".classpath" + - ".project" - App.config - NuGet.config - Settings.StyleCop @@ -4133,178 +4206,178 @@ XML: - Web.Release.config - Web.config - packages.config - + language_id: 399 XPages: type: programming extensions: - - .xsp-config - - .xsp.metadata + - ".xsp-config" + - ".xsp.metadata" tm_scope: none ace_mode: xml - + language_id: 400 XProc: type: programming extensions: - - .xpl - - .xproc + - ".xpl" + - ".xproc" tm_scope: text.xml ace_mode: xml - + language_id: 401 XQuery: type: programming color: "#5232e7" extensions: - - .xquery - - .xq - - .xql - - .xqm - - .xqy + - ".xquery" + - ".xq" + - ".xql" + - ".xqm" + - ".xqy" ace_mode: xquery tm_scope: source.xq - + language_id: 402 XS: type: programming extensions: - - .xs + - ".xs" tm_scope: source.c ace_mode: c_cpp - + language_id: 403 XSLT: type: programming aliases: - xsl extensions: - - .xslt - - .xsl + - ".xslt" + - ".xsl" tm_scope: text.xml.xsl ace_mode: xml color: "#EB8CEB" - + language_id: 404 Xojo: type: programming extensions: - - .xojo_code - - .xojo_menu - - .xojo_report - - .xojo_script - - .xojo_toolbar - - .xojo_window + - ".xojo_code" + - ".xojo_menu" + - ".xojo_report" + - ".xojo_script" + - ".xojo_toolbar" + - ".xojo_window" tm_scope: source.vbnet ace_mode: text - + language_id: 405 Xtend: type: programming extensions: - - .xtend + - ".xtend" ace_mode: text - + language_id: 406 YAML: type: data tm_scope: source.yaml aliases: - yml extensions: - - .yml - - .reek - - .rviz - - .sublime-syntax - - .syntax - - .yaml - - .yaml-tmlanguage + - ".yml" + - ".reek" + - ".rviz" + - ".sublime-syntax" + - ".syntax" + - ".yaml" + - ".yaml-tmlanguage" filenames: - - .clang-format + - ".clang-format" ace_mode: yaml - + language_id: 407 YANG: type: data extensions: - - .yang + - ".yang" tm_scope: source.yang ace_mode: text - + language_id: 408 Yacc: type: programming extensions: - - .y - - .yacc - - .yy + - ".y" + - ".yacc" + - ".yy" tm_scope: source.bison ace_mode: text color: "#4B6C4B" - + language_id: 409 Zephir: type: programming color: "#118f9e" extensions: - - .zep + - ".zep" tm_scope: source.php.zephir ace_mode: php - + language_id: 410 Zimpl: type: programming extensions: - - .zimpl - - .zmpl - - .zpl + - ".zimpl" + - ".zmpl" + - ".zpl" tm_scope: none ace_mode: text - + language_id: 411 desktop: type: data extensions: - - .desktop - - .desktop.in + - ".desktop" + - ".desktop.in" tm_scope: source.desktop ace_mode: text - + language_id: 412 eC: type: programming color: "#913960" search_term: ec extensions: - - .ec - - .eh + - ".ec" + - ".eh" tm_scope: source.c.ec ace_mode: text - + language_id: 413 edn: type: data ace_mode: clojure extensions: - - .edn + - ".edn" tm_scope: source.clojure - + language_id: 414 fish: type: programming group: Shell interpreters: - fish extensions: - - .fish + - ".fish" tm_scope: source.fish ace_mode: text - + language_id: 415 mupad: type: programming extensions: - - .mu + - ".mu" ace_mode: text - + language_id: 416 nesC: type: programming color: "#94B0C7" extensions: - - .nc + - ".nc" ace_mode: text tm_scope: source.nesc - + language_id: 417 ooc: type: programming color: "#b0b77e" extensions: - - .ooc + - ".ooc" ace_mode: text - + language_id: 418 reStructuredText: type: prose wrap: true @@ -4312,20 +4385,20 @@ reStructuredText: aliases: - rst extensions: - - .rst - - .rest - - .rest.txt - - .rst.txt + - ".rst" + - ".rest" + - ".rest.txt" + - ".rst.txt" ace_mode: text - + language_id: 419 wisp: type: programming ace_mode: clojure color: "#7582D1" extensions: - - .wisp + - ".wisp" tm_scope: source.clojure - + language_id: 420 xBase: type: programming color: "#403a40" @@ -4334,8 +4407,9 @@ xBase: - clipper - foxpro extensions: - - .prg - - .ch - - .prw + - ".prg" + - ".ch" + - ".prw" tm_scope: source.harbour ace_mode: text + language_id: 421 diff --git a/lib/linguist/version.rb b/lib/linguist/version.rb index 66c161a0..1fbf952c 100644 --- a/lib/linguist/version.rb +++ b/lib/linguist/version.rb @@ -1,3 +1,3 @@ module Linguist - VERSION = "4.8.8" + VERSION = "4.8.12" end diff --git a/samples/1C Enterprise/Catalog.ИсходящиеПисьма.Form.ФормаЭлемента.Form.Module.bsl b/samples/1C Enterprise/Catalog.ИсходящиеПисьма.Form.ФормаЭлемента.Form.Module.bsl new file mode 100644 index 00000000..e59d89b9 --- /dev/null +++ b/samples/1C Enterprise/Catalog.ИсходящиеПисьма.Form.ФормаЭлемента.Form.Module.bsl @@ -0,0 +1,265 @@ +&НаСервереБезКонтекста +Функция ПолучитьКонтактноеЛицоПоЭлектроннойПочте(ЭлектроннаяПочта) + Запрос = Новый Запрос; + Запрос.Текст = "ВЫБРАТЬ КонтактноеЛицо ИЗ Справочник.Контрагенты ГДЕ ЭлектроннаяПочта = &ЭлектроннаяПочта"; + Запрос.Параметры.Вставить("ЭлектроннаяПочта", СокрЛП(ЭлектроннаяПочта)); + Выборка = Запрос.Выполнить().Выбрать(); + КонтактноеЛицо = ""; + Если Выборка.Следующий() Тогда + КонтактноеЛицо = Выборка.КонтактноеЛицо; + КонецЕсли; + Возврат КонтактноеЛицо; +КонецФункции + +&НаСервереБезКонтекста +Функция ПолучитьКонтактноеЛицоПоПолучателю(Получатель) + Запрос = Новый Запрос; + Запрос.Текст = "ВЫБРАТЬ КонтактноеЛицо ИЗ Справочник.Контрагенты ГДЕ Ссылка = &Получатель"; + Запрос.Параметры.Вставить("Получатель", Получатель); + Выборка = Запрос.Выполнить().Выбрать(); + КонтактноеЛицо = ""; + Если Выборка.Следующий() Тогда + КонтактноеЛицо = Выборка.КонтактноеЛицо; + КонецЕсли; + Возврат КонтактноеЛицо; +КонецФункции + +&НаСервереБезКонтекста +Процедура ДобавитьПолучателей(Получатель, Получатели) + Запрос = Новый Запрос; + Запрос.Текст = "ВЫБРАТЬ ЭлектроннаяПочта ИЗ Справочник.Контрагенты ГДЕ Ссылка "; + Если ТипЗнч(Получатели) = Тип("Массив") Тогда + Запрос.Текст = Запрос.Текст + "В (&Получатели)"; + Иначе + Запрос.Текст = Запрос.Текст + "= &Получатели"; + КонецЕсли; + Запрос.Параметры.Вставить("Получатели", Получатели); + Выборка = Запрос.Выполнить().Выбрать(); + Пока Выборка.Следующий() Цикл + Если Получатель <> "" Тогда + Получатель = Получатель + "; "; + КонецЕсли; + Получатель = Получатель + Выборка.ЭлектроннаяПочта; + КонецЦикла; +КонецПроцедуры + +&НаСервере +Процедура ПриСозданииНаСервере(Отказ, СтандартнаяОбработка) + Если Параметры.Ключ.Пустая() Тогда + Заголовок = "Исходящее письмо (Создание)"; + Объект.Дата = ТекущаяДата(); + ПоШаблону = Параметры.Свойство("ПоШаблону"); + ВходящееПисьмо = Параметры.ВходящееПисьмо; + Если ПоШаблону = Истина Тогда + Элементы.ЗаполнитьПоШаблону.Видимость = Истина; + РаботаСПочтой.ЗаполнитьПисьмоПоШаблону(Объект, Содержимое); + ИначеЕсли Не ВходящееПисьмо.Пустая() Тогда + РаботаСПочтой.ЗаполнитьОтветНаПисьмо(ВходящееПисьмо, Объект, Содержимое); + КонецЕсли; + Адресаты = Параметры.Адресаты; + Если Адресаты <> Неопределено Тогда + Запрос = Новый Запрос; + Запрос.Текст = "ВЫБРАТЬ + | Контрагенты.ЭлектроннаяПочта + |ИЗ + | Справочник.Контрагенты КАК Контрагенты + |ГДЕ + | Контрагенты.Ссылка В(&Адресаты) + | И Контрагенты.ЭлектроннаяПочта <> """""; + Запрос.УстановитьПараметр("Адресаты", Адресаты); + Получатель = ""; + Выборка = Запрос.Выполнить().Выбрать(); + Пока Выборка.Следующий() Цикл + Если Получатель <> "" Тогда + Получатель = Получатель + "; "; + КонецЕсли; + Получатель = Получатель + Выборка.ЭлектроннаяПочта; + КонецЦикла; + Объект.Получатель = Получатель; + КонецЕсли; + КонецЕсли; +КонецПроцедуры + +&НаСервере +Процедура ПриЧтенииНаСервере(ТекущийОбъект) + Содержимое = ТекущийОбъект.Содержимое.Получить(); + Заголовок = ТекущийОбъект.Наименование + " (Исходящее письмо)"; + Если РаботаСПочтой.ПисьмоОтправлено(ТекущийОбъект.Ссылка) Тогда + Заголовок = Заголовок + " - Отправлено"; + КонецЕсли; +КонецПроцедуры + +&НаСервере +Процедура ПередЗаписьюНаСервере(Отказ, ТекущийОбъект, ПараметрыЗаписи) + ТекущийОбъект.Содержимое = Новый ХранилищеЗначения(Содержимое, Новый СжатиеДанных()); + ТекущийОбъект.Текст = Содержимое.ПолучитьТекст(); +КонецПроцедуры + +&НаСервере +Функция ОтправитьПисьмо(Ошибка) + Если Не Записать() Тогда + Ошибка = "ОшибкаЗаписи"; + Возврат Ложь; + КонецЕсли; + Если Не РаботаСПочтой.ОтправитьПисьмо(Объект.Ссылка) Тогда + Ошибка = "ОшибкаОтправки"; + Возврат Ложь; + КонецЕсли; + Заголовок = Заголовок + " - Отправлено"; + Возврат Истина; +КонецФункции + +&НаКлиенте +Функция ОтправитьПисьмоКлиент() + Ошибка = ""; + Если Не ОтправитьПисьмо(Ошибка) Тогда + Если Ошибка = "ОшибкаОтправки" Тогда + Кнопки = Новый СписокЗначений; + Кнопки.Добавить(1, "Настроить почту"); + Кнопки.Добавить(2, "Закрыть"); + + Оп = Новый ОписаниеОповещения( + "ОтправитьПисьмоКлиентВопросЗавершение", + ЭтотОбъект); + ПоказатьВопрос(Оп, + "Не указаны настройки интернет почты!", + Кнопки, , 1); + КонецЕсли; + Возврат Ложь; + КонецЕсли; + + НавигационнаяСсылка = ПолучитьНавигационнуюСсылку(Объект.Ссылка); + ПоказатьОповещениеПользователя("Письмо отправлено", НавигационнаяСсылка, Объект.Наименование); + ОповеститьОбИзменении(Объект.Ссылка); + Возврат Истина; +КонецФункции + +&НаКлиенте +Процедура ОтправитьПисьмоКлиентВопросЗавершение(Результат, Параметры) Экспорт + Если Результат = 1 Тогда + ОткрытьФорму("ОбщаяФорма.НастройкаПочты"); + КонецЕсли; +КонецПроцедуры + +&НаКлиенте +Процедура Отправить(Команда) + ОтправитьПисьмоКлиент(); +КонецПроцедуры + +&НаКлиенте +Процедура ОтправитьИЗакрыть(Команда) + Если Не ОтправитьПисьмоКлиент() Тогда + Возврат; + КонецЕсли; + Закрыть(); +КонецПроцедуры + +&НаКлиенте +Процедура ВставитьСтрокуВТекущуюПозицию(Поле, Документ, Строка) + Перем Начало, Конец; + Поле.ПолучитьГраницыВыделения(Начало, Конец); + Позиция = Документ.ПолучитьПозициюПоЗакладке(Начало); + Документ.Удалить(Начало, Конец); + Начало = Документ.ПолучитьЗакладкуПоПозиции(Позиция); + Документ.Вставить(Начало, Строка); + Позиция = Позиция + СтрДлина(Строка); + Закладка = Документ.ПолучитьЗакладкуПоПозиции(Позиция); + Поле.УстановитьГраницыВыделения(Закладка, Закладка); +КонецПроцедуры + +&НаКлиенте +Процедура ВставитьКонтактноеЛицо(Команда) + Если Объект.Контрагент.Пустая() Тогда + Сообщить("Выберите контрагента"); + Иначе + КонтактноеЛицо = ПолучитьКонтактноеЛицоПоПолучателю(Объект.Контрагент); + ВставитьСтрокуВТекущуюПозицию(Элементы.Содержимое, Содержимое, КонтактноеЛицо + " "); + КонецЕсли; +КонецПроцедуры + +&НаСервере +Процедура ПослеЗаписиНаСервере(ТекущийОбъект, ПараметрыЗаписи) + Заголовок = ТекущийОбъект.Наименование + " (Исходящее письмо)"; +КонецПроцедуры + +&НаКлиенте +Процедура КонтрагентПриИзменении(Элемент) + ДобавитьПолучателей(Объект.Получатель, Объект.Контрагент); +КонецПроцедуры + +&НаКлиенте +Процедура ВыделитьВажное(Команда) + Перем Начало, Конец; + ВсеВажное = Истина; + Элементы.Содержимое.ПолучитьГраницыВыделения(Начало, Конец); + Если Начало = Конец Тогда + Возврат; + КонецЕсли; + + НаборТекстовыхЭлементов = Новый Массив(); + Для Каждого ТекстовыйЭлемент Из Содержимое.СформироватьЭлементы(Начало, Конец) Цикл + Если Тип(ТекстовыйЭлемент) = Тип("ТекстФорматированногоДокумента") Тогда + НаборТекстовыхЭлементов.Добавить(ТекстовыйЭлемент); + КонецЕсли; + КонецЦикла; + + Для Каждого ТекстовыйЭлемент Из НаборТекстовыхЭлементов Цикл + Если ТекстовыйЭлемент.Шрифт.Жирный <> Истина И + ТекстовыйЭлемент.ЦветТекста <> Новый Цвет(255, 0, 0) Тогда + ВсеВажное = Ложь; + Прервать; + КонецЕсли; + КонецЦикла; + + Для Каждого ТекстовыйЭлемент Из НаборТекстовыхЭлементов Цикл + ТекстовыйЭлемент.Шрифт = Новый Шрифт(ТекстовыйЭлемент.Шрифт, , , Не ВсеВажное); + ТекстовыйЭлемент.ЦветТекста = Новый Цвет(?(ВсеВажное, 0, 255), 0, 0); + КонецЦикла; +КонецПроцедуры + +&НаКлиенте +Процедура ЗаполнитьПоШаблону(Команда) + Если Объект.Контрагент.Пустая() Тогда + Сообщить("Выберите контрагента"); + Иначе + НайтиИЗаменить("[Контрагент]", Объект.Контрагент); + НайтиИЗаменить("[КонтактноеЛицо]", ПолучитьКонтактноеЛицоПоПолучателю(Объект.Контрагент)); + КонецЕсли; + НайтиИЗаменить("[ДатаПисьма]", Объект.Дата); +КонецПроцедуры + +&НаКлиенте +Процедура НайтиИЗаменить(СтрокаДляПоиска, СтрокаДляЗамены) + Перем ВставленныйТекст, ШрифтОформления, ЦветТекстаОформления, ЦветФонаОформления, НавигационнаяСсылкаОформления; + РезультатПоиска = Содержимое.НайтиТекст(СтрокаДляПоиска); + Пока ((РезультатПоиска <> Неопределено) И (РезультатПоиска.ЗакладкаНачала <> Неопределено) И (РезультатПоиска.ЗакладкаКонца <> Неопределено)) Цикл + ПозицияНачалаСледующегоЦиклаПоиска = Содержимое.ПолучитьПозициюПоЗакладке(РезультатПоиска.ЗакладкаНачала) + СтрДлина(СтрокаДляЗамены); + МассивЭлементовДляОформления = Содержимое.ПолучитьЭлементы(РезультатПоиска.ЗакладкаНачала, РезультатПоиска.ЗакладкаКонца); + Для Каждого ЭлементДляОформления Из МассивЭлементовДляОформления Цикл + Если Тип(ЭлементДляОформления) = Тип("ТекстФорматированногоДокумента") Тогда + ШрифтОформления = ЭлементДляОформления.Шрифт; + ЦветТекстаОформления = ЭлементДляОформления.ЦветТекста; + ЦветФонаОформления = ЭлементДляОформления.ЦветФона; + НавигационнаяСсылкаОформления = ЭлементДляОформления.НавигационнаяССылка; + Прервать; + КонецЕсли; + КонецЦикла; + Содержимое.Удалить(РезультатПоиска.ЗакладкаНачала, РезультатПоиска.ЗакладкаКонца); + ВставленныйТекст = Содержимое.Вставить(РезультатПоиска.ЗакладкаНачала, СтрокаДляЗамены); + Если ВставленныйТекст <> Неопределено И ШрифтОформления <> Неопределено Тогда + ВставленныйТекст.Шрифт = ШрифтОформления; + КонецЕсли; + Если ВставленныйТекст <> Неопределено И ЦветТекстаОформления <> Неопределено Тогда + ВставленныйТекст.ЦветТекста = ЦветТекстаОформления; + КонецЕсли; + Если ВставленныйТекст <> Неопределено И ЦветФонаОформления <> Неопределено Тогда + ВставленныйТекст.ЦветФона = ЦветФонаОформления; + КонецЕсли; + Если ВставленныйТекст <> Неопределено И НавигационнаяСсылкаОформления <> Неопределено Тогда + ВставленныйТекст.НавигационнаяССылка = НавигационнаяСсылкаОформления; + КонецЕсли; + + РезультатПоиска = Содержимое.НайтиТекст(СтрокаДляПоиска, Содержимое.ПолучитьЗакладкуПоПозиции(ПозицияНачалаСледующегоЦиклаПоиска)); + КонецЦикла; +КонецПроцедуры + diff --git a/samples/1C Enterprise/Catalog.Товары.Command.ПечатьПрайсЛиста.CommandModule.bsl b/samples/1C Enterprise/Catalog.Товары.Command.ПечатьПрайсЛиста.CommandModule.bsl new file mode 100644 index 00000000..f96e8811 --- /dev/null +++ b/samples/1C Enterprise/Catalog.Товары.Command.ПечатьПрайсЛиста.CommandModule.bsl @@ -0,0 +1,85 @@ +&НаСервере +Функция ПечатнаяФорма(ПараметрКоманды) + ТабличныйДокумент = Новый ТабличныйДокумент; + ТабличныйДокумент.ОтображатьСетку = Истина; + ТабличныйДокумент.ОтображатьЗаголовки = Истина; + + Сформирован = Ложь; + ТабМакет = Справочники.Товары.ПолучитьМакет("МакетПрайсЛиста"); + + Шапка = ТабМакет.ПолучитьОбласть("Шапка"); + ТабличныйДокумент.Вывести(Шапка); + + ОбластьНоменклатура = ТабМакет.ПолучитьОбласть("ОбластьНоменклатура"); + + Запрос = Новый Запрос; + Запрос.Текст = "ВЫБРАТЬ + | Товары.Код КАК Код, + | Товары.Наименование КАК Наименование, + | Товары.Артикул КАК Артикул, + | Товары.ФайлКартинки КАК Картинка, + | Товары.Описание КАК Описание, + | Товары.Вид КАК Вид, + | ЦеныТоваров.Цена КАК Цена + |ИЗ + | РегистрСведений.ЦеныТоваров КАК ЦеныТоваров + | ЛЕВОЕ СОЕДИНЕНИЕ Справочник.Товары КАК Товары + | ПО ЦеныТоваров.Товар = Товары.Ссылка + |ГДЕ + | Товары.ЭтоГруппа = ЛОЖЬ + | И ЦеныТоваров.ВидЦен = &ВидЦен + | + |УПОРЯДОЧИТЬ ПО + | Вид, + | Товары.Родитель.Код, + | Код"; + + Запрос.УстановитьПараметр("ВидЦен", Справочники.ВидыЦен.НайтиПоНаименованию("Розничная")); + + Выборка = Запрос.Выполнить().Выбрать(); + Пока Выборка.Следующий() Цикл + ОбластьНоменклатура.Параметры.Заполнить(Выборка); + + Описание = ""; + + Чтение = Новый ЧтениеHTML(); + Чтение.УстановитьСтроку(Выборка.Описание); + + ДокDOM = Новый ПостроительDOM(); + HTML = ДокDOM.Прочитать(Чтение); + + Если Не HTML.ЭлементДокумента = Неопределено Тогда + Для Каждого Узел из HTML.ЭлементДокумента.ДочерниеУзлы Цикл + Если Узел.ИмяУзла = "body" Тогда + Для Каждого ЭлементОписания из Узел.ДочерниеУзлы Цикл + Описание = Описание + ЭлементОписания.ТекстовоеСодержимое; + КонецЦикла; + КонецЕсли; + КонецЦикла; + КонецЕсли; + ОбластьНоменклатура.Параметры.Описание = Описание; + + Если (Выборка.Картинка <> Null) Тогда + ОбластьНоменклатура.Параметры.ПараметрКартинки = Новый Картинка(Выборка.Картинка.ДанныеФайла.Получить()); + КонецЕсли; + + ТабличныйДокумент.Вывести(ОбластьНоменклатура, Выборка.Уровень()); + Сформирован = Истина; + КонецЦикла; + + Если Сформирован Тогда + Возврат ТабличныйДокумент; + Иначе + Возврат Неопределено; + КонецЕсли; +КонецФункции + +&НаКлиенте +Процедура ОбработкаКоманды(ПараметрКоманды, ПараметрыВыполненияКоманды) + ТабличныйДокумент = ПечатнаяФорма(ПараметрКоманды); + + Если ТабличныйДокумент <> Неопределено Тогда + ТабличныйДокумент.Показать(); + КонецЕсли; + +КонецПроцедуры diff --git a/samples/1C Enterprise/CommonModule.ОбменМобильныеОбщее.Module.bsl b/samples/1C Enterprise/CommonModule.ОбменМобильныеОбщее.Module.bsl new file mode 100644 index 00000000..d5a1a2cb --- /dev/null +++ b/samples/1C Enterprise/CommonModule.ОбменМобильныеОбщее.Module.bsl @@ -0,0 +1,109 @@ +// Процедура на основании анализа типа данных заменяет их на данные, удаляющие +// информацию из узла в котором их не должно быть +// +// Параметры: +// Данные – Объект, набор записей,... который нужно преобразовать +// +Процедура УдалениеДанных(Данные) + + // Получаем объект описания метаданного, соответствующий данным + ОбъектМетаданных = ?(ТипЗнч(Данные) = Тип("УдалениеОбъекта"), Данные.Ссылка.Метаданные(), Данные.Метаданные()); + // Проверяем тип, интересуют только те типы, которые реализованы на мобильной платформе + Если Метаданные.Справочники.Содержит(ОбъектМетаданных) + ИЛИ Метаданные.Документы.Содержит(ОбъектМетаданных) Тогда + + // Перенос удаления объекта для объектных + Данные = Новый УдалениеОбъекта(Данные.Ссылка); + + ИначеЕсли Метаданные.РегистрыСведений.Содержит(ОбъектМетаданных) + ИЛИ Метаданные.РегистрыНакопления.Содержит(ОбъектМетаданных) + ИЛИ Метаданные.Последовательности.Содержит(ОбъектМетаданных) Тогда + + // Очищаем данные + Данные.Очистить(); + + КонецЕсли; + +КонецПроцедуры + +// Функция формирует пакет обмена, который будет отправлен узлу "УзелОбмена" +// +// Параметры: +// УзелОбмена – узел плана обмена "мобильные", с которым осуществляется обмен +// +// Возвращаемое значение: +// сформированный пакет, помещенный в хранилище значения +Функция СформироватьПакетОбмена(УзелОбмена) Экспорт + + ЗаписьXML = Новый ЗаписьXML; + + ЗаписьXML.УстановитьСтроку("UTF-8"); + ЗаписьXML.ЗаписатьОбъявлениеXML(); + + ЗаписьСообщения = ПланыОбмена.СоздатьЗаписьСообщения(); + ЗаписьСообщения.НачатьЗапись(ЗаписьXML, УзелОбмена); + + ЗаписьXML.ЗаписатьСоответствиеПространстваИмен("xsi", "http://www.w3.org/2001/XMLSchema-instance"); + ЗаписьXML.ЗаписатьСоответствиеПространстваИмен("v8", "http://v8.1c.ru/data"); + + ТипДанныхУдаления = Тип("УдалениеОбъекта"); + + ВыборкаИзменений = ПланыОбмена.ВыбратьИзменения(УзелОбмена, ЗаписьСообщения.НомерСообщения); + Пока ВыборкаИзменений.Следующий() Цикл + + Данные = ВыборкаИзменений.Получить(); + + // Если перенос данных не нужен, то, возможно, необходимо записать удаление данных + Если Не ОбменМобильныеПереопределяемый.НуженПереносДанных(Данные, УзелОбмена) Тогда + + // Получаем значение с возможным удалением данных + УдалениеДанных(Данные); + + КонецЕсли; + + // Записываем данные в сообщение + ОбменМобильныеПереопределяемый.ЗаписатьДанные(ЗаписьXML, Данные); + + КонецЦикла; + + ЗаписьСообщения.ЗакончитьЗапись(); + + Возврат Новый ХранилищеЗначения(ЗаписьXML.Закрыть(), Новый СжатиеДанных(9)); + +КонецФункции + +// Процедура вносит в информационную базу данные, которые присланы из узла "УзелОбмена" +// +// Параметры: +// УзелОбмена – узел плана обмена "мобильные", с которым осуществляется обмен +// ДанныеОбмена - пакет обмена полученный из узла УзелОбмена, помещен в ХранилищеЗначения +// +Процедура ПринятьПакетОбмена(УзелОбмена, ДанныеОбмена) Экспорт + + ЧтениеXML = Новый ЧтениеXML; + ЧтениеXML.УстановитьСтроку(ДанныеОбмена.Получить()); + ЧтениеСообщения = ПланыОбмена.СоздатьЧтениеСообщения(); + ЧтениеСообщения.НачатьЧтение(ЧтениеXML); + ПланыОбмена.УдалитьРегистрациюИзменений(ЧтениеСообщения.Отправитель,ЧтениеСообщения.НомерПринятого); + + НачатьТранзакцию(); + Пока ВозможностьЧтенияXML(ЧтениеXML) Цикл + + Данные = ОбменМобильныеПереопределяемый.ПрочитатьДанные(ЧтениеXML); + + Если Не Данные = Неопределено Тогда + + Данные.ОбменДанными.Отправитель = ЧтениеСообщения.Отправитель; + Данные.ОбменДанными.Загрузка = Истина; + + Данные.Записать(); + + КонецЕсли; + + КонецЦикла; + ЗафиксироватьТранзакцию(); + + ЧтениеСообщения.ЗакончитьЧтение(); + ЧтениеXML.Закрыть(); + +КонецПроцедуры diff --git a/samples/1C Enterprise/Document.РасходТовара.ObjectModule.bsl b/samples/1C Enterprise/Document.РасходТовара.ObjectModule.bsl new file mode 100644 index 00000000..1edbfb08 --- /dev/null +++ b/samples/1C Enterprise/Document.РасходТовара.ObjectModule.bsl @@ -0,0 +1,302 @@ +//////////////////////////////////////////////////////////////////////////////// +// ПРОЦЕДУРЫ И ФУНКЦИИ +// + +// Формирование печатной формы документа +// +// Параметры: +// Нет. +// +// Возвращаемое значение: +// ТабличныйДокумент - Сформированный табличный документ. +Процедура ПечатнаяФорма(ТабличныйДокумент) Экспорт + + Макет = Документы.РасходТовара.ПолучитьМакет("МакетПечати"); + + // Заголовок + Область = Макет.ПолучитьОбласть("Заголовок"); + ТабличныйДокумент.Вывести(Область); + + // Шапка + Шапка = Макет.ПолучитьОбласть("Шапка"); + Шапка.Параметры.Заполнить(ЭтотОбъект); + ТабличныйДокумент.Вывести(Шапка); + + // Товары + Область = Макет.ПолучитьОбласть("ТоварыШапка"); + ТабличныйДокумент.Вывести(Область); + ОбластьТовары = Макет.ПолучитьОбласть("Товары"); + + Для каждого ТекСтрокаТовары Из Товары Цикл + + ОбластьТовары.Параметры.Заполнить(ТекСтрокаТовары); + ТабличныйДокумент.Вывести(ОбластьТовары); + + КонецЦикла; + +КонецПроцедуры + +// Формирование печатной формы документа +// +// Параметры: +// Нет. +// +// Возвращаемое значение: +// ТабличныйДокумент - Сформированный табличный документ. +Процедура Пересчитать() Экспорт + + Для каждого ТекСтрокаТовары Из Товары Цикл + + ТекСтрокаТовары.Сумма = ТекСтрокаТовары.Количество * ТекСтрокаТовары.Цена; + + КонецЦикла; + +КонецПроцедуры + +//////////////////////////////////////////////////////////////////////////////// +// ОБРАБОТЧИКИ СОБЫТИЙ ОБЪЕКТА + +Процедура ОбработкаПроведения(Отказ, Режим) + + // Формирование движений регистров накопления ТоварныеЗапасы и Продажи. + Движения.ТоварныеЗапасы.Записывать = Истина; + Движения.Продажи.Записывать = Истина; + Если Режим = РежимПроведенияДокумента.Оперативный Тогда + Движения.ТоварныеЗапасы.БлокироватьДляИзменения = Истина; + КонецЕсли; + + // Создадим запрос, чтобы получать информацию об услугах + Запрос = Новый Запрос("ВЫБРАТЬ + | ТоварыВДокументе.НомерСтроки КАК НомерСтроки + |ИЗ + | Документ.РасходТовара.Товары КАК ТоварыВДокументе + |ГДЕ + | ТоварыВДокументе.Ссылка = &Ссылка + | И ТоварыВДокументе.Товар.Вид = ЗНАЧЕНИЕ(Перечисление.ВидыТоваров.Услуга)"); + + Запрос.УстановитьПараметр("Ссылка", Ссылка); + РезультатУслуги = Запрос.Выполнить().Выгрузить(); + РезультатУслуги.Индексы.Добавить("НомерСтроки"); + + Для каждого ТекСтрокаТовары Из Товары Цикл + + Строка = РезультатУслуги.Найти(ТекСтрокаТовары.НомерСтроки, "НомерСтроки"); + Если Строка = Неопределено Тогда + + // Не услуга + Движение = Движения.ТоварныеЗапасы.Добавить(); + Движение.ВидДвижения = ВидДвиженияНакопления.Расход; + Движение.Период = Дата; + Движение.Товар = ТекСтрокаТовары.Товар; + Движение.Склад = Склад; + Движение.Количество = ТекСтрокаТовары.Количество; + + КонецЕсли; + + Движение = Движения.Продажи.Добавить(); + Движение.Период = Дата; + Движение.Товар = ТекСтрокаТовары.Товар; + Движение.Покупатель = Покупатель; + Движение.Количество = ТекСтрокаТовары.Количество; + Движение.Сумма = ТекСтрокаТовары.Сумма; + + КонецЦикла; + + // Формирование движения регистра накопления Взаиморасчеты. + Движения.Взаиморасчеты.Записывать = Истина; + Движение = Движения.Взаиморасчеты.Добавить(); + Движение.ВидДвижения = ВидДвиженияНакопления.Расход; + Движение.Период = Дата; + Движение.Контрагент = Покупатель; + Движение.Валюта = Валюта; + + Если Валюта.Пустая() Тогда + Движение.Сумма = Товары.Итог("Сумма"); + Иначе + + Курс = РегистрыСведений.КурсыВалют.ПолучитьПоследнее(Дата, Новый Структура("Валюта", Валюта)).Курс; + + Если Курс = 0 Тогда + Движение.Сумма = Товары.Итог("Сумма"); + Иначе + Движение.Сумма = Товары.Итог("Сумма") / Курс; + КонецЕсли; + + КонецЕсли; + + //Запишем движения + Движения.Записать(); + + //Контроль остатков при оперативном проведении + Если Режим = РежимПроведенияДокумента.Оперативный Тогда + // Создадим запрос, чтобы контролировать остатки по товарам + Запрос = Новый Запрос("ВЫБРАТЬ + | ТоварыВДокументе.Товар КАК Товар, + | СУММА(ТоварыВДокументе.Количество) КАК Количество, + | МАКСИМУМ(ТоварыВДокументе.НомерСтроки) КАК НомерСтроки + | + |ПОМЕСТИТЬ ТребуетсяТовара + | + |ИЗ + | Документ.РасходТовара.Товары КАК ТоварыВДокументе + | + |ГДЕ + | ТоварыВДокументе.Ссылка = &Ссылка + | И ТоварыВДокументе.Товар.Вид = ЗНАЧЕНИЕ(Перечисление.ВидыТоваров.Товар) + | + |СГРУППИРОВАТЬ ПО + | ТоварыВДокументе.Товар + | + |ИНДЕКСИРОВАТЬ ПО + | Товар + |; + | + |//////////////////////////////////////////////////////////////////////////////// + |ВЫБРАТЬ + | ПРЕДСТАВЛЕНИЕ(ТребуетсяТовара.Товар) КАК ТоварПредставление, + | ВЫБОР + | КОГДА - ЕСТЬNULL(ТоварныеЗапасыОстатки.КоличествоОстаток, 0) > ТоварыВДокументе.Количество + | ТОГДА ТоварыВДокументе.Количество + | ИНАЧЕ - ЕСТЬNULL(ТоварныеЗапасыОстатки.КоличествоОстаток, 0) + | КОНЕЦ КАК Нехватка, + | ТоварыВДокументе.Количество - ВЫБОР + | КОГДА - ЕСТЬNULL(ТоварныеЗапасыОстатки.КоличествоОстаток, 0) > ТоварыВДокументе.Количество + | ТОГДА ТоварыВДокументе.Количество + | ИНАЧЕ - ЕСТЬNULL(ТоварныеЗапасыОстатки.КоличествоОстаток, 0) + | КОНЕЦ КАК МаксимальноеКоличество, + | ТребуетсяТовара.НомерСтроки КАК НомерСтроки + | + |ИЗ + | ТребуетсяТовара КАК ТребуетсяТовара + | ЛЕВОЕ СОЕДИНЕНИЕ РегистрНакопления.ТоварныеЗапасы.Остатки( + | , + | Товар В + | (ВЫБРАТЬ + | ТребуетсяТовара.Товар + | ИЗ + | ТребуетсяТовара) + | И Склад = &Склад) КАК ТоварныеЗапасыОстатки + | ПО ТребуетсяТовара.Товар = ТоварныеЗапасыОстатки.Товар + | ЛЕВОЕ СОЕДИНЕНИЕ Документ.РасходТовара.Товары КАК ТоварыВДокументе + | ПО ТребуетсяТовара.Товар = ТоварыВДокументе.Товар + | И ТребуетсяТовара.НомерСтроки = ТоварыВДокументе.НомерСтроки + | + |ГДЕ + | ТоварыВДокументе.Ссылка = &Ссылка И + | 0 > ЕСТЬNULL(ТоварныеЗапасыОстатки.КоличествоОстаток, 0) + | + |УПОРЯДОЧИТЬ ПО + | НомерСтроки"); + + Запрос.УстановитьПараметр("Склад", Склад); + Запрос.УстановитьПараметр("Ссылка", Ссылка); + РезультатСНехваткой = Запрос.Выполнить(); + + ВыборкаРезультатаСНехваткой = РезультатСНехваткой.Выбрать(); + + // Выдадим ошибки для строк, в которых не хватает остатка + Пока ВыборкаРезультатаСНехваткой.Следующий() Цикл + + Сообщение = Новый СообщениеПользователю(); + Сообщение.Текст = НСтр("ru = 'Не хватает '", "ru") + + ВыборкаРезультатаСНехваткой.Нехватка + + НСтр("ru = ' единиц товара'", "ru") + """" + + ВыборкаРезультатаСНехваткой.ТоварПредставление + + """" + + НСтр("ru = ' на складе'", "ru") + + """" + + Склад + + """." + + НСтр("ru = 'Максимальное количество: '", "ru") + + ВыборкаРезультатаСНехваткой.МаксимальноеКоличество + + "."; + Сообщение.Поле = НСтр("ru = 'Товары'", "ru") + + "[" + + (ВыборкаРезультатаСНехваткой.НомерСтроки - 1) + + "]." + + НСтр("ru = 'Количество'", "ru"); + Сообщение.УстановитьДанные(ЭтотОбъект); + Сообщение.Сообщить(); + Отказ = Истина; + + КонецЦикла; + + КонецЕсли; + +КонецПроцедуры + +Процедура ОбработкаПроверкиЗаполнения(Отказ, ПроверяемыеРеквизиты) + // Проверим заполненность поля "Покупатель" + Если Покупатель.Пустая() Тогда + + // Если поле Покупатель не заполнено, сообщим об этом пользователю + Сообщение = Новый СообщениеПользователю(); + Сообщение.Текст = НСтр("ru = 'Не указан Покупатель, для которого выписывается накладная!'", "ru"); + Сообщение.Поле = НСтр("ru = 'Покупатель'", "ru"); + Сообщение.УстановитьДанные(ЭтотОбъект); + + Сообщение.Сообщить(); + + // Сообщим платформе, что мы сами обработали проверку заполнения поля "Покупатель" + ПроверяемыеРеквизиты.Удалить(ПроверяемыеРеквизиты.Найти("Покупатель")); + // Так как информация в документе не консистентна, то продолжать работу дальше смысла нет + Отказ = Истина; + + КонецЕсли; + + //Если склад не заполнен, то проверим есть ли в документе что-то кроме услуг + Если Склад.Пустая() И Товары.Количество() > 0 Тогда + + // Создадим запрос, чтобы получать информацию об товарах + Запрос = Новый Запрос("ВЫБРАТЬ + | Количество(*) КАК Количество + |ИЗ + | Справочник.Товары КАК Товары + |ГДЕ + | Товары.Ссылка В (&ТоварыВДокументе) + | И Товары.Вид = ЗНАЧЕНИЕ(Перечисление.ВидыТоваров.Товар)"); + + Запрос.УстановитьПараметр("ТоварыВДокументе", Товары.ВыгрузитьКолонку("Товар")); + Выборка = Запрос.Выполнить().Выбрать(); + Выборка.Следующий(); + Если Выборка.Количество = 0 Тогда + // Сообщим платформе, что мы сами обработали проверку заполнения поля "Склад" + ПроверяемыеРеквизиты.Удалить(ПроверяемыеРеквизиты.Найти("Склад")); + КонецЕсли; + + КонецЕсли; + +КонецПроцедуры + +Процедура ОбработкаЗаполнения(ДанныеЗаполнения, СтандартнаяОбработка) + + Если ТипЗнч(ДанныеЗаполнения) = Тип("СправочникСсылка.Контрагенты") Тогда + + ЗапросПоКонтрагенту = Новый Запрос("ВЫБРАТЬ + | Контрагенты.ЭтоГруппа, + | Контрагенты.ВидЦен + |ИЗ + | Справочник.Контрагенты КАК Контрагенты + |ГДЕ + | Контрагенты.Ссылка = &КонтрагентСсылка"); + ЗапросПоКонтрагенту.УстановитьПараметр("КонтрагентСсылка", ДанныеЗаполнения); + Выборка = ЗапросПоКонтрагенту.Выполнить().Выбрать(); + Если Выборка.Следующий() И Выборка.ЭтоГруппа Тогда + Возврат; + КонецЕсли; + + ВидЦен = Выборка.ВидЦен; + Покупатель = ДанныеЗаполнения.Ссылка; + + ИначеЕсли ТипЗнч(ДанныеЗаполнения) = Тип("Структура") Тогда + + Значение = Неопределено; + + Если ДанныеЗаполнения.Свойство("Покупатель", Значение) Тогда + ВидЦен = Значение.ВидЦен; + КонецЕсли; + + КонецЕсли; + +КонецПроцедуры + diff --git a/samples/1C Enterprise/ci_before_script.os b/samples/1C Enterprise/ci_before_script.os new file mode 100644 index 00000000..baeaa475 --- /dev/null +++ b/samples/1C Enterprise/ci_before_script.os @@ -0,0 +1,20 @@ +Каталог = ОбъединитьПути(ТекущийКаталог(), "libs\oscript-library\src"); +Загрузчик_Оригинал_ИмяФайла = ОбъединитьПути(Каталог, "package-loader.os"); + +Файлы = НайтиФайлы(Каталог, , Ложь); +Для Каждого ВыбФайл Из Файлы Цикл + + Если ВыбФайл.ЭтоФайл() Тогда + Продолжить; + КонецЕсли; + + Загрузчик_ИмяФайла = ОбъединитьПути(ВыбФайл.ПолноеИмя, "package-loader.os"); + Загрузчик_Файл = Новый Файл(Загрузчик_ИмяФайла); + + Если Загрузчик_Файл.Существует() Тогда + Продолжить; + КонецЕсли; + + КопироватьФайл(Загрузчик_Оригинал_ИмяФайла, Загрузчик_ИмяФайла); + +КонецЦикла; \ No newline at end of file diff --git a/samples/1C Enterprise/test_canCompile.os b/samples/1C Enterprise/test_canCompile.os new file mode 100644 index 00000000..2e949785 --- /dev/null +++ b/samples/1C Enterprise/test_canCompile.os @@ -0,0 +1,42 @@ +#Использовать "../libs/oscript-library/src/v8runner" +#Использовать "../libs/oscript-library/src/tempfiles" + +Перем Лог; +Перем КодВозврата; + +Процедура Инициализация() + + Лог = Логирование.ПолучитьЛог("oscript.app.gitlab-test_CanCompile"); + КодВозврата = 0; + +КонецПроцедуры + +Процедура ВыполнитьТест() + + Конфигуратор = Новый УправлениеКонфигуратором(); + + ПараметрыЗапуска = Конфигуратор.ПолучитьПараметрыЗапуска(); + КомандаЗапуска = "/LoadConfigFromFiles ""%1"""; + КомандаЗапуска = СтрШаблон(КомандаЗапуска, ТекущийКаталог() + "\source\cf"); + + Лог.Информация("Команда обновления конфигурации: " + КомандаЗапуска); + + ПараметрыЗапуска.Добавить(КомандаЗапуска); + + Попытка + Конфигуратор.ВыполнитьКоманду(ПараметрыЗапуска); + Исключение + + Лог.Ошибка(Конфигуратор.ВыводКоманды()); + КодВозврата = 1; + + КонецПопытки; + + УдалитьФайлы(Конфигуратор.ПутьКВременнойБазе()); + +КонецПроцедуры + +Инициализация(); +ВыполнитьТест(); + +ЗавершитьРаботу(КодВозврата); \ No newline at end of file diff --git a/samples/ASN.1/example.asn b/samples/ASN.1/example.asn new file mode 100644 index 00000000..0631abc9 --- /dev/null +++ b/samples/ASN.1/example.asn @@ -0,0 +1,33 @@ +MyShopPurchaseOrders DEFINITIONS AUTOMATIC TAGS ::= BEGIN + +PurchaseOrder ::= SEQUENCE { +dateOfOrder DATE, +customer CustomerInfo, +items ListOfItems +} + +CustomerInfo ::= SEQUENCE { +companyName VisibleString (SIZE (3..50)), +billingAddress Address, +contactPhone NumericString (SIZE (7..12)) +} + +Address::= SEQUENCE { +street VisibleString (SIZE (5 .. 50)) OPTIONAL, +city VisibleString (SIZE (2..30)), +state VisibleString (SIZE(2) ^ FROM ("A".."Z")), +zipCode NumericString (SIZE(5 | 9)) +} + +ListOfItems ::= SEQUENCE (SIZE (1..100)) OF Item + +Item ::= SEQUENCE { +itemCode INTEGER (1..99999), +color VisibleString ("Black" | "Blue" | "Brown"), +power INTEGER (110 | 220), +deliveryTime INTEGER (8..12 | 14..19), +quantity INTEGER (1..1000), +unitPrice REAL (1.00 .. 9999.00), +isTaxable BOOLEAN +} +END diff --git a/samples/DTrace/javascript-trace.d b/samples/DTrace/javascript-trace.d deleted file mode 100644 index 0acbaa97..00000000 --- a/samples/DTrace/javascript-trace.d +++ /dev/null @@ -1,73 +0,0 @@ -/* -*- Mode: dtrace-script; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ -/* ***** BEGIN LICENSE BLOCK ***** - * Version: MPL 1.1/GPL 2.0/LGPL 2.1 - * - * The contents of this file are subject to the Mozilla Public License Version - * 1.1 (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * http://www.mozilla.org/MPL/ - * - * Software distributed under the License is distributed on an "AS IS" basis, - * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License - * for the specific language governing rights and limitations under the - * License. - * - * Copyright (C) 2007 Sun Microsystems, Inc. All Rights Reserved. - * - * Alternatively, the contents of this file may be used under the terms of - * either the GNU General Public License Version 2 or later (the "GPL"), or - * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), - * in which case the provisions of the GPL or the LGPL are applicable instead - * of those above. If you wish to allow use of your version of this file only - * under the terms of either the GPL or the LGPL, and not to allow others to - * use your version of this file under the terms of the MPL, indicate your - * decision by deleting the provisions above and replace them with the notice - * and other provisions required by the GPL or the LGPL. If you do not delete - * the provisions above, a recipient may use your version of this file under - * the terms of any one of the MPL, the GPL or the LGPL. - * - * ***** END LICENSE BLOCK ***** */ - -/* - * javascript provider probes - * - * function-entry (filename, classname, funcname) - * function-info (filename, classname, funcname, lineno, - * runfilename, runlineno) - * function-args (filename, classname, funcname, argc, argv, argv0, - * argv1, argv2, argv3, argv4) - * function-rval (filename, classname, funcname, lineno, rval, rval0) - * function-return (filename, classname, funcname) - * object-create-start (filename, classname) - * object-create (filename, classname, *object, rlineno) - * object-create-done (filename, classname) - * object-finalize (NULL, classname, *object) - * execute-start (filename, lineno) - * execute-done (filename, lineno) - */ - -provider javascript { - probe function__entry(char *, char *, char *); - probe function__info(char *, char *, char *, int, char *, int); - probe function__args(char *, char *, char *, int, void *, void *, void *, - void *, void *, void *); - probe function__rval(char *, char *, char *, int, void *, void *); - probe function__return(char *, char *, char *); - probe object__create__start(char *, char *); - probe object__create__done(char *, char *); - /* XXX must use unsigned longs here instead of uintptr_t for OS X - (Apple radar: 5194316 & 5565198) */ - probe object__create(char *, char *, unsigned long, int); - probe object__finalize(char *, char *, unsigned long); - probe execute__start(char *, int); - probe execute__done(char *, int); -}; - -/* -#pragma D attributes Unstable/Unstable/Common provider mozilla provider -#pragma D attributes Private/Private/Unknown provider mozilla module -#pragma D attributes Private/Private/Unknown provider mozilla function -#pragma D attributes Unstable/Unstable/Common provider mozilla name -#pragma D attributes Unstable/Unstable/Common provider mozilla args -*/ - diff --git a/samples/DTrace/trace_futexes.d b/samples/DTrace/trace_futexes.d new file mode 100644 index 00000000..c9cbc99f --- /dev/null +++ b/samples/DTrace/trace_futexes.d @@ -0,0 +1,184 @@ +#!/usr/sbin/dtrace -qs + +// Source: https://github.com/bycn82/freebsd/blob/12a4a4a008eac3cfa71e496b33eaeaf426c374c1/sys/compat/linux/trace_futexes.d + +/*- + * Copyright (c) 2011-2012 Alexander Leidinger + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer + * in this position and unchanged. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +/** + * Trace futex operations: + * - internal locks + * - size of the futex list + * - report error conditions (emulation errors, kernel errors, + * programming errors) + * - execution time (wallclock) of futex related functions + */ + +#pragma D option specsize=32m + +/* Error conditions */ +linuxulator*:futex:futex_get:error, +linuxulator*:futex:futex_sleep:requeue_error, +linuxulator*:futex:futex_sleep:sleep_error, +linuxulator*:futex:futex_wait:copyin_error, +linuxulator*:futex:futex_wait:itimerfix_error, +linuxulator*:futex:futex_wait:sleep_error, +linuxulator*:futex:futex_atomic_op:missing_access_check, +linuxulator*:futex:futex_atomic_op:unimplemented_op, +linuxulator*:futex:futex_atomic_op:unimplemented_cmp, +linuxulator*:futex:linux_sys_futex:unimplemented_clockswitch, +linuxulator*:futex:linux_sys_futex:copyin_error, +linuxulator*:futex:linux_sys_futex:unhandled_efault, +linuxulator*:futex:linux_sys_futex:unimplemented_lock_pi, +linuxulator*:futex:linux_sys_futex:unimplemented_unlock_pi, +linuxulator*:futex:linux_sys_futex:unimplemented_trylock_pi, +linuxulator*:futex:linux_sys_futex:unimplemented_wait_requeue_pi, +linuxulator*:futex:linux_sys_futex:unimplemented_cmp_requeue_pi, +linuxulator*:futex:linux_sys_futex:unknown_operation, +linuxulator*:futex:linux_get_robust_list:copyout_error, +linuxulator*:futex:handle_futex_death:copyin_error, +linuxulator*:futex:fetch_robust_entry:copyin_error, +linuxulator*:futex:release_futexes:copyin_error +{ + printf("ERROR: %s in %s:%s:%s\n", probename, probeprov, probemod, + probefunc); + stack(); + ustack(); +} + +linuxulator*:futex:linux_sys_futex:invalid_cmp_requeue_use, +linuxulator*:futex:linux_sys_futex:deprecated_requeue, +linuxulator*:futex:linux_set_robust_list:size_error +{ + printf("WARNING: %s:%s:%s:%s in application %s, maybe an application error?\n", + probename, probeprov, probemod, probefunc, execname); + stack(); + ustack(); +} + + +/* Per futex checks/statistics */ + +linuxulator*:futex:futex:create +{ + ++futex_count; + @max_futexes = max(futex_count); +} + +linuxulator*:futex:futex:destroy +/futex_count == 0/ +{ + printf("ERROR: Request to destroy a futex which was not created,\n"); + printf(" or this script was started after some futexes where\n"); + printf(" created. Stack trace:\n"); + stack(); + ustack(); +} + +linuxulator*:futex:futex:destroy +{ + --futex_count; +} + + +/* Internal locks */ + +linuxulator*:locks:futex_mtx:locked +{ + ++check[probefunc, arg0]; + @stats[probefunc] = count(); + + ts[probefunc] = timestamp; + spec[probefunc] = speculation(); + printf("Stacktrace of last lock operation of the %s:\n", probefunc); + stack(); +} + +linuxulator*:locks:futex_mtx:unlock +/check[probefunc, arg0] == 0/ +{ + printf("ERROR: unlock attempt of unlocked %s (%p),", probefunc, arg0); + printf(" missing SDT probe in kernel, or dtrace program started"); + printf(" while the %s was already held (race condition).", probefunc); + printf(" Stack trace follows:"); + stack(); +} + +linuxulator*:locks:futex_mtx:unlock +{ + discard(spec[probefunc]); + spec[probefunc] = 0; + --check[probefunc, arg0]; +} + +/* Timeout handling for internal locks */ + +tick-10s +/spec["futex_mtx"] != 0 && timestamp - ts["futex_mtx"] >= 9999999000/ +{ + commit(spec["futex_mtx"]); + spec["futex_mtx"] = 0; +} + + +/* Timing statistings */ + +linuxulator*:futex::entry +{ + self->time[probefunc] = timestamp; + @calls[probeprov, execname, probefunc] = count(); +} + +linuxulator*:futex::return +/self->time[probefunc] != 0/ +{ + this->timediff = self->time[probefunc] - timestamp; + + @timestats[probeprov, execname, probefunc] = quantize(this->timediff); + @longest[probeprov, probefunc] = max(this->timediff); + + self->time[probefunc] = 0; +} + + +/* Statistics */ + +END +{ + printf("Number of locks per type:"); + printa(@stats); + printf("Number of maximum number of futexes in the futex list:"); + printa(@max_futexes); + printf("Number of futexes still existing: %d", futex_count); + printf("Number of calls per provider/application/kernel function:"); + printa(@calls); + printf("Wallclock-timing statistics per provider/application/kernel function (in ns):"); + printa(@timestats); + printf("Longest running (wallclock!) functions per provider (in ns):"); + printa(@longest); +} \ No newline at end of file diff --git a/samples/Emacs Lisp/filenames/.spacemacs b/samples/Emacs Lisp/filenames/.spacemacs new file mode 100644 index 00000000..a646eba0 --- /dev/null +++ b/samples/Emacs Lisp/filenames/.spacemacs @@ -0,0 +1,197 @@ +;; -*- mode: emacs-lisp -*- +;; This file is loaded by Spacemacs at startup. +;; It must be stored in your home directory. + +(defun dotspacemacs/layers () + "Configuration Layers declaration." + (setq-default + ;; List of additional paths where to look for configuration layers. + ;; Paths must have a trailing slash (i.e. `~/.mycontribs/') + dotspacemacs-configuration-layer-path '() + ;; List of configuration layers to load. If it is the symbol `all' instead + ;; of a list then all discovered layers will be installed. + dotspacemacs-configuration-layers + '( + ;; ---------------------------------------------------------------- + ;; Example of useful layers you may want to use right away. + ;; Uncomment some layer names and press (Vim style) or + ;; (Emacs style) to install them. + ;; ---------------------------------------------------------------- + emacs-lisp + charlock_holmes + escape_utils + mime-types + rugged + minitest + mocha + plist + pry + rake + yajl-ruby + colour-proximity + licensed + licensee + ;; List of additional packages that will be installed without being + ;; wrapped in a layer. If you need some configuration for these + ;; packages then consider to create a layer, you can also put the + ;; configuration in `dotspacemacs/config'. + dotspacemacs-additional-packages '() + ;; A list of packages and/or extensions that will not be install and loaded. + dotspacemacs-excluded-packages '() + ;; If non-nil spacemacs will delete any orphan packages, i.e. packages that + ;; are declared in a layer which is not a member of + ;; the list `dotspacemacs-configuration-layers' + dotspacemacs-delete-orphan-packages t)) + +(defun dotspacemacs/init () + "Initialization function. +This function is called at the very startup of Spacemacs initialization +before layers configuration." + ;; This setq-default sexp is an exhaustive list of all the supported + ;; spacemacs settings. + (setq-default + ;; Either `vim' or `emacs'. Evil is always enabled but if the variable + ;; is `emacs' then the `holy-mode' is enabled at startup. + dotspacemacs-editing-style 'vim + ;; If non nil output loading progress in `*Messages*' buffer. + dotspacemacs-verbose-loading nil + ;; Specify the startup banner. Default value is `official', it displays + ;; the official spacemacs logo. An integer value is the index of text + ;; banner, `random' chooses a random text banner in `core/banners' + ;; directory. A string value must be a path to an image format supported + ;; by your Emacs build. + ;; If the value is nil then no banner is displayed. + dotspacemacs-startup-banner 'official + ;; List of items to show in the startup buffer. If nil it is disabled. + ;; Possible values are: `recents' `bookmarks' `projects'." + dotspacemacs-startup-lists '(bookmarks projects recents) + ;; List of themes, the first of the list is loaded when spacemacs starts. + ;; Press T n to cycle to the next theme in the list (works great + ;; with 2 themes variants, one dark and one light) + dotspacemacs-themes '( + spacemacs-dark + spacemacs-light + solarized-dark + solarized-light + atom-light-ui + atom-dark-ui + atom-material-ui + zenburn + ;; If non nil the cursor colour matches the state colour. + dotspacemacs-colorize-cursor-according-to-state t + ;; Default font. `powerline-scale' allows to quickly tweak the mode-line + ;; size to make separators look not too crappy. + dotspacemacs-default-font '("Menloco" + :size 11 + :weight normal + :width normal + :powerline-scale 1.1) + ;; The leader key + dotspacemacs-leader-key "SPC" + ;; The leader key accessible in `emacs state' and `insert state' + dotspacemacs-emacs-leader-key "M-m" + ;; Major mode leader key is a shortcut key which is the equivalent of + ;; pressing ` m`. Set it to `nil` to disable it. + dotspacemacs-major-mode-leader-key "," + ;; Major mode leader key accessible in `emacs state' and `insert state' + dotspacemacs-major-mode-emacs-leader-key "C-M-m" + ;; The command key used for Evil commands (ex-commands) and + ;; Emacs commands (M-x). + ;; By default the command key is `:' so ex-commands are executed like in Vim + ;; with `:' and Emacs commands are executed with ` :'. + dotspacemacs-command-key ":" + ;; Location where to auto-save files. Possible values are `original' to + ;; auto-save the file in-place, `cache' to auto-save the file to another + ;; file stored in the cache directory and `nil' to disable auto-saving. + ;; Default value is `cache'. + dotspacemacs-auto-save-file-location 'cache + ;; If non nil then `ido' replaces `helm' for some commands. For now only + ;; `find-files' (SPC f f) is replaced. + dotspacemacs-use-ido nil + ;; If non nil the paste micro-state is enabled. When enabled pressing `p` + ;; several times cycle between the kill ring content. + dotspacemacs-enable-paste-micro-state nil + ;; Guide-key delay in seconds. The Guide-key is the popup buffer listing + ;; the commands bound to the current keystrokes. + dotspacemacs-guide-key-delay 0.4 + ;; If non nil a progress bar is displayed when spacemacs is loading. This + ;; may increase the boot time on some systems and emacs builds, set it to + ;; nil ;; to boost the loading time. + dotspacemacs-loading-progress-bar t + ;; If non nil the frame is fullscreen when Emacs starts up. + ;; (Emacs 24.4+ only) + dotspacemacs-fullscreen-at-startup nil + ;; If non nil `spacemacs/toggle-fullscreen' will not use native fullscreen. + ;; Use to disable fullscreen animations in OSX." + dotspacemacs-fullscreen-use-non-native nil + ;; If non nil the frame is maximized when Emacs starts up. + ;; Takes effect only if `dotspacemacs-fullscreen-at-startup' is nil. + ;; (Emacs 24.4+ only) + dotspacemacs-maximized-at-startup nil + ;; A value from the range (0..100), in increasing opacity, which describes + ;; the transparency level of a frame when it's active or selected. + ;; Transparency can be toggled through `toggle-transparency'. + dotspacemacs-active-transparency 90 + ;; A value from the range (0..100), in increasing opacity, which describes + ;; the transparency level of a frame when it's inactive or deselected. + ;; Transparency can be toggled through `toggle-transparency'. + dotspacemacs-inactive-transparency 90 + ;; If non nil unicode symbols are displayed in the mode line. + dotspacemacs-mode-line-unicode-symbols t + ;; If non nil smooth scrolling (native-scrolling) is enabled. Smooth + ;; scrolling overrides the default behavior of Emacs which recenters the + ;; point when it reaches the top or bottom of the screen. + dotspacemacs-smooth-scrolling t + ;; If non-nil smartparens-strict-mode will be enabled in programming modes. + dotspacemacs-smartparens-strict-mode nil + ;; Select a scope to highlight delimiters. Possible value is `all', + ;; `current' or `nil'. Default is `all' + dotspacemacs-highlight-delimiters 'all + ;; If non nil advises quit functions to keep server open when quitting. + dotspacemacs-persistent-server nil + ;; List of search tool executable names. Spacemacs uses the first installed + ;; tool of the list. Supported tools are `ag', `pt', `ack' and `grep'. + dotspacemacs-search-tools '("ag" "pt" "ack" "grep") + ;; The default package repository used if no explicit repository has been + ;; specified with an installed package. + ;; Not used for now. + dotspacemacs-default-package-repository nil + + ;; If non nil line numbers are turned on in all `prog-mode' and `text-mode' + ;; derivatives. If set to `relative', also turns on relative line numbers. + ;; (default nil) + dotspacemacs-line-numbers 'relative + + ;; Delete whitespace while saving buffer. Possible values are `all', + ;; `trailing', `changed' or `nil'. Default is `changed' (cleanup whitespace + ;; on changed lines) (default 'changed) + dotspacemacs-whitespace-cleanup 'changed + ) + ;; User initialization goes here + ) + +(defun dotspacemacs/user-config () + "Configuration function. + This function is called at the very end of Spacemacs initialization after +layers configuration." + (add-hook 'alchemist-mode-hook 'company-mode) + + (add-hook 'projectile-mode-hook 'projectile-rails-on) + (setq ruby-insert-encoding-magic-comment nil) + + (setq web-mode-markup-indent-offset 2) + (setq web-mode-code-indent-offset 2) + + (spacemacs/toggle-golden-ratio-on) + (spacemacs/toggle-indent-guide-globally-on) + (spacemacs/toggle-centered-point-globally-on) +) + +;; Do not write anything past this comment. This is where Emacs will +;; auto-generate custom variable definitions. +(custom-set-variables + ;; custom-set-variables was added by Custom. + ;; If you edit it by hand, you could mess it up, so be careful. + ;; Your init file should contain only one such instance. + ;; If there is more than one, they won't work right. +) diff --git a/samples/FORTRAN/bug-185631.f b/samples/FORTRAN/bug-185631.f new file mode 100644 index 00000000..abdf87b0 --- /dev/null +++ b/samples/FORTRAN/bug-185631.f @@ -0,0 +1,6 @@ +! Codes/HYCOM/hycom/ATLb2.00/src_2.0.01_22_one/ + real onemu, twomu + data onemu/0.0098/ + data twomu/1./ + data threemu/0.e9/ + end diff --git a/samples/Filebench WML/copyfiles.f b/samples/Filebench WML/copyfiles.f new file mode 100644 index 00000000..dc7f66fa --- /dev/null +++ b/samples/Filebench WML/copyfiles.f @@ -0,0 +1,51 @@ +# +# CDDL HEADER START +# +# The contents of this file are subject to the terms of the +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. +# +# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE +# or http://www.opensolaris.org/os/licensing. +# See the License for the specific language governing permissions +# and limitations under the License. +# +# When distributing Covered Code, include this CDDL HEADER in each +# file and include the License file at usr/src/OPENSOLARIS.LICENSE. +# If applicable, add the following below this CDDL HEADER, with the +# fields enclosed by brackets "[]" replaced with your own identifying +# information: Portions Copyright [yyyy] [name of copyright owner] +# +# CDDL HEADER END +# +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# Use is subject to license terms. +# + +set $dir=/tmp +set $nfiles=1000 +set $meandirwidth=20 +set $meanfilesize=16k +set $iosize=1m +set $nthreads=1 + +set mode quit firstdone + +define fileset name=bigfileset,path=$dir,size=$meanfilesize,entries=$nfiles,dirwidth=$meandirwidth,prealloc=100,paralloc +define fileset name=destfiles,path=$dir,size=$meanfilesize,entries=$nfiles,dirwidth=$meandirwidth + +define process name=filereader,instances=1 +{ + thread name=filereaderthread,memsize=10m,instances=$nthreads + { + flowop openfile name=openfile1,filesetname=bigfileset,fd=1 + flowop readwholefile name=readfile1,fd=1,iosize=$iosize + flowop createfile name=createfile2,filesetname=destfiles,fd=2 + flowop writewholefile name=writefile2,fd=2,srcfd=1,iosize=$iosize + flowop closefile name=closefile1,fd=1 + flowop closefile name=closefile2,fd=2 + } +} + +echo "Copyfiles Version 3.0 personality successfully loaded" diff --git a/samples/Groff/an-ext.tmac b/samples/Groff/an-ext.tmac new file mode 100644 index 00000000..585af208 --- /dev/null +++ b/samples/Groff/an-ext.tmac @@ -0,0 +1,215 @@ +.\" -*- nroff -*- +.\" +.\" an-ext.tmac +.\" +.\" Copyright (C) 2007-2014 Free Software Foundation, Inc. +.\" +.\" Written by Eric S. Raymond +.\" Werner Lemberg +.\" +.\" You may freely use, modify and/or distribute this file. +.\" +.\" The code below provides extension macros for the `man' macro package. +.\" Care has been taken to make the code portable; groff extensions are +.\" properly hidden so that all troff implementations can use it without +.\" changes. +.\" +.\" With groff, this file is sourced by the `man' macro package itself. +.\" Man page authors who are concerned about portability might add the +.\" used macros directly to the prologue of the man page(s). +. +. +.\" Convention: Auxiliary macros and registers start with `m' followed +.\" by an uppercase letter or digit. +. +. +.\" Protect against being sourced twice. +.nr mX +1 +.if \n(mX>1 \ +. nx +. +.\" Check whether we are using grohtml. +.nr mH 0 +.if \n(.g \ +. if '\*(.T'html' \ +. nr mH 1 +. +. +.\" Map mono-width fonts to standard fonts for groff's TTY device. +.if n \{\ +. do ftr CR R +. do ftr CI I +. do ftr CB B +.\} +. +.\" groff has glyph entities for angle brackets. +.ie \n(.g \{\ +. ds la \(la\" +. ds ra \(ra\" +.\} +.el \{\ +. ds la <\" +. ds ra >\" +. \" groff's man macros control hyphenation with this register. +. nr HY 1 +.\} +. +.nr mS 0 +. +. +.\" Declare start of command synopsis. Sets up hanging indentation. +.de SY +. ie !\\n(mS \{\ +. nh +. nr mS 1 +. nr mA \\n(.j +. ad l +. nr mI \\n(.i +. \} +. el \{\ +. br +. ns +. \} +. +. nr mT \w'\fB\\$1\fP\ ' +. HP \\n(mTu +. B "\\$1" +.. +. +. +.\" End of command synopsis. Restores adjustment. +.de YS +. in \\n(mIu +. ad \\n(mA +. hy \\n(HY +. nr mS 0 +.. +. +. +.\" Declare optional option. +.de OP +. ie \\n(.$-1 \ +. RI "[\fB\\$1\fP" "\ \\$2" "]" +. el \ +. RB "[" "\\$1" "]" +.. +. +. +.\" Start URL. +.de UR +. ds m1 \\$1\" +. nh +. if \\n(mH \{\ +. \" Start diversion in a new environment. +. do ev URL-div +. do di URL-div +. \} +.. +. +. +.\" End URL. +.de UE +. ie \\n(mH \{\ +. br +. di +. ev +. +. \" Has there been one or more input lines for the link text? +. ie \\n(dn \{\ +. do HTML-NS "" +. \" Yes, strip off final newline of diversion and emit it. +. do chop URL-div +. do URL-div +\c +. do HTML-NS +. \} +. el \ +. do HTML-NS "\\*(m1" +\&\\$*\" +. \} +. el \ +\\*(la\\*(m1\\*(ra\\$*\" +. +. hy \\n(HY +.. +. +. +.\" Start email address. +.de MT +. ds m1 \\$1\" +. nh +. if \\n(mH \{\ +. \" Start diversion in a new environment. +. do ev URL-div +. do di URL-div +. \} +.. +. +. +.\" End email address. +.de ME +. ie \\n(mH \{\ +. br +. di +. ev +. +. \" Has there been one or more input lines for the link text? +. ie \\n(dn \{\ +. do HTML-NS "" +. \" Yes, strip off final newline of diversion and emit it. +. do chop URL-div +. do URL-div +\c +. do HTML-NS +. \} +. el \ +. do HTML-NS "\\*(m1" +\&\\$*\" +. \} +. el \ +\\*(la\\*(m1\\*(ra\\$*\" +. +. hy \\n(HY +.. +. +. +.\" Continuation line for .TP header. +.de TQ +. br +. ns +. TP \\$1\" no doublequotes around argument! +.. +. +. +.\" Start example. +.de EX +. do ds mF \\n[.fam] +. nr mE \\n(.f +. nf +. nh +. do fam C +. ft CW +.. +. +. +.\" End example. +.de EE +. do fam \\*(mF +. ft \\n(mE +. fi +. hy \\n(HY +.. +. +. +.\" Start display. +.de DS +. \" XXX to be written +.. +. +. +.\" End display. +.de DE +. \" XXX to be written +.. +. +.\" EOF diff --git a/samples/Groff/refs.rno b/samples/Groff/refs.rno new file mode 100644 index 00000000..451ff5fa --- /dev/null +++ b/samples/Groff/refs.rno @@ -0,0 +1,35 @@ +.\" Copyright (c) 1980 Regents of the University of California. +.\" All rights reserved. The Berkeley software License Agreement +.\" specifies the terms and conditions for redistribution. +.\" +.\" @(#)refs.rno 6.1 (Berkeley) 4/29/86 +.\" +.NS 1 "References" +.sp +.ip "[Bac78]" +John Backus, \*(lqCan Programming Be Liberated from the von Neumann Style? +A Functional Style and Its Algebra of Programs,\*(rq \fICACM\fP, Turing +Award Lecture, 21, 8 (August 1978), 613-641. +.sp 6p +.ip "[Fod80]" +John K. Foderaro, \*(lqThe \s-2FRANZ LISP\s+2 +Manual,\*(rq University of California, +Berkeley, California, 1980. +.sp 6p +.ip "[Joy79]" +W.N. Joy, O. Babaoglu, \*(lqUNIX Programmer's Manual,\*(rq November 7, +1979, Computer Science Division, University of California, Berkeley, +California. +.sp 6p +.ip "[Mc60]" +J. McCarthy, \*(lqRecursive Functions of Symbolic expressions and their +Computation by Machine,\*(rq Part I, \fICACM\fP 3, 4 (April 1960), 184-195. +.sp 6p +.ip "[Pat80]" +Dorab Ratan Patel, \*(lqA System Organization for Applicative Programming,\*(rq +M.S Thesis, University of California, Los Angeles, California, 1980. +.sp 6p +.ip "[Pat81]" +Dorab Patel, \*(lqFunctional Language Interpreter User Manual,\*(rq +University of California, Los Angeles, California, 1981. +.bp diff --git a/samples/PowerBuilder/TestPBT.pbt b/samples/PowerBuilder/TestPBT.pbt new file mode 100644 index 00000000..d8d6c03f --- /dev/null +++ b/samples/PowerBuilder/TestPBT.pbt @@ -0,0 +1,42 @@ +// The MIT License (MIT) + +// Copyright (c) 2016 dario ureña + +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: + +// The above copyright notice and this permission notice shall be included in all +// copies or substantial portions of the Software. + +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. + +// Source: https://github.com/darioaxel/PowerScriptToKDMTransformer/blob/c7f167b4852c75d3da2f7b024bda7d7dda241a00/resources/advanced/real/myproject/myproject.pbt + +Save Format v3.0(19990112) +@begin Libraries + "Scs\\Lib\\ScsApex1\\ScsApex1.pbl" ""; +@end; +@begin Objects + "Scs\\Lib\\ScsApex1\\m_mant_apbe.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_mant_envio.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_inp_bolsa.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_mant_imput.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_inp_conce.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_mant_rete.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_info_noti.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_mant_concsani.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_mant_expe.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_proc_expe.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_mant_soli.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; + "Scs\\Lib\\ScsApex1\\m_proc_soli.srm" "Scs\\Lib\\ScsApex1\\ScsApex1.pbl"; +@end; \ No newline at end of file diff --git a/samples/PowerBuilder/ginpix7.sra b/samples/PowerBuilder/ginpix7.sra new file mode 100644 index 00000000..ce913d46 --- /dev/null +++ b/samples/PowerBuilder/ginpix7.sra @@ -0,0 +1,174 @@ +// The MIT License (MIT) + +// Copyright (c) 2016 dario ureña + +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: + +// The above copyright notice and this permission notice shall be included in all +// copies or substantial portions of the Software. + +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. + +// Source: https://github.com/darioaxel/PowerScriptToKDMTransformer/blob/07bf527194b73e133943221dc2199a9442d463eb/resources/inventoryModel/nivel0/ginpix7.sra + +HA$PBExportHeader$ginpix7.sra +$PBExportComments$Aplicaci$$HEX1$$f300$$ENDHEX$$n Ginpix7 +forward +global type ginpix7 from application +end type +global n_tr_apli sqlca +global dynamicdescriptionarea sqlda +global dynamicstagingarea sqlsa +global error error +global message message +end forward + +global variables +n_appmanager gnv_app +//------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ +// Satxa - 02-Jun-2009.27760 No tenemos constancia del uso de esta ayuda, asi que la eliminamos. +//n_help gn_help +//------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ +//---------------------------------------------------------- +// Satxa - 17-Jun-2010.42351 No se usa. +//n_help2 gn_help2 +//---------------------------------------------------------- + +//----------------------------------------------------------------------------------------------------------------------------------------------------------- +// Satxa - 15-Jun-2009.27760 +//Para el modulo de contratos. +String gs_enlacemacros, gs_office2000 // Posibles de Pulir.(en estudio). +//----------------------------------------------------------------------------------------------------------------------------------------------------------- +end variables +global type ginpix7 from application +string appname = "ginpix7" +string toolbarframetitle = "ginpix7" +boolean toolbarusercontrol = false +end type +global ginpix7 ginpix7 + +type prototypes +//------------------------------------------------------------------------------------------------------------------------------------------------------ +// Satxa - 15-Jun-2009.27760 Copio la llamada a la API del objeto aplicaci$$HEX1$$f300$$ENDHEX$$n de LCS. +// Satxa - 25-Oct-2005.25577 Viene de LCS y RCS, abre un archivo independientemente del tipo ejecutando el programa asociado en WINDOWS +Public Function long ShellExecuteA(long hwnd, string lpOperation, string lpFile, string lpParameters, string lpDirectory, long nShowCmd) Library "SHELL32.DLL" alias for "ShellExecuteA;Ansi" +//------------------------------------------------------------------------------------------------------------------------------------------------------ + +// +// Fernando Baldellou.14/05/2009. Ginpix7.// Funciones Externas Globales para el Proyecto de Mensajer$$HEX1$$ed00$$ENDHEX$$a. +// +Public Function Long GetWindowRect (Long hWnd, Ref mensajeria lpRect) Library "user32" alias for "GetWindowRect;Ansi" +Public Function Long GetClientRect (Long hWnd, Ref mensajeria lpRect) Library "user32" alias for "GetClientRect;Ansi" +Public Function Long SetWindowPos (Long hWnd, Long hWndInsertAfter, Long x, Long y, Long cx, Long cy, Long wFlags) Library "user32" +Public Function Boolean sndPlaySoundA (String SoundName, uint Flags)Library "winmm.dll" alias for "sndPlaySoundA;Ansi" +// Fin de la anotaci$$HEX1$$f300$$ENDHEX$$n anterior. + + +end prototypes + +type variables + +end variables + +on ginpix7.create +appname="ginpix7" +message=create message +sqlca=create n_tr_apli +sqlda=create dynamicdescriptionarea +sqlsa=create dynamicstagingarea +error=create error +end on + +on ginpix7.destroy +destroy(sqlca) +destroy(sqlda) +destroy(sqlsa) +destroy(error) +destroy(message) +end on + +event open;// Inicializa propiedades del objeto aplicaci$$HEX1$$f300$$ENDHEX$$n: +This.MicroHelpDefault = "SAVIA" + +//---------------------------------------------------------- +// Satxa - 17-Jun-2010.42351 No se usa. +// Crea el servicio de ayuda nivel2: +//IF NOT IsValid(gn_help2) THEN +// gn_help2 = CREATE n_help2 +//END IF +//---------------------------------------------------------- + +// Presenta la aplicaci$$HEX1$$f300$$ENDHEX$$n: +OpenWithParm(w_ini_ginpix7,commandline) +//OpenWithParm(w_logontab,commandline) + + +// PORQU$$HEX2$$c9002000$$ENDHEX$$RETRASAMOS LA INSTANCIACI$$HEX1$$d300$$ENDHEX$$N DEL MANEJADOR DE LA APLICACI$$HEX1$$d300$$ENDHEX$$N "n_appmanager" ??? +// +// El CNVUO n_appmanager conlleva consigo el proceso de apertura de la ventana w_logon de +// conexi$$HEX1$$f300$$ENDHEX$$n a la base de datos. Nosotros sin embargo, deseamos presentar previamente +// nuestra ventana de presentaci$$HEX1$$f300$$ENDHEX$$n "w_ini". +// +// Si instanciamos n_appmanager aqu$$HEX1$$ed00$$ENDHEX$$, abre "w_ini" pero pasa de largo y no se "queda" en la +// ventana esperando que pulsemos o bien , ll$$HEX1$$e900$$ENDHEX$$ndose directamente a la +// apertura de "w_logon" y requirimientos de datos para la conexi$$HEX1$$f300$$ENDHEX$$n a la base de datos. +// +// Por eso instanciamos el CNVUO n_appmanager en el evento w_ini::cb_ini_con::clicked, para +// retrasar este proceso de conexi$$HEX1$$f300$$ENDHEX$$n a base de datos. +// +//gnv_app = CREATE n_appmanager +//gnv_app.Event pfc_Open(commandline) + + +end event + +event close;//---------------------------------------------------------- +// Satxa - 17-Jun-2010.42351 No se usa. +// Destruye el servicio de ayuda nivel2: +//IF IsValid(gn_help2) THEN +// DESTROY n_help2 +//END IF +//---------------------------------------------------------- + +// Destruye el manejador de aplicaci$$HEX1$$f300$$ENDHEX$$n: +IF IsValid(gnv_app) THEN + DESTROY gnv_app +END IF + +// Redirige el evento al manejador de aplicaci$$HEX1$$f300$$ENDHEX$$n: +IF IsValid(gnv_app) THEN + gnv_app.Event pfc_Close() +END IF + +end event + +event connectionbegin;// Redirige el evento al manejador de aplicaci$$HEX1$$f300$$ENDHEX$$n: +RETURN gnv_app.Event pfc_ConnectionBegin(userid,password,connectstring) + +end event + +event connectionend;// Redirige el evento al manejador de aplicaci$$HEX1$$f300$$ENDHEX$$n: +gnv_app.Event pfc_ConnectionEnd() + + +end event + +event idle;// Redirige el evento al manejador de aplicaci$$HEX1$$f300$$ENDHEX$$n: +gnv_app.Event pfc_Idle() +end event + +event systemerror;// Redirige el evento al manejador de aplicaci$$HEX1$$f300$$ENDHEX$$n: +gnv_app.Event pfc_SystemError() +end event + diff --git a/samples/PowerBuilder/myproject.pbt b/samples/PowerBuilder/myproject.pbt new file mode 100644 index 00000000..ccafecd8 --- /dev/null +++ b/samples/PowerBuilder/myproject.pbt @@ -0,0 +1,32 @@ +// The MIT License (MIT) + +// Copyright (c) 2016 dario ureña + +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: + +// The above copyright notice and this permission notice shall be included in all +// copies or substantial portions of the Software. + +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. + +// Source: https://github.com/darioaxel/PowerScriptToKDMTransformer/blob/173c3949d5684150c34f7405f0689310eade0362/resources/basics/TestPBT.pbt + +Save Format v3.0(19990112) +@begin Projects + 0 "myproject\\myprojectlib.pbl"; +@end; +appname "myproject"; +applib "myproject\\myproject.pbl"; +LibList "myproject\\myproject.pbl;myproject\\lib\\logger\\logger.pbl;myproject\\lib\\payroll\\payroll.pbl;myproject\\lib\\contract\\contract.pbl;myproject\\lib\\common\\common.pbl;"; +type "pb"; \ No newline at end of file diff --git a/samples/PowerBuilder/n_cst_buttonlistbar_gradient.sru b/samples/PowerBuilder/n_cst_buttonlistbar_gradient.sru new file mode 100644 index 00000000..a98bb199 --- /dev/null +++ b/samples/PowerBuilder/n_cst_buttonlistbar_gradient.sru @@ -0,0 +1,765 @@ +// The MIT License (MIT) + +// Copyright (c) 2016 dario ureña + +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: + +// The above copyright notice and this permission notice shall be included in all +// copies or substantial portions of the Software. + +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. + +// Source: https://github.com/darioaxel/PowerScriptToKDMTransformer/blob/07bf527194b73e133943221dc2199a9442d463eb/resources/inventoryModel/nivel0/nivel1/n_cst_buttonlistbar_gradient.sru + +HA$PBExportHeader$n_cst_buttonlistbar_gradient.sru +forward +global type n_cst_buttonlistbar_gradient from nonvisualobject +end type +type gradient_rect from structure within n_cst_buttonlistbar_gradient +end type +type gradient_triangle from structure within n_cst_buttonlistbar_gradient +end type +type rect from structure within n_cst_buttonlistbar_gradient +end type +type trivertex from structure within n_cst_buttonlistbar_gradient +end type +type logfont from structure within n_cst_buttonlistbar_gradient +end type +end forward + +type gradient_rect from structure + unsignedlong upperleft + unsignedlong lowerright +end type + +type gradient_triangle from structure + unsignedlong vertex1 + unsignedlong vertex2 + unsignedlong vertex3 +end type + +type rect from structure + long left + long top + long right + long bottom +end type + +type trivertex from structure + long x + long y + integer red + integer green + integer blue + integer alpha +end type + +type logfont from structure + long lfheight + long lfwidth + long lfescapement + long lforientation + long lfweight + character lfitalic + character lfunderline + character lfstrikeout + character lfcharset + character lfoutprecision + character lfclipprecision + character lfquality + character lfpitchandfamily + character lffacename[32] +end type + +global type n_cst_buttonlistbar_gradient from nonvisualobject autoinstantiate +end type + +type prototypes +FUNCTION ulong SetBkMode(ulong lhdc,ulong nBkMode) LIBRARY "gdi32.dll" +Function Long GetDC (Long hwnd) Library 'user32' +Function Long GetClientRect (Long hwnd, REF RECT lpRect) Library 'user32' alias for "GetClientRect;Ansi" +Function Long ReleaseDC (Long hwnd, Long hdc1) Library 'user32' +Function Boolean GradientRectangle (Long hdc2, TRIVERTEX pVert[], ULong numVert, GRADIENT_RECT pMesh [], ULong numMesh, ULong dMode) Library 'msimg32' Alias For 'GradientFill;Ansi' +Function Boolean GradientTriangle (Long hdc3, TRIVERTEX pVert[], ULong numVert, GRADIENT_TRIANGLE pMesh [], ULong numMesh, ULong dMode) Library 'msimg32' Alias For 'GradientFill;Ansi' + +Function ulong Rectangle (ulong hwnd, ulong X1, ulong Y1, ulong X2, ulong Y2) library "gdi32" +Function ulong CreatePen (ulong nPenStyle, ulong nWidth, ulong crColor) LIBRARY "Gdi32.dll" +Function ULONG SelectObject (uLong hdc4, uLong hObject ) LIBRARY "Gdi32.dll" +function boolean DeleteObject(ulong hgdiobject) library "gdi32.dll" + +FUNCTION ulong DrawText(ulong lhdc,ref string lpStr,ulong nCount,ref RECT lpRect,ulong wFormat) LIBRARY "user32.dll" ALIAS FOR "DrawTextA;Ansi" +FUNCTION ulong SetTextColor(ulong lhdc,ulong crColor) LIBRARY "gdi32.dll" +FUNCTION ulong CreateFontIndirect(ref LOGFONT lpLogFont) LIBRARY "gdi32.dll" ALIAS FOR "CreateFontIndirectA;ANSI" + +Function ulong RoundRect (uLong hdc5 , uLong X1, ulong Y1 , ulong X2 , ulong Y2 , ulong X3 , ulong Y3 ) LIBRARY "Gdi32.dll" +Function ULONG FillRgn (Long hdc6, Long hRgn , Long hBrush ) LIBRARY "Gdi32.dll" +Function ulong CreateRectRgn (Long X1, Long Y1 , Long X2 , Long Y2 ) LIBRARY "Gdi32.dll" +Function ulong CreateRoundRectRgn (long X1 , long Y1 , long X2 , long Y2 , long X3 , long Y3 ) LIBRARY "Gdi32.dll" + +Function ULONG PolyBezier (Long hdc7, REF RECT lpRect, long cPoints ) LIBRARY "Gdi32.dll" +Function ULONG Polyline( Long hdc8, GRADIENT_RECT lppt[], int cPoints) LIBRARY "Gdi32.dll" + +FUNCTION boolean Ellipse(ulong hwnd,long x1,long y1,long x2,long y2) LIBRARY "Gdi32.dll" + +FUNCTION ulong CreatePolygonRgn(ref POINT ppoint[], int count, int fillMode) Library "GDI32.DLL" +FUNCTION long SelectClipRgn(ulong lhdc, ulong lhrgn) Library "GDI32.DLL" + +FUNCTION long PtInRegion(ulong hrgn, int x, int y) LIBRARY "GDI32.dll" + +Function boolean ImageList_Draw(long himl, long i, long hdcDst, long lx, long ly, ulong fStyle) Library "comctl32.dll" +Function boolean ImageList_DrawEx(long himl, long i, long hdcDst, long lx, long ly, long lwidth, long lheight, long lback, long lfore , ulong fStyle) Library "comctl32.dll" + +end prototypes + +type variables +// MS Windows enumerations +CONSTANT ULong GRADIENT_FILL_RECT_H = 0 +CONSTANT ULong GRADIENT_FILL_RECT_V = 1 +CONSTANT ULong GRADIENT_FILL_TRIANGLE = 2 +CONSTANT ULong GRADIENT_FILL_OP_FLAG = 255 + +CONSTANT Long ILD_TRANSPARENT = 1 +CONSTANT Long LVM_GETIMAGELIST = 4098 +CONSTANT Long LVSIL_NORMAL = 0 +CONSTANT Long ILD_BLEND50 = 4 +CONSTANT Long ILD_BLEND25 = 2 + +// User object enumerations +CONSTANT String TOPLEFT = "TOPLEFT" +CONSTANT String TOPRIGHT = "TOPRIGHT" +CONSTANT String BOTTOMRIGHT = "BOTTOMRIGHT" +CONSTANT String BOTTOMLEFT = "BOTTOMLEFT" + +BOOLEAN ib_displayborder + +CONSTANT LONG ALIGN_LEFT = 0 +CONSTANT LONG ALIGN_CENTER = 1 +CONSTANT LONG ALIGN_RIGHT = 2 + +CONSTANT LONG DT_WORD_ELLIPSIS = 262144 +CONSTANT LONG DT_CALCRECT = 1024 +CONSTANT LONG DT_WORDBREAK = 16 + +Long il_HDC + +Long il_newHeight +Long il_newWidth + +PRIVATE: +// Object Handle +Long HDC + +Long il_ShadowBackColor + +ULong iul_font +ULong iul_fontbold + +// Dimensions +RECT DC_Rect + +// Vertices +TRIVERTEX Corner[4] +TRIVERTEX BorderCorner[2] +TRIVERTEX VistaCorner1[4] +TRIVERTEX VistaCorner2[4] +TRIVERTEX VistaCorner3[4] +end variables + +forward prototypes +public subroutine of_verticalgradient (long al_color1, long al_color2) +public subroutine of_splitrgb (long al_color, ref long red, ref long green, ref long blue) +public function boolean of_setdevicecontext (graphicobject ado_palette) +public subroutine of_verticalgradient (long al_color1, long al_color2, graphicobject ado_palette) +public subroutine of_verticalgradient (long al_color1, long al_color2, graphicobject ado_palette, boolean ab_displayborder, long al_bordercolor, integer ai_style) +public subroutine of_xpgradient (long al_color1, long al_color2, graphicobject ado_palette, boolean ab_displayborder, long al_bordercolor) +public function boolean of_setdevicecontext (graphicobject ado_palette, integer ai_style, boolean ab_border) +public function integer of_drawtext (graphicobject ado_palette, string as_text, long al_color, string as_font, long al_size, boolean ab_bold, long al_align, long al_x, long al_y, long al_width, long al_height, boolean ab_displayshadow) +public function integer of_sethdc (long al_hdc) +public function boolean of_getbit (long al_decimal, integer ai_bit) +public function unsignedlong of_createfont (string as_name, long al_size, boolean ab_underline) +public function long of_bitwiseand (long al_value1, long al_value2) +public function long of_bitwiseor (long al_value1, long al_value2) +public function integer of_drawtext (graphicobject ado_palette, string as_text, long al_color, string as_font, long al_size, boolean ab_bold, long al_align, long al_x, long al_y, long al_width, long al_height, boolean ab_displayshadow, boolean ab_elipse, boolean ab_underline, boolean ab_wordwrap) +public function integer of_drawbuttons (dragobject ado_palette, buttons ast_buttons[], long al_bordercolor, long al_imagelist, boolean ab_boldselected, long il_imagesize, long al_height) +public subroutine of_verticalgradient (long al_color1, long al_color2) +public subroutine of_splitrgb (long al_color, ref long red, ref long green, ref long blue) +public function boolean of_setdevicecontext (graphicobject ado_palette) +public subroutine of_verticalgradient (long al_color1, long al_color2, graphicobject ado_palette) +public subroutine of_verticalgradient (long al_color1, long al_color2, graphicobject ado_palette, boolean ab_displayborder, long al_bordercolor, integer ai_style) +public subroutine of_xpgradient (long al_color1, long al_color2, graphicobject ado_palette, boolean ab_displayborder, long al_bordercolor) +public function boolean of_setdevicecontext (graphicobject ado_palette, integer ai_style, boolean ab_border) +public function integer of_drawtext (graphicobject ado_palette, string as_text, long al_color, string as_font, long al_size, boolean ab_bold, long al_align, long al_x, long al_y, long al_width, long al_height, boolean ab_displayshadow) +public function integer of_sethdc (long al_hdc) +public function boolean of_getbit (long al_decimal, integer ai_bit) +public function unsignedlong of_createfont (string as_name, long al_size, boolean ab_underline) +public function long of_bitwiseand (long al_value1, long al_value2) +public function long of_bitwiseor (long al_value1, long al_value2) +public function integer of_drawtext (graphicobject ado_palette, string as_text, long al_color, string as_font, long al_size, boolean ab_bold, long al_align, long al_x, long al_y, long al_width, long al_height, boolean ab_displayshadow, boolean ab_elipse, boolean ab_underline, boolean ab_wordwrap) +public function integer of_drawbuttons (dragobject ado_palette, buttons ast_buttons[], long al_bordercolor, long al_imagelist, boolean ab_boldselected, long il_imagesize, long al_height) +end prototypes + +public subroutine of_verticalgradient (long al_color1, long al_color2);Long ll_Red, & + ll_Green, & + ll_Blue, & + ll_DC +GRADIENT_RECT l_Gradient[1] + +LONG hRPen + +// Set the colors in the first corner (top left) +of_SplitRGB (al_Color1, ll_Red, ll_Green, ll_Blue) +Corner[1].Red = ll_Red +Corner[1].Green = ll_Green +Corner[1].Blue = ll_Blue + +// Set the colors in the third corner (bottom right) +of_SplitRGB (al_Color2, ll_Red, ll_Green, ll_Blue) +Corner[3].Red = ll_Red +Corner[3].Green = ll_Green +Corner[3].Blue = ll_Blue + +l_Gradient[1].UpperLeft = 0 // First corner, top left +l_Gradient[1].LowerRight = 2 // Third corner, bottom right + +ll_DC = il_HDC//GetDC (HDC) + +// Create a border if ib_displayborder is true +IF ib_displayborder THEN + hRPen = CreatePen(0,0,1090519039) + SelectObject(ll_DC, hRPen) + Rectangle(ll_DC, Corner[1].X - 1, Corner[1].Y - 1, Corner[3].X +1, Corner[3].Y +1) +END IF + +GradientRectangle (ll_DC, Corner, 4, l_Gradient, 1, GRADIENT_FILL_RECT_V) + +//ReleaseDC (HDC, ll_DC) +end subroutine + +public subroutine of_splitrgb (long al_color, ref long red, ref long green, ref long blue);Red = Mod (al_Color, 256) +Red *= 256 + +al_Color /= 256 +Green = Mod (al_Color, 256) +Green *= 256 + +Blue = al_Color / 256 +Blue *= 256 +end subroutine + +public function boolean of_setdevicecontext (graphicobject ado_palette);IF NOT IsValid (ado_Palette) THEN RETURN FALSE + +// Get the object's handle +HDC = Handle (ado_Palette) + +// Get the object's dimensions +GetClientRect (HDC, DC_RECT) + +// let's resize the grandient rectangle if border is displayed +IF ib_displayborder THEN + // Initialize the vertices + Corner[1].X = DC_RECT.Left +1 + Corner[1].Y = DC_RECT.Top +1 + Corner[2].X = DC_RECT.Right -1 + Corner[2].Y = DC_RECT.Top +1 + Corner[3].X = DC_RECT.Right -1 + Corner[3].Y = DC_RECT.Bottom - 1 + Corner[4].X = DC_RECT.Left +1 + Corner[4].Y = DC_RECT.Bottom - 1 + + VistaCorner1[1].X = DC_RECT.Left + 1 + VistaCorner1[1].Y = DC_RECT.Top + 1 + VistaCorner1[2].X = DC_RECT.Right -1 + VistaCorner1[2].Y = DC_RECT.Top + 1 + VistaCorner1[3].X = DC_RECT.Right -1 + VistaCorner1[3].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .65)//20 + VistaCorner1[4].X = DC_RECT.Left +1 + VistaCorner1[4].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .65)//20 + + VistaCorner3[1].X = DC_RECT.Left + 1 + VistaCorner3[1].Y = DC_RECT.Top + ((DC_RECT.Bottom * .65) / 2)//10 + VistaCorner3[2].X = DC_RECT.Right -1 + VistaCorner3[2].Y = DC_RECT.Top + ((DC_RECT.Bottom * .65) / 2)//10 + VistaCorner3[3].X = DC_RECT.Right -1 + VistaCorner3[3].Y = DC_RECT.Bottom - 1 + VistaCorner3[4].X = DC_RECT.Left +1 + VistaCorner3[4].Y = DC_RECT.Bottom - 1 + +ELSE + Corner[1].X = DC_RECT.Left + Corner[1].Y = DC_RECT.Top + Corner[2].X = DC_RECT.Right + Corner[2].Y = DC_RECT.Top + Corner[3].X = DC_RECT.Right + Corner[3].Y = DC_RECT.Bottom + Corner[4].X = DC_RECT.Left + Corner[4].Y = DC_RECT.Bottom + + VistaCorner1[1].X = DC_RECT.Left + VistaCorner1[1].Y = DC_RECT.Top + VistaCorner1[2].X = DC_RECT.Right + VistaCorner1[2].Y = DC_RECT.Top + VistaCorner1[3].X = DC_RECT.Right + VistaCorner1[3].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .65)// - 19 + VistaCorner1[4].X = DC_RECT.Left + VistaCorner1[4].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .65)// - 19 + + VistaCorner3[1].X = DC_RECT.Left + VistaCorner3[1].Y = DC_RECT.Top + ((DC_RECT.Bottom * .65) / 2) - 1// + 9//12 + VistaCorner3[2].X = DC_RECT.Right + VistaCorner3[2].Y = DC_RECT.Top + ((DC_RECT.Bottom * .65) / 2) - 1// + 9//12 + VistaCorner3[3].X = DC_RECT.Right + VistaCorner3[3].Y = DC_RECT.Bottom + VistaCorner3[4].X = DC_RECT.Left + VistaCorner3[4].Y = DC_RECT.Bottom +END IF + +RETURN TRUE + + +end function + +public subroutine of_verticalgradient (long al_color1, long al_color2, graphicobject ado_palette);IF NOT of_SetDeviceContext (ado_Palette) THEN RETURN + +of_VerticalGradient (al_Color1, al_Color2) +end subroutine + +public subroutine of_verticalgradient (long al_color1, long al_color2, graphicobject ado_palette, boolean ab_displayborder, long al_bordercolor, integer ai_style);CHOOSE CASE ai_STYLE + CASE 0 + of_XPGradient (al_color1, al_color2, ado_palette,ab_displayborder,al_bordercolor) +END CHOOSE +end subroutine + +public subroutine of_xpgradient (long al_color1, long al_color2, graphicobject ado_palette, boolean ab_displayborder, long al_bordercolor);Long ll_Red, & + ll_Green, & + ll_Blue, & + ll_DC +GRADIENT_RECT l_Gradient[1] + +LONG hRPen + +ib_displayborder = ab_displayborder + +IF NOT of_SetDeviceContext (ado_Palette) THEN RETURN + +//of_VerticalGradient (al_Color1, al_Color2) + +// Set the colors in the first corner (top left) +of_SplitRGB (al_Color1, ll_Red, ll_Green, ll_Blue) +Corner[1].Red = ll_Red +Corner[1].Green = ll_Green +Corner[1].Blue = ll_Blue + +// Set the colors in the third corner (bottom right) +of_SplitRGB (al_Color2, ll_Red, ll_Green, ll_Blue) +Corner[3].Red = ll_Red +Corner[3].Green = ll_Green +Corner[3].Blue = ll_Blue + +l_Gradient[1].UpperLeft = 0 // First corner, top left +l_Gradient[1].LowerRight = 2 // Third corner, bottom right + +ll_DC = il_HDC//GetDC (HDC) + +// Create a border if ib_displayborder is true +IF ab_displayborder THEN + hRPen = CreatePen(0,0,al_bordercolor) + SelectObject(ll_DC, hRPen) + Rectangle(ll_DC, Corner[1].X - 1, Corner[1].Y - 1, Corner[3].X +1, Corner[3].Y +1) + DeleteObject(hRPen) +END IF + +GradientRectangle (ll_DC, Corner, 4, l_Gradient, 1, GRADIENT_FILL_RECT_V) + +//ReleaseDC (HDC, ll_DC) +end subroutine + +public function boolean of_setdevicecontext (graphicobject ado_palette, integer ai_style, boolean ab_border);IF NOT IsValid (ado_Palette) THEN RETURN FALSE + +// Get the object's handle +HDC = Handle (ado_Palette) + +// Get the object's dimensions +GetClientRect (HDC, DC_RECT) + +// let's resize the grandient rectangle if border is displayed +choose case ai_style + case 2 + IF ab_border THEN + // Initialize the vertices + Corner[1].X = DC_RECT.Left +1 + Corner[1].Y = DC_RECT.Top +1 + Corner[2].X = DC_RECT.Right -1 + Corner[2].Y = DC_RECT.Top +1 + Corner[3].X = DC_RECT.Right -1 + Corner[3].Y = DC_RECT.Bottom - 1 + Corner[4].X = DC_RECT.Left +1 + Corner[4].Y = DC_RECT.Bottom - 1 + + VistaCorner1[1].X = DC_RECT.Left + 2 + VistaCorner1[1].Y = DC_RECT.Top + 2 + VistaCorner1[2].X = DC_RECT.Right - 1 + VistaCorner1[2].Y = DC_RECT.Top + 2 + VistaCorner1[3].X = DC_RECT.Right -2 + VistaCorner1[3].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .48)//14 + VistaCorner1[4].X = DC_RECT.Left +1 + VistaCorner1[4].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .48)//14 + + VistaCorner3[1].X = DC_RECT.Left + 2 + VistaCorner3[1].Y = DC_RECT.Top + (DC_RECT.Bottom * .53)//16 + VistaCorner3[2].X = DC_RECT.Right //-1 + VistaCorner3[2].Y = DC_RECT.Top + (DC_RECT.Bottom * .53)//16 + VistaCorner3[3].X = DC_RECT.Right - 2 + VistaCorner3[3].Y = DC_RECT.Bottom - 2 + VistaCorner3[4].X = DC_RECT.Left + VistaCorner3[4].Y = DC_RECT.Bottom - 2 + ELSE + Corner[1].X = DC_RECT.Left +1 + Corner[1].Y = DC_RECT.Top +1 + Corner[2].X = DC_RECT.Right -1 + Corner[2].Y = DC_RECT.Top +1 + Corner[3].X = DC_RECT.Right -1 + Corner[3].Y = DC_RECT.Bottom - 1 + Corner[4].X = DC_RECT.Left +1 + Corner[4].Y = DC_RECT.Bottom - 1 + + VistaCorner1[1].X = DC_RECT.Left + VistaCorner1[1].Y = DC_RECT.Top + VistaCorner1[2].X = DC_RECT.Right + VistaCorner1[2].Y = DC_RECT.Top + VistaCorner1[3].X = DC_RECT.Right + VistaCorner1[3].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .48)//14 + VistaCorner1[4].X = DC_RECT.Left + VistaCorner1[4].Y = DC_RECT.Bottom - (DC_RECT.Bottom * .48)//14 + + VistaCorner3[1].X = DC_RECT.Left + VistaCorner3[1].Y = DC_RECT.Top + (DC_RECT.Bottom * .53)//16 + VistaCorner3[2].X = DC_RECT.Right + VistaCorner3[2].Y = DC_RECT.Top + (DC_RECT.Bottom * .53)//16 + VistaCorner3[3].X = DC_RECT.Right + VistaCorner3[3].Y = DC_RECT.Bottom + VistaCorner3[4].X = DC_RECT.Left + VistaCorner3[4].Y = DC_RECT.Bottom + END IF +end choose + +RETURN TRUE + + +end function + +public function integer of_drawtext (graphicobject ado_palette, string as_text, long al_color, string as_font, long al_size, boolean ab_bold, long al_align, long al_x, long al_y, long al_width, long al_height, boolean ab_displayshadow);RETURN of_DrawText (ado_palette, as_text, al_color, as_font, al_size, ab_bold, al_align, al_x, al_y, al_width, al_height, ab_displayshadow, FALSE, FALSE, FALSE) +end function + +public function integer of_sethdc (long al_hdc);il_HDC = al_hdc + +RETURN 1 +end function + +public function boolean of_getbit (long al_decimal, integer ai_bit);Boolean lb_null + +//Check parameters +If IsNull(al_decimal) or IsNull(ai_bit) then + SetNull(lb_null) + Return lb_null +End If + +//Assumption ai_bit is the nth bit counting right to left with +//the leftmost bit being bit one. +//al_decimal is a binary number as a base 10 long. +If Int(Mod(al_decimal / (2 ^(ai_bit - 1)), 2)) > 0 Then + Return True +End If + +Return False +end function + +public function unsignedlong of_createfont (string as_name, long al_size, boolean ab_underline);LogFont lstr_Lf +uLong lul_Font + +lstr_Lf.lffacename = as_name +lstr_Lf.lfweight = 400 +lstr_Lf.lfheight = al_size * -1 +lstr_Lf.lfPitchAndFamily = '1' +lstr_Lf.lfClipPrecision = Char(2) +lstr_Lf.lfOutPrecision = Char(1) +lstr_Lf.lfQuality = Char(1) +lstr_Lf.lfCharset = Char(1) + +IF ab_underline THEN + lstr_Lf.lfunderline = Char(1) +END IF + +iul_font = CreateFontIndirect( lstr_Lf ) +lstr_Lf.lfweight = 700 +iul_fontbold = CreateFontIndirect( lstr_Lf ) + +RETURN 1 +end function + +public function long of_bitwiseand (long al_value1, long al_value2);Integer li_Cnt +Long ll_Result +Boolean lb_Value1[32], lb_Value2[32] + +// Check for nulls +If IsNull(al_Value1) Or IsNull(al_Value2) Then + SetNull(ll_Result) + Return ll_Result +End If + +// Get all bits for both values +For li_Cnt = 1 To 32 + lb_Value1[li_Cnt] = of_getbit(al_Value1, li_Cnt) + lb_Value2[li_Cnt] = of_getbit(al_Value2, li_Cnt) +Next + +// And them together +For li_Cnt = 1 To 32 + If lb_Value1[li_Cnt] And lb_Value2[li_Cnt] Then + ll_Result = ll_Result + (2^(li_Cnt - 1)) + End If +Next + +Return ll_Result +end function + +public function long of_bitwiseor (long al_value1, long al_value2);Integer li_Cnt +Long ll_Result +Boolean lb_Value1[32], lb_Value2[32] + +// Check for nulls +If IsNull(al_Value1) Or IsNull(al_Value2) Then + SetNull(ll_Result) + Return ll_Result +End If + +// Get all bits for both values +For li_Cnt = 1 To 32 + lb_Value1[li_Cnt] = of_getbit(al_Value1, li_Cnt) + lb_Value2[li_Cnt] = of_getbit(al_Value2, li_Cnt) +Next + +// Or them together +For li_Cnt = 1 To 32 + If lb_Value1[li_Cnt] Or lb_Value2[li_Cnt] Then + ll_Result = ll_Result + (2^(li_Cnt - 1)) + End If +Next + +Return ll_Result + +end function + +public function integer of_drawtext (graphicobject ado_palette, string as_text, long al_color, string as_font, long al_size, boolean ab_bold, long al_align, long al_x, long al_y, long al_width, long al_height, boolean ab_displayshadow, boolean ab_elipse, boolean ab_underline, boolean ab_wordwrap);Long ll_Red, & + ll_Green, & + ll_Blue, & + ll_DC, ll_parm, ll_sizeparm +GRADIENT_RECT l_Gradient[1] +RECT l_Rect, l_Rectback + +LONG hRPen + +IF Len(Trim(as_text)) = 0 THEN + il_newWidth = 1 + il_NewHeight = al_height + RETURN 0 +END IF + +IF NOT of_SetDeviceContext (ado_Palette) THEN RETURN 0 + +ll_DC = il_HDC//GetDC (HDC) + +of_CreateFont(as_font, al_size, ab_underline) + +IF ab_bold THEN + SelectObject(ll_DC, iul_fontbold) +ELSE + SelectObject(ll_DC, iul_font) +END IF + +IF ab_elipse THEN + ll_sizeparm = of_BitWiseOr(al_align, DT_WORD_ELLIPSIS) +ELSE + IF ab_wordwrap THEN + ll_sizeparm = of_BitWiseOr(al_align, DT_WORDBREAK) + END IF +END IF + +IF ab_wordwrap THEN + ll_parm = of_BitWiseOr(DT_CALCRECT, DT_WORDBREAK) +ELSE + ll_parm = DT_CALCRECT +END IF + +SetBkMode(ll_DC, 1) + +/*------------------------------------------------------------------- + Normal text +-------------------------------------------------------------------*/ +// Position +l_Rect.Left = al_x +l_Rect.Top = al_y +l_Rect.Right = al_width +l_Rect.Bottom = al_height + +//SetBkMode(ll_DC, 1) +SetTextColor(ll_DC, al_color) + +IF NOT ab_elipse THEN + Drawtext(ll_DC, as_text, LEN(as_text), l_Rect, ll_parm) +END IF + +IF al_align = ALIGN_RIGHT OR & + al_align = ALIGN_CENTER THEN + l_Rect.Right = al_width +END IF + +Drawtext(ll_DC, as_text, LEN(as_text), l_Rect, ll_sizeparm) + +il_NewHeight = l_Rect.Bottom +il_newWidth = l_Rect.RIGHT + +DeleteObject(iul_font) +DeleteObject(iul_fontbold) + +//ReleaseDC (HDC, ll_DC) + +RETURN 1 +end function + +public function integer of_drawbuttons (dragobject ado_palette, buttons ast_buttons[], long al_bordercolor, long al_imagelist, boolean ab_boldselected, long il_imagesize, long al_height);point lp[], lp_line[] +point lp_empty[] +gradient_rect l_Gradient[1] +GRADIENT_RECT l_Line[] +rect rc +Long ll_Red, & + ll_Green, & + ll_Blue +long hRgn, hRPen, ll_index, ll_count, ll_textcolor, ll_parm +Long ll_inner, ll_innercount +Long ll_textx, ll_texty, ll_textwidth, ll_y +Boolean lb_bold + +ll_count = UpperBound(ast_buttons) + +FOR ll_index = 1 TO ll_count + lp = lp_empty + + lp = ast_buttons[ll_index].ast_point + + IF lp[4].py < 0 OR lp[1].py > al_height THEN + CONTINUE + END IF + + l_Gradient[1].UpperLeft = 0 + l_Gradient[1].LowerRight = 2 + + IF ast_buttons[ll_index].ab_selected OR & + ast_buttons[ll_index].ab_mouseover THEN + Corner[1].X = lp[1].px + Corner[1].Y = lp[1].py + Corner[2].X = lp[2].px + Corner[2].Y = lp[2].py + Corner[3].X = lp[3].px + Corner[3].Y = lp[3].py + Corner[4].X = lp[4].px + Corner[4].Y = lp[4].py + + // Set the colors in the first corner (top left) + of_SplitRGB (ast_buttons[ll_index].al_backcolor1, ll_Red, ll_Green, ll_Blue) + Corner[1].Red = ll_Red + Corner[1].Green = ll_Green + Corner[1].Blue = ll_Blue + + // Set the colors in the third corner (bottom right) + of_SplitRGB (ast_buttons[ll_index].al_backcolor2, ll_Red, ll_Green, ll_Blue) + Corner[3].Red = ll_Red + Corner[3].Green = ll_Green + Corner[3].Blue = ll_Blue + + //Create Polygon + hRPen = CreatePen(0,0,al_bordercolor) + SelectObject(il_HDC, hRPen) + hRgn = CreateRoundRectRgn( Corner[1].X, Corner[1].Y, Corner[3].X, Corner[3].Y,7,7) + RoundRect( il_HDC, Corner[1].X - 1, Corner[1].Y - 1, Corner[3].X, Corner[3].Y,10,10) + + SelectClipRgn(il_HDC, hRgn) + + //Gradient Fill + GradientRectangle (il_HDC, Corner, 4, l_Gradient, 1, GRADIENT_FILL_RECT_V) + + SelectClipRgn(il_HDC, 0) + + DeleteObject(hRPen) + DeleteObject(hRgn) + END IF + + IF ast_buttons[ll_index].ab_enabled THEN + ll_textcolor = 0 + ELSE + ll_textcolor = RGB(100,100,100) + END IF + + IF ab_boldselected AND ast_buttons[ll_index].ab_selected THEN + lb_bold = TRUE + ELSE + lb_bold = FALSE + END IF + + of_DrawText(ado_palette, & + ast_buttons[ll_index].as_text, & + ll_textcolor, & + 'tahoma', & + 11, lb_bold, ALIGN_CENTER, & + ast_buttons[ll_index].ast_point[1].px, & + ast_buttons[ll_index].ast_point[1].py + il_imagesize + 6, & + ast_buttons[ll_index].ast_point[2].px - ast_buttons[ll_index].ast_point[1].px + 10, & + ast_buttons[ll_index].al_textheight, & + FALSE, FALSE, FALSE, TRUE) + + //---------------------------------------- + + IF ast_buttons[ll_index].ab_enabled THEN + ImageList_DrawEx(al_imagelist, & + ast_buttons[ll_index].al_image - 1, & + il_HDC, & + ast_buttons[ll_index].ast_point[1].px + (ast_buttons[ll_index].ast_point[2].px - ast_buttons[ll_index].ast_point[1].px) / 2 - (il_imagesize / 2) , & + ast_buttons[ll_index].ast_point[1].py + 4, & + il_imagesize,il_imagesize, & + 0, 0, ILD_TRANSPARENT ) + ELSE + ll_parm = of_BitWiseOR(ILD_TRANSPARENT, ILD_BLEND50) + ImageList_DrawEx(al_imagelist, & + ast_buttons[ll_index].al_image - 1, & + il_HDC, & + ast_buttons[ll_index].ast_point[1].px + (ast_buttons[ll_index].ast_point[2].px - ast_buttons[ll_index].ast_point[1].px) / 2 - (il_imagesize / 2) , & + ast_buttons[ll_index].ast_point[1].py + 4, & + il_imagesize,il_imagesize, & + 4294967295, RGB(128,128,128), ll_parm ) + END IF + +NEXT + +RETURN 1 +end function + +on n_cst_buttonlistbar_gradient.create +call super::create +TriggerEvent( this, "constructor" ) +end on + +on n_cst_buttonlistbar_gradient.destroy +TriggerEvent( this, "destructor" ) +call super::destroy +end on + diff --git a/samples/PowerBuilder/part1.srw b/samples/PowerBuilder/part1.srw new file mode 100644 index 00000000..ae302630 --- /dev/null +++ b/samples/PowerBuilder/part1.srw @@ -0,0 +1,46 @@ +// The MIT License (MIT) + +// Copyright (c) 2016 dario ureña + +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: + +// The above copyright notice and this permission notice shall be included in all +// copies or substantial portions of the Software. + +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. + +// Source - https://github.com/darioaxel/PowerScriptToKDMTransformer/blob/62083e4cd4f9ead9975427ee9f558d6adef67bbe/resources/advanced/w_mant_seg/part1.srw + +forward +global type w_mant_seg_scs from w_mant +end type +type sle_anio from singlelineedit within w_mant_seg_scs +end type +type st_1 from statictext within w_mant_seg_scs +end type +end forward + +global type w_mant_seg_scs from w_mant +integer height = 952 +sle_anio sle_anio +st_1 st_1 +end type +global w_mant_seg_scs w_mant_seg_scs + +type variables +//------------------------------------------------------------------------------------------ +// Satxa - 26-Ene-2005.19417 +String is_anio +//------------------------------------------------------------------------------------------ +end variables diff --git a/samples/PowerBuilder/w_export.srw b/samples/PowerBuilder/w_export.srw new file mode 100644 index 00000000..c294af41 --- /dev/null +++ b/samples/PowerBuilder/w_export.srw @@ -0,0 +1,399 @@ +// The MIT License (MIT) + +// Copyright (c) 2016 Sébastien Kirche + +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to deal +// in the Software without restriction, including without limitation the rights +// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +// copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: + +// The above copyright notice and this permission notice shall be included in all +// copies or substantial portions of the Software. + +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. + +// Source: https://github.com/sebkirche/libexport/blob/c2459a5399ff87f29344b3b0472b041ebb6f9246/sources/115/w_export.srw + +HA$PBExportHeader$w_export.srw +forward +global type w_export from window +end type +type st_2 from statictext within w_export +end type +type sle_destdir from singlelineedit within w_export +end type +type cb_browse_dest from commandbutton within w_export +end type +type cb_export_some from commandbutton within w_export +end type +type cb_export_all from commandbutton within w_export +end type +type dw_objects from datawindow within w_export +end type +type cb_browse from commandbutton within w_export +end type +type sle_pbl from singlelineedit within w_export +end type +type st_1 from statictext within w_export +end type +end forward + +global type w_export from window +integer width = 3209 +integer height = 1600 +boolean titlebar = true +string title = "Export" +boolean controlmenu = true +boolean minbox = true +boolean maxbox = true +boolean resizable = true +long backcolor = 67108864 +string icon = "AppIcon!" +boolean center = true +st_2 st_2 +sle_destdir sle_destdir +cb_browse_dest cb_browse_dest +cb_export_some cb_export_some +cb_export_all cb_export_all +dw_objects dw_objects +cb_browse cb_browse +sle_pbl sle_pbl +st_1 st_1 +end type +global w_export w_export + +forward prototypes +public subroutine get_objects (string as_pbl) +public function boolean export_object (string as_lib, string as_object, string as_type, string as_comment) +public function string get_object_suffix (string as_type) +public function libexporttype get_object_libtype (string as_type) +public subroutine export_object_at_row (long al_row, string as_lib) +end prototypes + +public subroutine get_objects (string as_pbl); +if not fileexists(as_pbl) then return + +int i, p = 1 +string ls_entries, ls_entry +ls_entries = LibraryDirectoryEx(as_pbl, DirAll!) +debug_message('get_objects()', ls_entries) + +dw_objects.reset() +dw_objects.importstring(ls_entries) + +end subroutine + +public function boolean export_object (string as_lib, string as_object, string as_type, string as_comment); +LibExportType l_ot +string ls_syntax, ls_filename, ls_dir +int li_file + +ls_dir = sle_destdir.text +l_ot = get_object_libtype(as_type) +ls_syntax = libraryexport(as_lib, as_object, l_ot) + +ls_filename = as_object + '.' + get_object_suffix(as_type) +li_file = FileOpen(ls_dir + '\' + ls_filename, streammode!, write!, LockReadWrite!, Replace!, EncodingUTF16LE!) +if li_file = -1 then return false + +FileWrite(li_file, "$PBExportHeader$" + ls_filename + "~r~n") +if as_comment <> "" then + FileWrite(li_file, "$PBExportComments$" + as_comment + "~r~n") +end if +FileWrite(li_file, ls_syntax) +FileClose(li_file) + +return true + +end function + +public function string get_object_suffix (string as_type); +string ls_suf = "" + +choose case as_type + case 'Application'; ls_suf = 'sra' + case 'DataWindow'; ls_suf = 'srd' + case 'Function'; ls_suf = 'srf' + case 'Menu'; ls_suf = 'srm' + case 'Pipeline'; ls_suf = 'srp' + case 'Project'; ls_suf = 'srj' + case 'Query'; ls_suf = 'srq' + case 'Structure'; ls_suf = 'srs' + case 'UserObject'; ls_suf = 'sru' + case 'Window'; ls_suf = 'srw' +end choose + +return ls_suf + +end function + +public function libexporttype get_object_libtype (string as_type); +libexporttype l_ot + +choose case as_type + case 'Application'; l_ot = ExportApplication! + case 'DataWindow'; l_ot = ExportDataWindow! + case 'Function'; l_ot = ExportFunction! + case 'Menu'; l_ot = ExportMenu! + case 'Pipeline'; l_ot = ExportPipeline! + case 'Project'; l_ot = ExportProject! + case 'Query'; l_ot = ExportQuery! + case 'Structure'; l_ot = ExportStructure! + case 'UserObject'; l_ot = ExportUserObject! + case 'Window'; l_ot = ExportWindow! +end choose + +return l_ot + +end function + +public subroutine export_object_at_row (long al_row, string as_lib); +string ls_obj, ls_type, ls_comment + +ls_obj = dw_objects.getitemstring(al_row, "obj_name") +ls_type = dw_objects.getitemstring(al_row, "obj_type") +ls_comment = dw_objects.getitemstring(al_row, "comment") +export_object(as_lib, ls_obj, ls_type, ls_comment) + +end subroutine + +on w_export.create +this.st_2=create st_2 +this.sle_destdir=create sle_destdir +this.cb_browse_dest=create cb_browse_dest +this.cb_export_some=create cb_export_some +this.cb_export_all=create cb_export_all +this.dw_objects=create dw_objects +this.cb_browse=create cb_browse +this.sle_pbl=create sle_pbl +this.st_1=create st_1 +this.Control[]={this.st_2,& +this.sle_destdir,& +this.cb_browse_dest,& +this.cb_export_some,& +this.cb_export_all,& +this.dw_objects,& +this.cb_browse,& +this.sle_pbl,& +this.st_1} +end on + +on w_export.destroy +destroy(this.st_2) +destroy(this.sle_destdir) +destroy(this.cb_browse_dest) +destroy(this.cb_export_some) +destroy(this.cb_export_all) +destroy(this.dw_objects) +destroy(this.cb_browse) +destroy(this.sle_pbl) +destroy(this.st_1) +end on + +type st_2 from statictext within w_export +integer x = 32 +integer y = 1208 +integer width = 251 +integer height = 76 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +long textcolor = 33554432 +long backcolor = 67108864 +string text = "Export into" +boolean focusrectangle = false +end type + +type sle_destdir from singlelineedit within w_export +integer x = 325 +integer y = 1204 +integer width = 2619 +integer height = 80 +integer taborder = 30 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +long textcolor = 33554432 +string text = "none" +borderstyle borderstyle = stylelowered! +end type + +type cb_browse_dest from commandbutton within w_export +integer x = 2985 +integer y = 1204 +integer width = 169 +integer height = 80 +integer taborder = 30 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +string text = "..." +end type + +event clicked; +string ls_dir + +ls_dir = getfolder("Select the directory where you want to export") +if ls_dir <> "" then + sle_destdir.text = ls_dir +end if + +end event + +type cb_export_some from commandbutton within w_export +integer x = 398 +integer y = 1344 +integer width = 457 +integer height = 100 +integer taborder = 50 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +string text = "Export selected" +end type + +event clicked; +string ls_lib +int r + +ls_lib = sle_pbl.text +if not fileexists(ls_lib) then return + +r = dw_objects.getselectedrow(0) +do while r > 0 + export_object_at_row(r, ls_lib) + r = dw_objects.getselectedrow(r) +loop + +end event + +type cb_export_all from commandbutton within w_export +integer x = 37 +integer y = 1344 +integer width = 338 +integer height = 100 +integer taborder = 40 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +string text = "Export all" +end type + +event clicked; +string ls_lib +int i, li_max + +ls_lib = sle_pbl.text +if not fileexists(ls_lib) then return + +li_max = dw_objects.rowcount() +for i = 1 to li_max + export_object_at_row(i, ls_lib) +next +end event + +type dw_objects from datawindow within w_export +integer x = 32 +integer y = 212 +integer width = 2912 +integer height = 876 +integer taborder = 30 +string title = "none" +string dataobject = "dw_objects" +boolean hscrollbar = true +boolean vscrollbar = true +boolean livescroll = true +borderstyle borderstyle = stylelowered! +end type + +event clicked; +boolean lb_sel + +lb_sel = dw_objects.isselected(row) +dw_objects.selectrow(row, not lb_sel) + +end event + +type cb_browse from commandbutton within w_export +integer x = 2985 +integer y = 64 +integer width = 169 +integer height = 80 +integer taborder = 20 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +string text = "..." +end type + +event clicked; +string ls_dir, ls_file, ls_path + +if 1 = getfileopenname("Choose a library to export", ls_dir, ls_file, "pbl", "Libraries (*.PBL),*.PBL") then + ls_path = ls_dir + sle_pbl.text = ls_path + get_objects(ls_path) +end if + +end event + +type sle_pbl from singlelineedit within w_export +integer x = 256 +integer y = 64 +integer width = 2688 +integer height = 80 +integer taborder = 10 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +long textcolor = 33554432 +string text = "none" +borderstyle borderstyle = stylelowered! +end type + +type st_1 from statictext within w_export +integer x = 32 +integer y = 72 +integer width = 215 +integer height = 76 +integer textsize = -8 +integer weight = 400 +fontcharset fontcharset = ansi! +fontpitch fontpitch = variable! +fontfamily fontfamily = swiss! +string facename = "Tahoma" +long textcolor = 33554432 +long backcolor = 67108864 +string text = "Library" +boolean focusrectangle = false +end type + diff --git a/samples/Python/spec.linux.spec b/samples/Python/spec.linux.spec new file mode 100644 index 00000000..c5806cd3 --- /dev/null +++ b/samples/Python/spec.linux.spec @@ -0,0 +1,22 @@ +a = Analysis(['portablizer.pyqt4.py'], + hiddenimports=[], + hookspath=None, + runtime_hooks=None) +pyz = PYZ(a.pure) +exe = EXE(pyz, + a.scripts, + exclude_binaries=True, + name='Portablizer', + debug=False, + strip=None, + upx=True, + console=False) +node = Tree('node', prefix='node') +collect = COLLECT(exe, + a.binaries, + a.zipfiles, + a.datas, + node, + strip=None, + upx=True, + name='Portablizer') diff --git a/samples/REXX/BatchRemapBrushes.pprx b/samples/REXX/BatchRemapBrushes.pprx new file mode 100644 index 00000000..a621ae19 --- /dev/null +++ b/samples/REXX/BatchRemapBrushes.pprx @@ -0,0 +1,174 @@ +/* Ga igenom lador med IFF-filer rekursivt och skapa: + 1: Spritekartor om 320x256 med alla spritar + 2: En tabell med enumererade spritenummer + Aterstar: + *: Att skriva shapesfiler direkt + $VER: 1.0 +*/ +SIGNAL ON BREAK_C +PARSE ARG argument +template = 'START/N COLOURS/N REMAP/S RECURSIVE/S PALETTE/K DIRECTORY/A' +CALL Init + +ADDRESS 'PPAINT' +OPTIONS RESULTS +GetBestVideoMode WIDTH 320 HEIGHT 256 COLORS args.colours +modeid=Word(RESULT,1) +say modeid +Set 'FORCE "DISPLAY=' || modeid || '"' +IF RC~=0 THEN EXIT 20 +Set 'FORCE "IMAGEW=320" "IMAGEH=256" "COLORS='args.colours'"' +ClearImage +LockGUI +ScreenToFront +x=0 ; y=0 ; maxhoejd=0 ; fil#=0 ; blad#=0 +CALL WriteLn konstfil, ';Blad' blad# +DO UNTIL Lines()==0 & fillista=='' + DO WHILE fillista~='' + PARSE VAR fillista filnamn 'y' fillista + IF Right(filnamn,5)=='.info' THEN ITERATE + IF Word(StateF(dir||filnamn),1)=='DIR' THEN DO + PUSH fillista + PUSH dir + dir=dir||filnamn||'/' + SAY 'Entering directory' dir'...' + fillista=ShowDir(dir,'ALL','y') + ITERATE + END + LoadBrush FILE dir || filnamn NOPROGRESS + IF RC~==0 THEN DO + SAY 'Skipping file:' dir || filnamn + ITERATE + END + IF args.remap THEN RemapBrush NOPROGRESS + GetBrushAttributes WIDTH ; bredd=RESULT + GetBrushAttributes HEIGHT ; hoejd=RESULT + GetBrushAttributes COLORS ; djup=RESULT + IF bredd//16==0 THEN ebwidth=bredd + ELSE ebwidth=bredd+(16-(bredd//16)) + maxhoejd=Max(maxhoejd,hoejd) + SAY 'File:' Left(filnamn,29) 'Width:' bredd ' Height:' hoejd ' Depth:' djup ' ebwidth:' ebwidth + SetCurrentBrush RECTANGULAR WIDTH 1 HEIGHT 1 + DrawRectangle x y x+ebwidth y+hoejd + Text fil# 'X' x+2 'Y' y+2 + SetCurrentBrush 1 ; SetBrushHandle 0 0 + PutBrush x y + CALL WriteLn(konstfil,'; '||fil# ||': '|| filnamn ||' ('||ebwidth||'x'||hoejd||'x'||djup||')') + CALL WriteLn(konstfil,'#'||Upper(Left(filnamn,Min(Length(filnamn),Max(LastPos('.',filnamn)-1,0))))||'='fil#) + x=x+ebwidth + IF x+ebwidth>319 THEN DO + x=0 + y=y+maxhoejd + IF y+maxhoejd>255 THEN DO + SaveImage FILE 'Spritesheet' || blad# || '.ilbm' FORCE + IF RC==0 THEN SAY 'Saved sheet' blad# + ELSE SAY "Couldn't save spritesheet" + ClearImage + y=0 + blad#=blad#+1 + CALL WriteLn konstfil, ';Blad' blad# + END + maxhoejd=0 + END + fil#=fil#+1 + END /* WHILE fillista */ + IF Lines()>0 THEN DO + PARSE PULL dir + PARSE PULL fillista + SAY 'Going back to' dir'...' + END +END /* UNTIL Lines() */ + +BREAK_C: +FreeBrush FORCE +UnLockGUI +medd=fil# 'files processed in' blad#+1 'sheets' +SAY medd +RequestNotify 'TITLE SpriteSheet.pprx PROMPT "'medd'"' +ScreenToBack +CALL Close(konstfil) +DO WHILE Lines()>0; PULL .; END +EXIT 0 + +Init: + IF argument = '' | argument = '?' THEN DO + SAY template + EXIT 0 + END + + CALL ReadArgs() + + IF ~Show('L',"rexxsupport.library") THEN DO + IF ~AddLib("rexxsupport.library",0,-30,0) THEN DO + SAY 'Hittade inte rexxsupport.library' + EXIT 20 + END + END + IF ~Open(konstfil,'SpriteConstants.txt','WRITE') THEN EXIT 10 + + IF ~SHOW('P', 'PPAINT') THEN DO + SAY "Couldn't find PPaint. Please start the program first." + EXIT 5 + END + dir=args.directory + IF dir='""' THEN dir=Pragma('DIRECTORY') + IF dir='' THEN dir='Ram:Megamanv6/Graphics/' + IF Right(dir,1)~=='/' THEN dir=dir || '/' + fillista=ShowDir(dir,'FILES','y') + fillista=ShowDir(dir,'ALL','y') + IF fillista="" THEN DO + SAY "Found no files" + EXIT 5 + END + IF args.colours==0 THEN args.colours=16 + ADDRESS 'PPAINT' + OPTIONS RESULTS + IF args.palette~='' THEN LoadPalette args.palette +RETURN + +ReadArgs: +/* ReadArgs()-like evaluation of command line arguments */ +SAY 'ReadArgs' +DO key# = 1 TO Words(Template) + key=Word(template,key#) + PARSE VAR key key "/" keytype + SELECT + WHEN keytype='S'|keytype='N' THEN args.key=0 + WHEN keytype='K'|keytype='A' THEN args.key='' + OTHERWISE NOP /* Error in template */ + END + END + +DO WHILE argument ~= '' + PARSE VAR argument arg1 argument + arg2='' + DO key# = 1 TO Words(template) + key = Word(template,key#) + PARSE VAR key key '/' keytype + IF Upper(Left(arg1,Length(key))) = key THEN DO + SELECT + WHEN keytype='S' THEN DO + args.key=1 + END + WHEN keytype='K' | keytype='N' | keytype='A' THEN DO + IF Index(arg1,'=')>0 + THEN DO + SAY 'Innehaller =' + PARSE VAR arg1 '=' arg2 + SAY 'arg2:' arg2 + END + ELSE PARSE VAR argument arg2 argument + args.key=arg2 + IF keytype='N' & DataType(arg2)~==NUM THEN DO + SAY 'Illegal numerical argument' key arg2 + EXIT 10 + END + END + END + arg1='' + LEAVE key# + END + END + IF arg1~='' THEN args.directory=arg1 + END +RETURN \ No newline at end of file diff --git a/samples/REXX/ShapesInfo.rexx b/samples/REXX/ShapesInfo.rexx new file mode 100644 index 00000000..56918a58 --- /dev/null +++ b/samples/REXX/ShapesInfo.rexx @@ -0,0 +1,135 @@ +/* Display information about Blitz Basic .shapes file, + optionally displaying the shape's cookiecut +$AUTHOR: Iggy Drougge 2016 +$VER: 1.1 +*/ +PARSE ARG argument +template = 'FROM/N TO/N SHOW/S FILE/A' +IF argument = '' | argument = '?' THEN DO + SAY 'ShapesInfo' template + EXIT 0 + END + +CALL ReadArgs() + +IF ~Open(fh,args.file,READ) then DO + SAY "Couldn't Open file:" args.file + EXIT 10 + END + +shape#=0 +filebad=0 +IF args.to=0 THEN args.to=9999 + +IF args.from>1 THEN SAY 'Seeking...' +DO WHILE ~EOF(fh) + header=ReadCh(fh,32) + IF EOF(fh) THEN DO + SAY 'Reached end of file.' + EXIT 0 + END + PARSE VALUE header WITH pixwidth +2 pixheight +2 depth +2 ebwidth +2 bltsize +2 xhandle +2 yhandle +2 . +4 . +4 onebpmem +2 onebpmemx +2 allbpmem +2 allbpmemx +2 . + CALL CheckHeader + IF filebad THEN DO + SAY 'Not a valid shapes file.' + SAY C2X(header) + EXIT 10 + END + shape#=shape#+1 + bitplanesize = C2D(ebwidth) * C2D(pixheight) + bitmapsize = bitplanesize * C2D(depth) + IF shape# < args.from THEN DO + CALL Seek(fh,bitmapsize,CURRENT) + ITERATE + END + IF shape# > args.to THEN LEAVE + CALL PrintHeader + IF args.show THEN CALL ShowCookiecut + ELSE CALL Seek(fh,bitmapsize,CURRENT) + END +EXIT 0 + +CheckHeader: + IF C2D(pixwidth)>C2D(ebwidth)*8 THEN filebad=1 + IF Left(C2B(bltsize),10)~=C2B(pixheight) THEN filebad=1 +RETURN + +PrintHeader: + SAY 'Shape #' || shape# || ':' + SAY ' Width: ' C2D(pixwidth) 'pixels' '('C2D(ebwidth) 'bytes)' + SAY ' Height: ' C2D(pixheight) 'pixels' + SAY ' Depth: ' C2D(depth) 'bitplanes' + SAY ' BLTSIZE: ' '$'C2X(bltsize) '('||, + C2D(B2C(Left(C2B(bltsize),10))) 'x', + C2D(B2C(Right(C2B(bltsize),6)))')' + SAY ' Handle: ' C2D(xhandle)','C2D(yhandle) +/* + SAY 'Onebpmem: ' C2D(onebpmem) + SAY 'OnebpmemX:' C2D(onebpmemx) + SAY 'Allbpmem: ' C2D(allbpmem) + SAY 'AllbpmemX:' C2D(allbpmemx) +*/ +RETURN + + + +ShowCookiecut: + depth=C2D(depth) + bmap=Copies('00'x,bitplanesize) + DO FOR depth + bmap=BitOr(bmap,readch(fh,bitplanesize)) + END + ln=1 ; pixheight=C2D(pixheight) ; ebwidth=C2D(ebwidth) + DO FOR pixheight + SAY C2B(SubStr(bmap,ln,ebwidth)) + ln=ln+ebwidth + END +RETURN + +EXIT 0 + +ReadArgs: +/* ReadArgs()-like evaluation of command line arguments */ +DO key# = 1 TO Words(Template) /* Initialise the keywords */ + key=Word(template,key#) + PARSE VAR key key "/" keytype + SELECT + WHEN keytype='S'|keytype='N' THEN args.key=0 + WHEN keytype='K'|keytype='A' THEN args.key='' + OTHERWISE NOP /* Error in template */ + END + END + +DO WHILE argument ~= '' + PARSE VAR argument arg1 argument + arg2='' + DO key# = 1 TO Words(template) + key = Word(template,key#) + PARSE VAR key key '/' keytype + IF Upper(Left(arg1,Length(key))) = key THEN DO + SELECT + WHEN keytype='S' THEN DO + args.key=1 + END + WHEN keytype='K' | keytype='N' | keytype='A' THEN DO + IF Index(arg1,'=')>0 + THEN DO + SAY 'Innehaller =' + PARSE VAR arg1 '=' arg2 + SAY 'arg2:' arg2 + END + ELSE PARSE VAR argument arg2 argument + args.key=arg2 + IF keytype='N' & DataType(arg2)~==NUM THEN DO + SAY 'Illegal numerical argument' key arg2 + EXIT 10 + END + END + END + arg1='' + LEAVE key# + END + END + IF arg1~='' THEN args.file=arg1 + END +RETURN \ No newline at end of file diff --git a/samples/REXX/SkrivShape.rexx b/samples/REXX/SkrivShape.rexx new file mode 100644 index 00000000..42e5e6d3 --- /dev/null +++ b/samples/REXX/SkrivShape.rexx @@ -0,0 +1,54 @@ +/* rexx */ +PARSE ARG filnamn +IF filnamn='' THEN DO + filnamn='raw' + filnamn='font.shapes' + end +IF ~open(fil,filnamn,r) THEN EXIT 10 +pixwidth=48 +ebwidth=pixwidth/8 +pixheight=48 +depth=4 +SAY "Skriver utfil..." +CALL open utfil,"RAM:utfil",W +CALL skriv pixwidth,2 +CALL skriv pixheight,2 +CALL skriv depth,2 +CALL skriv ebwidth,2 +bltsize=Right(C2B(D2C(pixheight)),10,"00") +bltsize=bltsize || Right(C2B(D2C(ebwidth)),6,"00") +/* SAY bltsize */ +CALL skriv C2D(B2C(bltsize)),2 +CALL skriv 0,4 /* xhandle, yhandle*/ +CALL skriv 0,4 /* datapekare */ +CALL skriv 0,4 /* cookiepekare */ +CALL skriv ebwidth*pixheight,2 /* onebpmem */ +CALL skriv ebwidth*pixheight+pixheight*2,2 /* onebpmemx */ +CALL skriv ebwidth*pixheight*depth,2 /* allbpmem */ +CALL skriv ebwidth*pixheight*depth+pixheight*2*depth,2 /* allbpmemx */ +CALL skriv 0,2 /* padding */ +CALL Close utfil +EXIT + +skriv: +say "Skriver $"D2X(arg(1)) "("arg(2) "byte)" +call writech utfil,right(D2C(ARG(1)),ARG(2),"00"x) +return + +visacookie: + rad=copies('00'x,pixheight*ebwidth) + say "Initierar bitmap till" pixheight*ebwidth*depth + say "Ett bitplan =" pixheight*ebwidth + bmap.='' + say "laser in" + do bitplan=1 to depth + say "laser plan" bitplan + rad=bitor(rad,readch(fil,pixheight*ebwidth)) + end + ln=1 + say "skriver ut" + do for pixheight + say c2b(substr(rad,ln,bredd/8)) + ln=ln+bredd/8 + end +return \ No newline at end of file diff --git a/samples/REXX/ag2xml.rexx b/samples/REXX/ag2xml.rexx new file mode 100644 index 00000000..8ee3faaa --- /dev/null +++ b/samples/REXX/ag2xml.rexx @@ -0,0 +1,106 @@ +/* Las en Amigaguidefil och omvandla till nan slags XML */ +/* $VER: 2 */ +options AREXX_BIFS +options AREXX_SEMANTICS +if ~open(infil,'Blitz2_V1.3.guide',R) then exit 10 +if ~open(utfil,'bb2.xml',W) then exit 10 + +call writeln utfil,'' +call writeln utfil,'' +radnr=1 +inrad=readln(infil) + +do while ~eof(infil) + och=1 + do while index(inrad,'&',och)>0 + och=index(inrad,'&',och) + if index(inrad,';',och)=0 then do + parse value inrad with prefix =(och) +1 suffix + inrad=prefix'&'suffix + och=index(inrad,';',och) + end + end + do while index(inrad,'<')>0 + parse var inrad prefix '<' suffix + inrad = prefix'<'suffix + end + do while index(inrad,'>')>0 + parse var inrad prefix '>' suffix + inrad = prefix'>'suffix + end + inrad=behandlarad(inrad) + if right(inrad,1)~='>' & strip(inrad)~='' then inrad=inrad || ' ' + testrad=inrad + do while index(testrad,'>') > 0 + parse var testrad prefix '<' . '>' suffix + testrad = prefix || suffix + end + if length(testrad)<65 then inrad = inrad || '0d'x + call writech utfil,inrad + inrad=readln(infil) + radnr=radnr+1 +end +call close(infil) +call writeln utfil,'' +call close(utfil) +exit 0 + +behandlarad: procedure +parse arg inrad +do forever + if abbrev(inrad,'@NODE') then do + parse var inrad '@NODE ' nod inrad + /* say 'Hittade nod:' nod */ + inrad='' || inrad + end + if inrad='@ENDNODE' then inrad='' || '0d'x + /* say inrad */ + if abbrev(inrad,'-----') then inrad=' ' + if abbrev(inrad,'Command'), + | abbrev(inrad,'Function'), + | abbrev(inrad,'Statement') then do + parse var inrad kommandotyp ':' inrad + /* if index(inrad,'@{')>0 then */ + parse var inrad inrad '@{' rest + if rest~='' then rest='@{' || rest + /* say 'rest:' rest */ + inrad=''||strip(kommandotyp)||' '||behandlarad(inrad)||''||behandlarad(rest) + end + if index(inrad,'@{')>0 then do + parse var inrad inrad '@{' tagg '}' rest + select + when tagg='fg shine' then tagg='' + when tagg='fg text' then tagg='' + when tagg='b' then tagg='' + when tagg='ub' then tagg='' + /* @{" SpriteMode " link BUM_SPRITEMODE} */ + when abbrev(tagg,'"') then do + parse var tagg '"' besk '"' . 'link' dest + tagg='' || besk || '' + end + otherwise tagg='' + end + rest=behandlarad(rest) + /* + if index(rest,'@{')>0 then rest=behandlarad(left(rest,index(rest,'@{'))) || substr(rest,index(rest,'@{')) + */ + inrad=inrad || tagg || rest + /* iterate */ + end + if abbrev(inrad,'@') then do + say 'Hittade okand tagg:' inrad + /* inrad='' inrad '' */ + parse var inrad '@' tagg inrad + if abbrev(tagg,'$') then parse var tagg '$' tagg ':' + inrad='<'tagg'>'inrad'' + end + if abbrev(inrad,'Modes') then do + parse var inrad . ':' inrad + inrad='Modes: ' || strip(inrad) || '' + end + if abbrev(inrad,'Syntax') then do + parse var inrad . ':' inrad + inrad='Syntax: ' || strip(inrad) || '' + end + return inrad +end \ No newline at end of file diff --git a/samples/RPM Spec/apache.spec b/samples/RPM Spec/apache.spec new file mode 100644 index 00000000..6e34ba98 --- /dev/null +++ b/samples/RPM Spec/apache.spec @@ -0,0 +1,673 @@ +%define _prefix /usr/local +%define _mandir /usr/local/man +%define _sysconfdir /etc + +%define apache_ver 1.3.42 +%define mod_ssl_ver 2.8.31 +%define mod_perl_ver 1.31 +%define libapreq_ver 1.34 + + +%define aname apache +%define pname httpd13 +%define contentdir %{_var}/www +%define suexec_caller apache + +Summary: The 1.x Apache webserver (with static mod_perl, mod_ssl) +Name: apache +Version: %{apache_ver} +Release: 4%{?dist} +License: Apache Software License 2.0 +URL: http://httpd.apache.org/ +Group: System Environment/Daemons + +Requires: initscripts >= 3.25 +Requires: openssl >= 0.9.6 + +BuildRequires: openssl-devel mm-devel krb5-devel pkgconfig +BuildRequires: perl-ExtUtils-MakeMaker perl-libwww-perl perl-HTML-Parser perl-ExtUtils-Embed +BuildRequires: gdbm-devel flex +Requires: /sbin/chkconfig /bin/mktemp /usr/sbin/useradd +Requires: findutils procps + +Provides: webserver +Provides: mod_perl = %{mod_perl_ver} +Provides: perl(mod_perl) = %{mod_perl_ver} +Provides: mod_ssl = %{mod_ssl_ver} +Provides: apache = %{apache_ver} + +Source0: http://httpd.apache.org/dist/apache_%{apache_ver}.tar.bz2 +Source1: http://www.modssl.org/source/mod_ssl-%{mod_ssl_ver}-%{apache_ver}.tar.gz +Source2: http://perl.apache.org/dist/mod_perl-%{mod_perl_ver}.tar.gz +Source3: httpd.init +Source4: apache.logrotate +Source5: SSL-Certificate-Creation +Source6: ftp://ftp.cpan.org/authors/id/J/JO/JOESUF/libapreq-%{libapreq_ver}.tar.gz + +Patch0: sslcfg.patch +Patch1: apache_1.3.39-config.patch +Patch3: apache_1.3.39-Makefile.patch +Patch5: apache_1.3.20-apachectl-init.patch +Patch11: mod_ssl-2.8.4-openssl.patch +Patch12: apache_1.3.42-db.patch +Patch13: apache-1.3.39-gcc44.patch +Patch14: mod_ssl-2.8.31-STACK.patch +Patch15: apache_1.3.39-ap_getline.patch +Patch16: mod_ssl-openssl-x86_64.patch +Patch17: mp1+perl5.14.diff +Patch18: apache_1.3.42-64bits.patch + + +%description +This package contains a powerful, full-featured, efficient, and +freely-available Web server based on work done by the Apache Software +Foundation. It is also the most popular Web server on the Internet. + +------------------------------------------------------------------------------ +This package is a custom release containing the httpd server (v%{apache_ver}) +bundled with: mod_perl v.%{mod_ssl_ver}, +and mod_ssl v%{mod_ssl_ver}, all BUILT-IN. +------------------------------------------------------------------------------ + + The Apache/Perl integration project brings together the full power +of the Perl programming language and the Apache HTTP server. + With mod_perl it is possible to write Apache modules entirely in Perl. +In addition, the persistent interpreter embedded in the server avoids the +overhead of starting an external interpreter and the penalty of Perl +start-up time. + Mod_SSL provides strong cryptography for the Apache 1.3 webserver +via the Secure Sockets Layer (SSL v2/v3) and Transport Layer Security +(TLSv1) protocols by the help of the Open Source SSL/TLS toolkit OpenSSL. + + +%package devel +Group: Development/Libraries +Summary: Module development tools for apache-mod_ssl +Provides: eapi = %{mod_ssl_ver} +Requires: %{name} = %{version} +Provides: mod_perl-devel = %{mod_perl_ver} +Provides: mod_ssl-devel = %{mod_ssl_ver} +Provides: apache-devel = %{apache_ver} + +%description devel +The apache-devel package contains the APXS binary and other files +that you need to build Dynamic Shared Objects (DSOs) for Apache. +If you are installing the Apache Web server and you want to be able +to compile or develop additional modules for Apache, you need to install +this package. + + +%package manual +Group: Documentation +Summary: Documentation for the Apache Web server + +%description manual +The apache-manual package contains the complete manual and reference +guide for the Apache Web server. +It also contains the basic web content (icons, default welcome messages, +etc) provided with Apache's HTTPD distribution. + + +%prep +%setup -q -c -T -n %{name}-%{version} -a 0 +%setup -q -c -T -D -n %{name}-%{version} -a 1 +%setup -q -c -T -D -n %{name}-%{version} -a 2 +%setup -q -c -T -D -n %{name}-%{version} -a 6 + +pushd %{aname}_%{apache_ver} +%patch0 -p0 -b .sslcfg +%patch1 -p1 -b .config +%patch3 -p0 -b .make +%patch5 -p1 -b .apachectl-init +%ifarch x86_64 +%patch18 -p1 -b .apache-x86_64 +%endif + +#patch12 -p1 -b .dbmdb +%patch13 -p1 -b .compile +%patch15 -p0 -b .ap_getline + + +patch -p0 < ../libapreq-%{libapreq_ver}/patches/apache-1.3+apreq.patch +cp ../libapreq-%{libapreq_ver}/c/*.[ch] src/lib/apreq/ +popd + +pushd mod_ssl-%{mod_ssl_ver}-%{apache_ver} +%patch11 -p1 -b .openssl +%patch14 -p0 -b .stack +%ifarch x86_64 +%patch16 -p1 -b .openssl-x86_64 +%endif +popd + +pushd mod_perl-%{mod_perl_ver} +%patch17 -p1 -b .mp1+perl5.14.diff +popd + +# Substitute values to match the configuration. The first two are +# for the default httpd.conf file, the rest is for the mod_ssl +# additions. +pushd %{aname}_%{apache_ver} +sed -e 's,@@ServerRoot@@,%{_sysconfdir}/%{pname},g' \ + -e 's,@@ContentRoot@@,%{contentdir},g' \ + -e 's,^DocumentRoot "@@ContentRoot@@",#DocumentRoot "%{_sysconfdir}/%{pname}/htdocs",g' \ + -e 's,^,,g' \ + -e 's,^ServerName new.host.name,#ServerName new.host.name,g' \ + -e 's,^ServerAdmin you@your.address,#ServerAdmin you@your.address,g' \ + -e 's,^SSLCipherSuite,#SSLCipherSuite,g' \ + -e 's,^SSLLogLevel info,SSLLogLevel error,g' \ + -e 's,^SSLSessionCache dbm:logs/ssl_scache,SSLSessionCache shm:logs/ssl_scache(512000),g' \ + conf/httpd.conf-dist > conf/httpd.conf +popd + +cp %{SOURCE5} . + +#cp %{_tmppath}/rpm-tmp* /tmp/01prep.sh + +%build +export CFLAGS="$RPM_OPT_FLAGS -fPIC $(pkg-config --cflags openssl)" +export LIBS="-lpthread" +export EAPI_MM=SYSTEM + +############################################### +echo mod_perl ... +pushd mod_perl-%{mod_perl_ver} + perl Makefile.PL CCFLAGS="$RPM_OPT_FLAGS -fPIC" \ + APACHE_SRC=../%{aname}_%{apache_ver}/src \ + DO_HTTPD=1 USE_APACI=1 PREP_HTTPD=1 EVERYTHING=1 + make %{?_smp_mflags} + ## put mod_perl docs in a safe place ;-]~ + mkdir mod_perl-doc + cp -a eg/ faq/ mod_perl-doc/ + cp {CREDITS,LICENSE,README,SUPPORT,STATUS,Changes,INSTALL*} mod_perl-doc/ + cp *.{pod,html,gif} mod_perl-doc/ + find mod_perl-doc -type f -exec chmod 644 {} \; +popd + +############################################### +echo mod_ssl ... +export SSL_COMPAT=yes +export SSL_EXPERIMENTAL=yes +pushd mod_ssl-%{mod_ssl_ver}-%{apache_ver} + ./configure --with-apache=../apache_%{apache_ver} \ + --with-mm=SYSTEM --force +popd + +############################################### +echo apache ... +pushd %{aname}_%{apache_ver} + ./configure \ + --prefix=%{_prefix} \ + --exec-prefix=%{_prefix} \ + --bindir=%{_bindir} \ + --sbindir=%{_sbindir} \ + --mandir=%{_mandir} \ + --sysconfdir=%{_sysconfdir}/%{pname}/conf \ + --libexecdir=%{_libdir}/apache \ + --datadir=%{contentdir} \ + --iconsdir=%{contentdir}/icons \ + --htdocsdir=%{contentdir}/html \ + --manualdir=%{contentdir}/html/manual \ + --cgidir=%{contentdir}/cgi-bin \ + --localstatedir=%{_localstatedir} \ + --runtimedir=%{_sysconfdir}/%{pname}/run \ + --logfiledir=logs \ + --proxycachedir=%{_localstatedir}/cache/%{pname} \ + --with-perl=%{__perl} \ + --enable-rule=EAPI \ + --enable-rule=SSL_COMPAT \ + --enable-rule=SSL_EXPERIMENTAL \ + --disable-rule=SSL_VENDOR \ + --disable-rule=WANTHSREGEX \ + --disable-rule=EXPAT \ + %{?_with_backtrace:--activate-module=src/modules/experimental/mod_backtrace.c} \ + %{?_with_whatkilledus:--activate-module=src/modules/experimental/mod_whatkilledus.c} \ + --activate-module=src/modules/perl/libperl.a \ + --enable-module=auth_dbm \ + --enable-module=ssl \ + --enable-module=all \ + --enable-shared=max \ + --disable-shared=perl \ + --disable-shared=ssl \ + --disable-module=example \ + --disable-module=auth_db \ + --without-execstrip \ + %{?_with_suexec:--enable-suexec --suexec-docroot=%{contentdir}} \ + %{?_with_suexec:--suexec-uidmin=300 --suexec-gidmin=300} \ + %{?_with_suexec:--suexec-umask=022 --suexec-caller=%{suexec_caller}} + + make %{?_smp_mflags} + +popd +#cp %{_tmppath}/rpm-tmp* /tmp/02build.sh + +%install +############################################################################### +### install basic apache stuff +pushd apache_%{apache_ver} + make install root="$RPM_BUILD_ROOT" +popd + +### rename +mv $RPM_BUILD_ROOT%{_sbindir}/httpd $RPM_BUILD_ROOT%{_sbindir}/%{pname} + +### install SYSV init stuff +mkdir -p $RPM_BUILD_ROOT%{_initrddir} +install -m755 %{SOURCE3} $RPM_BUILD_ROOT%{_initrddir}/%{pname} + +### install log rotation stuff +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d +install -m644 %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/apache + +### default rootdir links +mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/%{pname} +pushd $RPM_BUILD_ROOT%{_sysconfdir}/%{pname} + ln -s %{_localstatedir}/log/%{pname} logs + ln -s %{_libdir}/%{aname} modules + ln -s %{_localstatedir}/run run +popd + +### replace Apache's default config file with our patched version +install -m644 apache_%{apache_ver}/conf/httpd.conf \ + $RPM_BUILD_ROOT%{_sysconfdir}/%{pname}/conf/httpd.conf + +# fix up apxs so that it doesn't think it's in the build root +perl -pi -e "s^$RPM_BUILD_ROOT^^g" $RPM_BUILD_ROOT%{_sbindir}/apxs + +# fixup the documentation file naming +find $RPM_BUILD_ROOT%{contentdir} -name "*.html.html" | xargs rename .html.html .html + +############################################################################### +### install mod_perl files +pushd mod_perl-%{mod_perl_ver} + export PERL_INSTALL_ROOT=$RPM_BUILD_ROOT + make pure_install PREFIX=/usr INSTALLDIRS=vendor + + # convert man pages to UTF-8 + recode() { + iconv -f "$2" -t utf-8 < "$1" > "${1}_" + %{__mv} -f "${1}_" "$1" + } + pushd $RPM_BUILD_ROOT/usr/share/man/man3/ + for i in * ; do + recode "${i}" iso-8859-1 + done + popd + + # fix files mod + find $RPM_BUILD_ROOT%{perl_vendorarch} -iname '*.pm' -exec chmod 0644 {} \; + + # bake web docs... + mkdir -p $RPM_BUILD_ROOT%{contentdir}/html/manual/mod/mod_perl + install -c -m 644 htdocs/manual/mod/mod_perl.html \ + $RPM_BUILD_ROOT%{contentdir}/html/manual/mod/mod_perl/ + make -C faq + rm -f faq/pod2htm* + install -m644 faq/*.html \ + $RPM_BUILD_ROOT%{contentdir}/html/manual/mod/mod_perl/ + +popd + +# remove special perl files this is specific for rpms , already have in own .packlist +find $RPM_BUILD_ROOT%{perl_vendorarch}/.. -name perllocal.pod -o -name .packlist \ + -o -name '*.bs' | xargs -r -i rm -f {} + +### ssl leftovers +# point to the right makefile. +ln -sf ../../../etc/pki/tls/certs/Makefile $RPM_BUILD_ROOT%{_sysconfdir}/%{pname}/conf +# create a prototype session cache +touch $RPM_BUILD_ROOT%{_localstatedir}/cache/ssl_gcache_data.{dir,pag,sem} + +# drop shellbang from .exp files +for exp in $RPM_BUILD_ROOT%{perl_vendorarch}/auto/Apache/mod_perl.exp $RPM_BUILD_ROOT%{_libdir}/%{aname}/httpd.exp +do + sed -i '/^#!/ d' $exp +done + +#cp %{_tmppath}/rpm-tmp* /tmp/03install.sh + +%post +/sbin/chkconfig --add %{pname} +/sbin/ldconfig + +# safely build a test certificate +umask 077 +if [ ! -f %{_sysconfdir}/%{pname}/conf/ssl.key/server.key ] ; then +openssl genrsa -rand /proc/apm:/proc/cpuinfo:/proc/dma:/proc/filesystems:/proc/interrupts:/proc/ioports:/proc/pci:/proc/rtc:/proc/uptime 1024 > %{_sysconfdir}/%{pname}/conf/ssl.key/server.key 2> /dev/null +fi + +if [ ! -f %{_sysconfdir}/%{pname}/conf/ssl.crt/server.crt ] ; then +cat << EOF | openssl req -new -key %{_sysconfdir}/%{pname}/conf/ssl.key/server.key -x509 -days 365 -out %{_sysconfdir}/%{pname}/conf/ssl.crt/server.crt 2>/dev/null +-- +SomeState +SomeCity +SomeOrganization +SomeOrganizationalUnit +localhost.localdomain +root@localhost.localdomain +EOF +fi + +# safely add .htm to mime types if it is not already there +[ -f %{_sysconfdir}/mime.types ] || exit 0 +TEMPTYPES=`/bin/mktemp /tmp/mimetypes.XXXXXX` +[ -z "$TEMPTYPES" ] && { + echo "could not make temporary file, htm not added to %{_sysconfdir}/mime.types" >&2 + exit 1 +} +( grep -v "^text/html" %{_sysconfdir}/mime.types + types=$(grep "^text/html" %{_sysconfdir}/mime.types | cut -f2-) + echo -en "text/html\t\t\t" + for val in $types ; do + if [ "$val" = "htm" ] ; then + continue + fi + echo -n "$val " + done + echo "htm" +) > $TEMPTYPES +cat $TEMPTYPES > %{_sysconfdir}/mime.types && /bin/rm -f $TEMPTYPES + +cp %{_tmppath}/rpm-tmp* /tmp/04post.sh + +%pre +# Add the "apache" user +/usr/sbin/useradd -c "Apache" -u 48 \ + -s /sbin/nologin -r -d "%{contentdir}" apache 2> /dev/null || : + +%preun +if [ $1 = 0 ]; then + if [ -f /var/lock/subsys/%{pname} ]; then + %{_initrddir}/%{pname} stop + fi + if [ -f %{_initrddir}/%{pname} ]; then + /sbin/chkconfig --del %{pname} + fi +fi + +%files +%defattr(-,root,root) +%dir %{_sysconfdir}/%{pname} +%dir %{_sysconfdir}/%{pname}/conf +%config(noreplace) %{_sysconfdir}/%{pname}/conf/*.conf +%config(noreplace) %{_sysconfdir}/%{pname}/conf/Makefile +%config(noreplace) %{_sysconfdir}/%{pname}/conf/magic +%config(noreplace) %{_sysconfdir}/%{pname}/conf/mime.types +%config(noreplace) %{_sysconfdir}/logrotate.d/* +%config(noreplace) %{_sysconfdir}/%{pname}/conf/ssl.* +%doc %{_sysconfdir}/%{pname}/conf/*.default +%attr(755,root,root) %{_initrddir}/* +%{_sysconfdir}/%{pname}/logs +%{_sysconfdir}/%{pname}/modules +%{_sysconfdir}/%{pname}/run +%{_libdir}/%{aname} +%{perl_vendorarch}/Apache +%{perl_vendorarch}/Bundle +%{perl_vendorarch}/*.pm +%{perl_vendorarch}/*.PL +%dir %{perl_vendorarch}/auto/Apache +%{perl_vendorarch}/auto/Apache/Leak +%{perl_vendorarch}/auto/Apache/Symbol +%{perl_vendorarch}/auto/Apache/mod_perl.exp +%{perl_vendorarch}/auto/Apache/typemap +%attr(0755,root,root) %{_bindir}/* +%attr(0755,root,root) %{_sbindir}/ab +%attr(0755,root,root) %{_sbindir}/apachectl +%attr(0755,root,root) %{_sbindir}/httpd13 +%attr(0755,root,root) %{_sbindir}/logresolve +%attr(0755,root,root) %{_sbindir}/rotatelogs +%{?_with_suexec:%attr(4710,root,%{suexec_caller}) %{_sbindir}/suexec} +%{_mandir}/man1*/* +%{_mandir}/man8/ab.8* +%{_mandir}/man8/apachectl.8* +%{_mandir}/man8/httpd.8* +%{_mandir}/man8/logresolve.8* +%{_mandir}/man8/rotatelogs.8* +%{?_with_suexec:%{_mandir}/man8/suexec.8*} +%attr(0755,apache,root) %dir %{_localstatedir}/cache/%{pname} +%attr(0640,apache,root) %{_localstatedir}/cache/ssl_* +%attr(0750,root,apache) %dir %{_localstatedir}/log/%{pname} + + +%files devel +%defattr(-,root,root) +%{_includedir} +%attr(0755,root,root) %{_sbindir}/apxs +%{_mandir}/man8/apxs.8* +%doc %{perl_vendorarch}/*.pod +%{perl_vendorarch}/auto/Apache/include + +%files manual +%defattr(-,root,root) +%doc apache_%{apache_ver}/cgi-bin +%dir %{contentdir} +%dir %{contentdir}/cgi-bin +%config(noreplace) %{contentdir}/cgi-bin/* +%dir %{contentdir}/html +%config(noreplace) %{contentdir}/html/*.html* +%config(noreplace) %{contentdir}/html/*.gif +%dir %{contentdir}/icons +%dir %{contentdir}/icons/small +%config(noreplace) %{contentdir}/icons/*.* +%config(noreplace) %{contentdir}/icons/small/*.* +%doc %{contentdir}/icons/README + +%doc apache_%{apache_ver}/{ABOUT_APACHE,LICENSE*,NOTICE,README*,cgi-bin} +%doc apache_%{apache_ver}/src/{CHANGES,README}* +%doc mod_ssl-%{mod_ssl_ver}-%{apache_ver}/README.* +%doc mod_ssl-%{mod_ssl_ver}-%{apache_ver}/NEWS +%doc mod_perl-%{mod_perl_ver}/mod_perl-doc +%doc SSL-Certificate-Creation + +%doc %{contentdir}/html/manual +%exclude %{contentdir}/html/manual/mod/mod_ssl/ssl_cover.wml +#man3 conflicts with mod_perl2 +/usr/share/man/man3*/* + + +%changelog +* Sun May 13 2012 Sérgio Basto - 1.3.42-4 +- Many improvements on defaults directories +- Separate libapreq in other package, to compile libapreq is need other sources installed. +- more cleanups. + +* Wed Nov 16 2011 Sérgio Basto +- build for F16 +- mp1+perl5.14.diff (mod_perl1 + perl5.14) +- many improvents. + +* Sat Oct 29 2011 Sérgio Basto +- mock build add many buildrequires +- many improvemts on confs + +* Tue Oct 16 2007 Sérgio Basto +- UNDROPPED CONFIGURATION COMPLETELY: rpm it suposed do all alone. +- rename httpd to http13 to work independently of apache 2.2 +- add patch to Makefile.tmp, resolve all problems at once +- change server port number to run out of the box. +- Update link to certs/Makefile. + +* Tue Sep 11 2007 Marius FERARU - 1.3.39-1.n0i.23.MPSSL +- apache 1.3.39 +- mod_ssl 2.8.29 + +* Mon Apr 02 2007 Marius FERARU - 1.3.37-3.n0i.22.MPSSL +- mod_perl 1.30 +- initscript: use a "$pidfile" variable for all operations +- initscript: added a dummy "alias" for "reload" (will do a 'restart'!) +- initscript: added missing "fullstatus" option (will run through "apachectl") +- dropped shellbang from .exp files +- dropped 2 explicit provides (mod_perl and Apache::Constants) + +* Fri Sep 08 2006 Marius FERARU - 1.3.37-2.n0i.21.MPSSL +- BR: gdbm-devel, db4-devel + +* Mon Aug 21 2006 Marius FERARU - 1.3.37-1.n0i.20.MPSSL +- apache 1.3.37 +- mod_ssl 2.8.28 +- Dist macro +- URL update +- updated description +- spec cleanups +- use "--with backtrace" to activate "mod_backtrace" +- use "--with whatkilledus" to activate "mod_whatkilledus" +- use "--with suexec" to activate suexec functionality +- moved default web content into documentation package + +* Tue Jun 06 2006 Marius FERARU - 1.3.36-2.n0i.19.MPSSL +- changed "runtimedir" and "logfiledir" to relative paths, + letting users run apache on their own + +* Tue Jun 06 2006 Marius FERARU - 1.3.36-1.n0i.19.MPSSL +- apache 1.3.36 +- mod_ssl version 2.8.27 +- spec cleanups + +* Mon Mar 13 2006 Marius FERARU - 1.3.34-2.n0i.18.MPSSL +- rebuild + +* Thu Nov 24 2005 Marius FERARU 1.3.34-1.n0i.17.MPSSL +- apache 1.3.34 +- mod_ssl version 2.8.25 + +* Tue Sep 20 2005 Marius FERARU 1.3.33-5.n0i.16.MPSSL +- mod_ssl version 2.8.24 + +* Fri Sep 02 2005 Marius FERARU 1.3.33-4.n0i.15.MPSSL +- rebuild +- dropped more requirements (which Fedora considers to "always have") + +* Sat Jul 23 2005 Marius FERARU 1.3.33-3.n0i.14.MPSSL +- dropped Epoch +- changed Summary and Description +- rebuild (perl 5.8.7) + +* Tue Jan 04 2005 Marius FERARU 1.3.33-2.n0i.13.MPSSL +- libapreq version 1.33 + +* Mon Dec 06 2004 Marius FERARU 1.3.33-1.n0i.12.MPSSL +- apache version 1.3.33 +- mod_ssl version 2.8.22 +- description update + +* Tue Aug 17 2004 Marius FERARU 1.3.31-5.n0i.11.MPSSL +- mod_ssl version 2.8.19 + +* Thu Jul 15 2004 Marius FERARU 1.3.31-4.n0i.10.MPSSL +- mod_ssl version 2.8.18 + +* Tue Jul 13 2004 Marius FERARU 1.3.31-3.n0i.9.MPSSL +- tweaked rotatelog's build: drop linking with apache libs + +* Tue Jul 13 2004 Marius FERARU 1.3.31-2.n0i.8.MPSSL +- applied some fixing patches from current CVS version + +* Thu May 13 2004 Marius FERARU 1.3.31-1.n0i.7.MPSSL +- apache version 1.3.31 +- mod_ssl version 2.8.17 +- updated apxs patch +- slight spec tweaks +- enabled backtrace experimental module +- updated config patch + +* Fri Apr 30 2004 Marius Feraru 1.3.29-6.n0i.6.MPSSL +- automatic rebuild + +* Thu Apr 22 2004 Marius FERARU 1.3.29-5.n0i.5.MPSSL +- rebuild (perl 5.8.4) + +* Tue Feb 10 2004 Marius FERARU 1.3.29-4.n0i.4.MPSSL +- fixed the shameful bugs from my httpd.init script + +* Fri Jan 23 2004 Marius FERARU 1.3.29-3.n0i.3.MPSSL +- rebuild (perl 5.8.3) + +* Fri Jan 16 2004 Marius FERARU 1.3.29-2.n0i.2.MPSSL +- rebuilt on perl 5.8.2 / Fedora 1 Devel (tobe FC2) +- finally clearly enabled modperl.c in apache_1.3.23-config.patch +as many helpless people seem to use this dumb default configuration file :( +- also updated the same patch to properly define SSL too :) +- added a lame "MPSSL" extra tag in release to make people understand this +is a !SPECIAL! apache + mod_perl + mod_ssl + libapreq package suite!!! +- updated init script to do "real" server shutdown (in squid style) and to NOT +shutdown all the apache servers, just the one started with /var/run/httpd.pid +- added USE_MODULEARGS=[yes/no] and SHUTDOWN_TIMEOUT=[seconds] configuration +parameters to init script + +* Thu Nov 13 2003 Marius FERARU 1.3.29-1.n0i.1 +- apache 1.3.29 +- modssl 2.8.16 +- dropped zombie patch +- dropped fderr patch +- dropped for good thttpd conflict note as THERE IS NO CONFLICT!!! In fact +we really use them both for long time without a problem :)) +- added more Prereq stuff +- more Fedora style spec updates + +* Thu Oct 16 2003 Marius FERARU 1.3.28-2.n0i +- mod_perl 1.29 +- libapreq 1.3 +- replaced ALL direct 'etc' occurences to macros (some for other stuff) +- perl %%files are now more properly quested. +- switched krb5-config to pkg-config +- switched textutils to coreutils +- using mm 1.3 +- disabled internal expat linking +- added the 'zombie' patch +- added the 'file descriptors are erroneously closed' patch + +* Mon Jul 28 2003 Marius FERARU 1.3.28-1.n0i +- mod_perl 1.28 +- added builtin libapreq + +* Fri Jul 25 2003 Marius FERARU 1.3.28-0.n0i +- apache version 1.3.28 +- mod_ssl version 2.8.15 +- switched the old dbm-gdbm patch with a more elegant one (apache_1.3.27-db); +yet, more tests are to be done on other systems before dropping the old one +from our src.rpm +- disabled suexec SSL env support patch as Apache ppl changed their code heavily +and I do not yet have time to update this patch +- moved mod_perl header files into apache-devel (are they needed by someone?!) +- dropped using RPM_SOURCE_DIR/ stuff. +- disabled auth_db module (db4 API changes?!) + +* Mon Apr 21 2003 Marius FERARU 1.3.27-2.n0i +- automatic rebuild on RHL9 + +* Wed Mar 26 2003 Marius FERARU 1.3.27-1.n0i +- mod_ssl version 2.8.14 +- dropped thttpd conflict note as THERE IS NO CONFLICT!!! In fact we really +use them both :)) + +* Fri Oct 18 2002 Marius Feraru +- apache version 1.3.27 +- mod_ssl version 2.8.11 +- eliminated db4 patch +- disabled thttpd conflict flag + +* Tue Sep 24 2002 Marius Feraru +- automatic rebuild (to conform with the openssl update) + +* Wed Sep 4 2002 Marius Feraru +- some spec cleanups (rpm 4.1.x compatibility) + +* Tue Jul 23 2002 Marius FERARU +- apache 1.3.26 +- mod_perl 1.27 +- mod_ssl 2.8.10 +- lots of new tweaks to the spec file (hopefully it will be easier now for others to +rebuild this package =] ) + + +* Sat Sep 1 2001 Marius FERARU +- updated apache to 1.3.22 +- reparsed and tweaked all RedHat patches +- lots of spec file tweaks: optimisations, + file location/integration/modes fixes... + +* Sat Sep 1 2001 Marius FERARU +- updated mod_perl to version 1.26 +- based on apache-1.3.20-15.src.rpm from Red Hat RawHide +- used apache_modperl-1.3.19-1.24-1.src.rpm from + perl.apache.org as example spec. diff --git a/samples/RPM Spec/erlang-erlydtl.spec b/samples/RPM Spec/erlang-erlydtl.spec new file mode 100644 index 00000000..eea3fb2b --- /dev/null +++ b/samples/RPM Spec/erlang-erlydtl.spec @@ -0,0 +1,62 @@ +%global debug_package %{nil} + +Name: erlang-erlydtl +Version: 0.6.0 +Release: 1%{?dist} +Summary: Erlang implementation of the Django Template Language. + +Group: Development/Libraries +License: MIT +URL: http://code.google.com/p/erlydtl/ +Source0: http://erlydtl.googlecode.com/files/erlydtl-0.6.0.tar.gz +Patch0: erlang-erlydtl-0.6.0-tests.patch +Patch1: erlang-erlydtl-0.6.0-r14a.patch +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +Provides: ErlyDTL = %{version}-%{release} +BuildRequires: erlang +Requires: erlang + +%description +ErlyDTL is an Erlang implementation of the Django Template Language. The +erlydtl module compiles Django Template source code into Erlang bytecode. The +compiled template has a "render" function that takes a list of variables and +returns a fully rendered document + +%prep +%setup -q -n erlydtl-%{version} +find examples/ -type f -executable -exec chmod -x {} \; + +%patch0 -p0 +%patch1 -p0 + +%build +make %{?_smp_mflags} + +%check +make test + + +%install +rm -rf %{buildroot} +mkdir -p %{buildroot}/%{_libdir}/erlang/lib/erlydtl-%{version}/ +cp -r ebin %{buildroot}/%{_libdir}/erlang/lib/erlydtl-%{version}/ +cp -r bin %{buildroot}/%{_libdir}/erlang/lib/erlydtl-%{version}/ +cp -r priv %{buildroot}/%{_libdir}/erlang/lib/erlydtl-%{version}/ + + +%clean +rm -rf %{buildroot} + + +%files +%defattr(-,root,root,-) +%dir %{_libdir}/erlang/lib/erlydtl-%{version} +%{_libdir}/erlang/lib/erlydtl-%{version}/* +%doc README +%doc examples + + +%changelog +* Sun Aug 1 2010 Ilia Cheishvili - 0.6.0-1 +- Initial Package diff --git a/samples/RPM Spec/manos.spec b/samples/RPM Spec/manos.spec new file mode 100644 index 00000000..5674d3ce --- /dev/null +++ b/samples/RPM Spec/manos.spec @@ -0,0 +1,46 @@ +# +# spec file for package manos +# +# Copyright (c) 2010 Jackson Harper (jackson@novell.com) +# +# + +Name: manos-devel +Version: 0.1.1 +Release: 1 +License: MIT/X11 +BuildRoot: %{_tmppath}/manos-%{version}-build +BuildRequires: mono-devel >= 2.6 +BuildRequires: mono-nunit >= 2.6 +Source0: manos-%{version}.tar.bz2 +Source1: rpmlintrc +Summary: The Manos Web Application Framework +Group: Development/Web/Servers +BuildArch: noarch + +%description +Manos is an easy to use, easy to test, high performance web application framework that stays out of your way and makes your life ridiculously simple. + +%files +%defattr(-, root, root) +%{_prefix}/lib/manos +%{_bindir}/manos +%{_datadir}/manos +%{_prefix}/lib/pkgconfig/manos.pc +%{_datadir}/man/man1/manos.1.gz + +%prep +%setup -q -n manos-%{version} + + +%build +./configure --prefix=%{buildroot}%{_prefix} --install-prefix=%{_prefix} +make + +%install +make install + +%clean +rm -rf %{buildroot} + +%changelog \ No newline at end of file diff --git a/samples/RUNOFF/VMS_ZIP.RNH b/samples/RUNOFF/VMS_ZIP.RNH new file mode 100644 index 00000000..183ceeac --- /dev/null +++ b/samples/RUNOFF/VMS_ZIP.RNH @@ -0,0 +1,1467 @@ +.! +.! File: ZIP.RNH +.! +.! Author: Hunter Goatley +.! +.! Date: October 22, 1991 +.! +.! Description: +.! +.! RUNOFF source file for portable ZIP on-line help for VMS. +.! Adapted from MANUAL, distributed with ZIP. +.! +.! To build: $ RUNOFF ZIP.RNH +.! $ LIBR/HELP/INSERT libr ZIP +.! +.! Modification history: +.! +.! Hunter Goatley 22-OCT-1991 20:45 +.! Genesis. +.! Jean-loup Gailly 25 March 92 +.! Adaptation to zip 1.6. +.! Igor Mandrichenko 9-JUN-1992 +.! Added explanation of -V option. +.! Jean-loup Gailly 14 June 92 +.! Adaptation to zip 1.8. +.! Jean-loup Gailly 20 Aug 92 +.! Adaptation to zip 1.9. +.! Jean-loup Gailly 31 Aug 93 +.! Adaptation to zip 2.0. +.! Christian Spieler 20 Sep 93 +.! Adaptation to zip 2.0 and OpenVMS completed. +.! Christian Spieler 05 Dec 95 +.! Adaptation to zip 2.1, new options. +.! Christian Spieler 20 Jan 96 +.! Changed -L and -v descriptions. +.! Christian Spieler 11 Feb 96 +.! Added -X option. +.! Onno van der Linden, +.! Christian Spieler 13 Mar 96 +.! Removed -ee option. +.! Christian Spieler 09 Feb 96 +.! Updated copyright notice, Zip version. +.! Christian Spieler 21 Jul 97 +.! Added -P, -R, -i@, -x@ and -tt options, modified for Zip 2.2. +.! Christian Spieler 14 Oct 97 +.! unified spelling of "Info-ZIP", final cleanups for 2.2. +.! Steven Schweda 10 May 2007 +.! General update for version 3.0. +.! Ed Gordon 12 May 2007 +.! Minor updates for version 3.0. +.! +.noflags +.lm4 .rm72 +.indent -4 +1 ZIP +.br +Zip is a compression and file packaging utility for several operating +systems, including UNIX, VMS, MSDOS, OS/2, Windows 9x/NT/XP, Minix, Atari, +Macintosh, Amiga, and Acorn RISC OS. It is analogous to a combination of +tar and compress and is compatible with PKZIP (Phil Katz's ZIP) for +MSDOS systems. +.sk +Zip is useful for packaging a set of files for distribution, for +archiving files, and for saving disk space by temporarily compressing +unused files or directories. A companion program, UnZip, unpacks Zip +archives. +.sk +For brief help on Zip or UnZip, run the program without specifying any +parameters on the command line. +.sk +This description covers the Zip program which uses a UNIX-style command +line. A separate program is available which provides a VMS-style CLI +command line, and it has its own documentation. Refer to the Zip +installation instructions for details. +.sk +Format +.sk;.lm+2;.literal +ZIP [-options] archive inpath inpath ... +.end literal;.lm-2 +.!------------------------------------------------------------------------------ +.indent -4 +2 Basic_Usage +.br +Format +.sk;.lm+2;.literal +ZIP [-options] archive inpath inpath ... +.end literal;.lm-2 +.sk +The default action of Zip is to add or replace entries in "archive" from +the list of "inpath" file specifications, which can include directories +and file names with VMS-style wildcards, or the special name -@ to read +file specifications from SYS$INPUT (stdin). +.sk +With SET PROCESS /PARSE_STYLE = EXTENDED (available on recent non-VAX +systems), Zip preserves the case of the command line. Otherwise, mixed- +or upper-case options and arguments must be quoted. For example, +"-V". Examples in this document generally do not show this quotation, +so VAX and /PARSE_STYLE = TRADITIONAL users (that is, troglodytes) will +need to add quotation where needed when working with these examples. +.sk +General +.sk +Zip reads one or more files, compresses the data (normally), and stores +the compressed information into a single Zip archive file, along with +information about each file (name, path, date and time of last +modification, protection, and check information to verify file +integrity). On a VMS system, Zip can also save VMS/RMS file attributes, +allowing UnZip to restore the files without loss of important file +attributes. Zip can pack an entire directory structure into a Zip +archive with a single command. +.sk +Compression +.sk +Compression ratios of 2:1 to 3:1 are common for text files. Zip has one +standard compression method ("deflate") and can also store files without +compression. Zip (and UnZip) may be built with optional support for the +bzip2 compression method. Then, the user may select bzip2 compression +instead of the default "deflate" method. Zip automatically chooses +simple storage over compression for a file, if the specified compression +method does not actually compress the data in that file. +.sk +Compatibility +.sk +Zip and UnZip can work with archives produced by PKZIP (supporting most +PKZIP features up to PKZIP version 4.6), and PKZIP and PKUNZIP can work +with archives produced by Zip (with some exceptions, notably streamed +archives, but recent changes in the .ZIP file standard may facilitate +better compatibility). Zip version 3.0 is compatible with PKZIP 2.04 +and also supports the Zip64 extensions of PKZIP 4.5 which allows +archives as well as files to exceed the previous 2 GB limit (4 GB in +some cases). Zip also supports bzip2 compression if the bzip2 library +is included when Zip is built. Note that PKUNZIP 1.10 cannot extract +files produced by PKZIP 2.04 or Zip 3.0. You must use PKUNZIP 2.04g or +UnZip 5.0p1 (or later versions) to extract them. +.sk +Large Archives and Zip64 +.sk +Where the operating system and C run-time support allow, Zip 3.0 and +UnZip 6.0 (and later versions) support large files (input and archive), +using the Zip64 extensions to the original .ZIP file format. On VMS, +this genarally means non-VAX systems with VMS V7.2 or later (perhaps +requiring a C RTL ECO before VMS V7.3-2). +.sk +Zip automatically uses the Zip64 extensions when a file larger than 2 GB +is added to an archive, an archive containing a Zip64 entry is updated +(if the resulting archive still needs Zip64), the size of the archive +will exceed 4 GB, or when the number of entries in the archive will +exceed about 64K. Zip64 is also used for archives streamed to a +non-seekable output device. You must use a 4.5 compatible UnZip to +extract files using the Zip64 extensions such as UnZip 6.0 or later. +.sk +In addition, streamed archives, entries encrypted with standard +encryption, or split archives created with the pause option may not be +compatible with PKZIP as data descriptors are used, and PKZIP at the +time of this writing does not support data descriptors (but recent +changes in the PKWare published .ZIP file standard now include some +support for the data descriptor format Zip uses). +.!------------------------------------------------------------------------------ +.indent -4 +2 More_Usage +.br +Here is a very simple example of Zip use: +.sk;.indent 10; +$ zip stuff.zip *.* +.sk +This will create the Zip archive "stuff.zip" (assuming it does not +already exist) and put all the (non-directory) files (";0") from the +current default directory into "stuff.zip" in a compressed form. The +archive is opened using a default file specification of +"SYS$DISK:[].zip", so specifying "stuff" as the archive name would also +create (or use an existing) "stuff.zip", but specifying "stuff.other" +would give you that name. In general, Zip doesn't care about the type +in the file specification, but for split archives (archives split over +multiple files), the user should normally specify a type-less name, +because Zip will normally generate sequentially numbered types ".z01", +".z02", and so on for the early splits, and then the required ".zip" for +the last split. These file types are required by the Zip standard for +split archives. +.sk +Standard VMS wildcard expansion ($SEARCH) is used to interpret the +"inpath" file and directory specifications, like the "*.*" in this +example. +.sk +On VMS, the most natural way to archive an entire directory tree is to +use a directory-depth wildcard ("[...]"). For example: +.sk;.indent 10 +zip foo [...]*.* +.sk +This will create the file "foo.zip" containing all the files (";0") and +directories in and below the current default directory. A more +UNIX-like way to do this would be to use the -r (--recurse-paths) +option: +.sk;.indent 10 +$ zip -r foo *.* +.sk +Zip avoids including its own output files when selecting files to +include in the archive, so it should be safe, as in this case, to create +the archive in the same drectory as the input files. +.sk +One or more specific files, directories, or subdirectories may also be +specified: +.lm +10;.literal +zip foo.zip readme.txt [www...]*.* [.ftp...]*.* - + [.src]*.h [.src]*.c +.end literal;.lm -10 +.sk +For security reasons, paths in Zip archives are always stored as +relative paths, so some care is needed when creating an archive so that +it will create the intended directory structure when UnZip is used to +unpack it. +.sk +To use -r with a specific directory, the name of the directory file +itself must be specified: +.sk;.indent 10 +zip -r foo.zip [000000]www.dir ftp.dir +.sk +You may want to make an archive that contains the files in [.foo], but not +record the directory name, "foo". You can use the -j (junk path) option +to leave off the path: +.sk;.indent 10 +$ zip -j foo [.foo]*.* +.sk +If you are short on disk space, you might not have enough room to hold +both the original directory and the corresponding compressed Zip +archive. In this case, you can create the archive in steps, and use the +-m option. For example, if [.foo] contains the subdirectories [.tom], +[.dick], and [.harry], you could: +.sk +.lm +10;.literal +zip -m foo [.foo.tom...]*.* +zip -m foo [.foo.dick...]*.* +zip -m foo [.foo.harry...]*.* +.end literal;.lm -10 +.sk +The first command would create foo.zip, and the next two would add to +it. The -m option means "move", and it will cause Zip to delete all +files added to the archive after making or updating foo.zip. No +deletions will be done until the Zip operation has completed with no +errors. This option is obviously dangerous and should be used with +care, but it does reduce the need for free disk space. When -m is +used, the -T option is recommended and will test the resulting archive +before deleting the input files. +.sk +If a file specification list is too long to fit conveniently on the Zip +command line, the -@ option can be used to cause Zip to read a list of +file specifications from SYS$INPUT (stdin). If a DCL command procedure +is used, the names can be specified in the procedure: +.sk; +.lm +10;.literal +$ zip foo -@ +$ deck +file_spec_1 +file_spec_2 +file_spec_3 +$ eod +.end literal;.lm -10 +.sk +The file specifications can also be put into a separate file, and fed +into Zip by explicitly defining SYS$INPUT, or by using PIPE. For +example, with the list in foo.zfl: +.sk; +.lm +10;.literal +$ define /user_mode sys$input foo.zfl +$ zip foo -@ +.end literal;.lm -10; +or: +.lm +10;.literal +$ pipe type foo.zfl | zip foo -@ +.end literal;.lm -10 +.sk +If Zip is not able to read a file, it issues a warning but continues. +See the -MM option for more on how Zip handles patterns that are not +matched and files that are not readable. If some files were skipped, a +warning is issued at the end of the Zip operation noting how many files +were read and how many skipped. +.!------------------------------------------------------------------------------ +.indent -4 +2 Comments +.br +One-line comments may be included in the archive for each file added, +using the -c (--entry-comments) option. File operations (adding, +updating) are done first, and the user is then prompted for a one-line +comment for each file added or updated. Enter the comment followed by +, or just for no comment. +.sk +A single multi-line comment may be included for the archive as a whole, +using the -z (--archive-comment) option. UnZip (including UnZip SFX) +will display this comment when it expands the archive. The comment is +read from SYS$INPUT (stdin), and is terminated by the usual end-of-file +character, CTRL/Z. As usual, in a DCL command procedure, these data can +be included in-line in the procedure, or a user may DEFINE SYS$INPUT to +a file to get the comment from that file. Where supported, the DCL PIPE +command can also be used to redirect SYS$INPUT from a file. +.sk +Note that -z (--archive-comment) and -@ (read file specifications from +SYS$INPUT (stdin)) can't be used together (successfully). +.!------------------------------------------------------------------------------ +.indent -4 +2 Compression +.br +Zip can archive files with or without compression. The standard +compression method ("deflate") is compatible with all UnZip versions +(except really old ones that only understand the "store" method). +Current Zip and UnZip versions may be built with optional support for +the bzip2 compression method. (The bzip2 method can compress better, +especially when compressing smaller files, but uses more CPU time, and +requires an UnZip which includes the optional bzip2 support. See the +installation instructions for details on adding bzip2 compression +support at build time.) +.sk +Numeric compression level options control the effort put into data +compression, with -1 being the fastest, and -9 giving the most +compression. +.sk +Compression control options: +.sk;.lm +10;.literal +-Z mthd use compress method "mthd", +--compression-method mthd "bzip2" or "deflate" (default) + +-0 (--store) no compression +-1 (--compress-1) compression level 1 +-2 (--compress-2) compression level 2 +-3 (--compress-3) compression level 3 +-4 (--compress-4) compression level 4 +-5 (--compress-5) compression level 5 +-6 (--compress-6) compression level 6 +-7 (--compress-7) compression level 7 +-8 (--compress-8) compression level 8 +-9 (--compress-9) compression level 9 +.end literal;.lm -10 +.sk +Normally, a file which is already compressed will not be compressed much +further (if at all) by Zip, and trying to do it can waste considerable +CPU time. Zip can suppress compression on files with particular types, +specified as a colon- or semi-colon-separated list of file types: +.sk;.indent 10 +-n type1[:type2[...]] (--suffixes type1[:type2[...]]) +.sk +For example: +.sk;.indent 10 +zip -n .bz2:.gz:.jpeg:.jpg:.mp3:.zip foo [.foo]*.* +.sk +will put everything (";0") from [.foo] into foo.zip, but will store any +files that end in .bz2, .gz, .jpeg, .jpg, .mp3, or .zip, without trying +to compress them. +.sk +The default type list is .Z:.zip:.zoo:.arc:.lzh:.arj, and the comparison +is case-insensitive. +.sk +-9 (--compress-9) will override -n (--suffixes), causing compression to +be attempted for all files. +.!------------------------------------------------------------------------------ +.indent -4 +2 Encryption +.br +Zip offers optional encryption, using a method which by modern standards +is generally considered to be weak. +.sk;.literal +-e --encrypt +.end literal;.br +Encrypt new or updated archive entries using a password which is +supplied by the user interactively on the terminal in response to a +prompt. (The password will not be echoed.) If SYS$COMMAND is not a +terminal, Zip will exit with an error. The password is verified before +being accepted. +.sk;.literal +-P password --password password +.end literal;.br +Use "password" to encrypt new or updated archive entries (if any). +USING -P IS INSECURE! Many multi-user operating systems provide ways +for any user (or a privileged user) to see the current command line of +any other user. Even on more secure systems, there is always the threat +of over-the-shoulder peeking. Storing the plaintext password as part of +a command line in a command procedure is even less secure. Whenever +possible, use the non-echoing, interactive password entry method. +.sk +Because standard Zip encryption is weak, where security is truly +important, use a strong encryption program, such as Pretty Good Privacy +(PGP) or GNU Privacy Guard (GnuPG), on an archive instead of standard +Zip encryption. A stronger encryption method, such as AES, is planned +for Zip 3.1. +.!------------------------------------------------------------------------------ +.indent -4 +2 Exit_Status +.br +On VMS, Zip's UNIX-style exit values are mapped into VMS-style status +codes with facility code 1955 = %x7A3, and with the inhibit-message +(%x10000000) and facility-specific (%x00008000) bits set: +.sk +.literal + %x17A38001 normal exit + %x17A38000+ 16* Zip_error_code warnings + %x17A38002+ 16* Zip_error_code normal errors + %x17A38004+ 16* Zip_error_code fatal errors +.end literal +.sk +Note that multiplying the UNIX-style Zip error code by 16 places it +conveniently in the hexadecimal representation of the VMS exit code, +"__" in %x17A38__s, where "s" is the severity code. For example, a +truncated archive might cause Zip error code 2, which would be +transformed into the VMS exit status %x17A38024. +.sk +The Zip VMS exit codes include severity values which approximate those +defined by PKWARE, as shown in the following table: +.literal + + VMS Zip err + severity code Error description + ----------+---------+---------------------------------------------- + Success 0 Normal; no errors or warnings detected. + Fatal 2 Unexpected end of archive. + Error 3 A generic error in the archive format was + detected. Processing may have completed + successfully anyway; some broken archives + created by other archivers have simple work- + arounds. + Fatal 4 Zip was unable to allocate memory for one or + more buffers during program initialization. + Fatal 5 A severe error in the archive format was + detected. Processing probably failed imme- + diately. + Error 6 Entry too large to be split with zipsplit. + Error 7 Invalid comment format. + Fatal 8 Zip -T failed or out of memory. + Error 9 The user aborted zip prematurely with con- + trol-C (or equivalent). + Fatal 10 Zip encountered an error while using a temp + file. + Fatal 11 Read or seek error. + Warning 12 Zip has nothing to do. + Error 13 Missing or empty zip file. + Fatal 14 Error writing to a file. + Fatal 15 Zip was unable to create a file to write to. + Error 16 Bad command line parameters. + Error 18 Zip could not open a specified file to read. + Fatal 19 Zip was built with options not supported on + this system + Fatal 20 Attempt to read unsupported Zip64 archive +.end literal +.!------------------------------------------------------------------------------ +.indent -4 +2 Extra_Fields +.br +The .ZIP file format allows some extra data to be stored with a file in +the archive. For example, where local time zone information is +available, Zip can store UTC date-time data for files. (Look for +USE_EF_UT_TIME in a "zip -v" report.) On VMS, with -V or -VV, Zip will +also store VMS-specific file attributes. These data are packaged as +"extra fields" in the archive. Some extra fields are specific to a +particular operating system (like VMS file attributes). Large files +(bigger than 4GB) on any OS require an extra field to hold their 64-bit +size data. Depending on the capabilities of the UnZip program used to +expand the archive, these extra fields may be used or ignored when files +are extracted from the archive. +.sk +Some extra fields, like UTC date-times or VMS file attributes, are +optional. Others, like the Zip64 extra field which holds 64-bit sizes +for a large file, are required. +.sk +The -X (--strip-extra) option suppresses the saving of any optional +extra fields in the archive. (Thus, -X conflicts with -V or -VV.) +.!------------------------------------------------------------------------------ +.indent -4 +2 Environment +.br +A user can specify default command-line options and arguments by +defining an "environment variable" (that is, a logical name or DCL +symbol), "ZIP_OPTS" or "ZIPOPT", to specify them. If both "ZIP_OPTS" and +"ZIPOPT" are specified, the definition of "ZIPOPT" prevails. +.sk +The C RTL function getenv() is used to sense these variables, so its +behavior determines what happens if both a logical name and a symbol are +defined. As of VMS V7.3, a logical name supercedes a symbol. +.sk +The "zip -v" report should show the perceived settings of these +variables. +.!------------------------------------------------------------------------------ +.indent -4 +2 File_Names +.br +Zip deals with file names in the system file system and with file names +in Zip archives. File names in a Zip archive are stored in a UNIX-like +path-name format. For example, a VMS file specification like this: +.sk;.indent 10 +[.zip30.vms]descrip.mms +.sk +could appear in a Zip archive as: +.sk;.indent 10 +zip30/vms/descrip.mms +.sk +For security reasons, paths in Zip archives are always stored as +relative paths, so an absolute VMS directory specification will be +transformed to a relative path in the archive (that is, no leading "/"). +For example, the following absolute directory specification would give +the same archive path as the previous (relative) example: +.sk;.indent 10 +[zip30.vms]descrip.mms +.sk +Also, device names are dropped, so the following file specification +would also give the same archive path: +.sk;.indent 10 +sys$sysdevice:[zip30.vms]descrip.mms +.sk +If an archive is intended for use with PKUNZIP under MSDOS, then the -k +(for "Katz", --DOS-names) option should be used to attempt to adjust the +names and paths to conform to MSDOS character-set and length +limitations, to store only the MSDOS file attributes (just the +owner:write attribute from VMS), and to mark the entry as made under +MSDOS (even though it wasn't). +.sk +Note that file specifications in the file system must be specified using +VMS notation, but file names in an archive must be specified using the +UNIX-like notation used in the archive. For example, where a BACKUP +command might look like this: +.sk.indent 10 +$ back [.zip30...]*.* /excl = [...vms]*.c stuff.bck /save +.sk +a corresponding Zip command might look like this: +.sk;.indent 10; +$ zip stuff.zip [.zip30...]*.* -x */vms/*.c +.sk +because the files to be added to the Zip archive are specified using VMS +file specifications, but the -x (--exclude) option excludes names based +on their archive path/file names. Options dealing with archive names +include -R (--recurse-patterns), -d (--delete), -i (--include), -x +(--exclude), and -U (--copy-entries). +.sk +Note: By default, on VMS, archive name pattern matching (-R, -d, -i, -x, +and -U) is case sensitive, even when the file system is not case +sensitive (or even case preserving). This allows accurate matching of +mixed-case names in an archive which may have been created on a system +with a case sensitive file system, but it can involve extra effort on +VMS, where it may be necessary to use unnatural case names (or the same +names in multiple cases, like "*.obj *.OBJ") for this kind of pattern +matching to give the desired behavior. If completely case-blind pattern +matching behavior is desired, specify the -ic (--ignore-case) option. +.!------------------------------------------------------------------------------ +.indent -4 +3 Case +.br +For better compatibility with UNIX-like systems, Zip, by default, +down-cases ODS2 file names. For example, the following file on an ODS2 +file system: +.sk;.indent 10 +[.ZIP30.VMS]DESCRIP.MMS +.sk +would appear in an archive as: +.sk;.indent 10 +zip30/vms/descrip.mms +.sk +Zip versions before 3.0 down-cased all VMS file names. Now, various +options give the user control over these conversions: +.sk +.lm +10;.literal +-C preserve case of all file names +-C- down-case all file names +-C2 preserve case of ODS2 names +-C2- down-case ODS2 file names (default) +-C5 preserve case of ODS5 names (default) +-C5- down-case ODS5 file names +.end literal;.lm -10 +.sk +Case is handled differently for archive member names, which the user +specifies with the -R, -d, -i, -x, and -U options. By default, on VMS, +archive name pattern matching is case sensitive, even when the file +system is not case sensitive (or even case preserving). This allows +accurate matching of mixed-case names in an archive which may have been +created on a system with a case sensitive file system, but it can +involve extra effort on VMS, where it may be necessary to use unnatural +case names (or the same names in multiple cases, like "*.obj *.OBJ") for +this kind of pattern matching to give the desired behavior. If +completely case-blind pattern matching behavior is desired, specify the +-ic (--ignore-case) option. +.!------------------------------------------------------------------------------ +.indent -4 +2 Fixing_Damage +.br +Two options can be used to fix a damaged Zip archive. +.sk;.literal +-F --fix +-FF --fixfix +.end literal;.sk +The -F (--fix) option can be used if some portions of the archive are +missing, but it requires a reasonably intact central directory. The +input archive is scanned as usual, but zip will ignore some problems. +The resulting archive should be valid, but any inconsistent entries +will be left out. +.sk +If the archive is too damaged or the end (where the central directory is +situated) has been truncated, you must use -FF (--fixfix). This is a +change from zip 2.32, where the -F option is able to read a truncated +archive. The -F option now more reliably fixes archives with minor +damage, and the -FF option is needed to fix archives where -F and -FF +was used before. +.sk +With -FF, the archive is scanned from the beginning and Zip scans for +special signatures to identify the limits between the archive members. +The -F option is more reliable if the archive is not too much damaged, +so try this option first. +.sk +Neither option will recover archives that have been incorrectly +transferred, such as by FTP in ASCII mode instead of binary. After the +repair, the -t option of UnZip may show that some files have a bad CRC. +Such files cannot be recovered; you can remove them from the archive +using the -d option of Zip. +.sk +Because of the uncertainty of the "fixing" process, it's required +to specify an output archive, rather than risking further damage to the +original damaged archive. For example, to fix the damaged archive +foo.zip, +.sk;.indent 10 +zip -F foo --out foo_fix +.sk +tries to read the entries normally, copying good entries to the new +archive foo_fix.zip. If this doesn't work, as when the archive is +truncated, or if some entries are missed because of bad central +directory entries, try -FF: +.sk;.indent 10 +zip -FF foo --out foo_fixfix +.sk +and compare the resulting archive to the archive created using -F. The +-FF option may create an inconsistent archive. Depending on what is +damaged, you can then use the -F option to fix that archive. +.sk +A split archive with missing split files can be fixed using -F if you +have the last split of the archive (the ".zip" file). If this file is +missing, you must use -FF to fix the archive, which will prompt you for +the splits you have. +.sk +Currently, the fix options can't recover an entry which has a bad +checksum or is otherwise damaged. +.!------------------------------------------------------------------------------ +.indent -4 +2 Log_File +.br +Zip normally sends messages to the user's terminal, but these may be +also directed to a log file. +.sk;.literal +-la --log-append +.end literal;.br +Append to an existing log file. Default is to create a new version. +.sk;.literal +-lf logfilepath --logfile-path logfilepath +.end literal;.br +Open a logfile at the given path. By default, a new version will be +created, but with the -la option an existing file will be opened and the +new log information appended to any existing information. Only +warnings and errors are written to the log unless the -li option is also +given, then all information messages are also written to the log. +.sk;.literal +-li --log-info +.end literal;.br +Include information messages, such as file names being zipped, in the +log. The default is to include only the command line, any warnings +and errors, and the final status. +.!------------------------------------------------------------------------------ +.indent -4 +2 Modes_of_Operation +.br +Zip supports two distinct types of command modes, external and +internal. The external modes (update, grow, and freshen) read files +from the file system (as well as from an existing archive) while the +internal modes (delete and copy) operate exclusively on entries in an +existing archive. +.sk;.literal +-u --update +.end literal;.br +Update existing entries and add new files. If the archive does not +exist, create it. This is the default mode, so -u is optional. +.sk;.literal +-g --grow +.end literal;.br +Grow (append to) the specified Zip archive, instead of creating a new +one. If this operation fails, Zip attempts to restore the archive to +its original state. If the restoration fails, the archive might become +corrupted. This option is ignored when there's no existing archive or +when at least one archive member must be updated or deleted. +.sk;.literal +-f --freshen +.end literal;.br +Update existing entries in an existing archive. Does not add new files +to the archive. +.sk;.literal +-d --delete +.end literal;.br +Delete entries from an existing archive. +.sk;.literal +-DF --difference-archive +.end literal;.br +Create an incremental backup-style archive, where the resulting archive +will contain all new and changed files since the original archive was +created. For this to work, the input file list and current directory +must be the same as during the original Zip operation. +.sk +For example, if the existing archive was created using +.sk;.indent 10 +zip foo_full.zip [.foo...]*.* +.sk +from just above the foo directory, then the command (also from just +above the foo directory): +.sk;.indent 10 +zip foo_full.zip [.foo...]*.* -DF -O foo_incr.zip +.sk +creates the archive foo_incr.zip with just the files not in foo_full.zip +and the files where the size or date-time of the files does not match +that in foo_full.zip. Note that in the "zip -DF" operation, the +original full archive is specified as the input archive, and the -O +(--output-file) option is used to specify the new (incremental) output +archive. +.sk;.literal +-FS --filesync +.end literal;.br +Delete entries in the archive that do not match files on the OS. +Normally when an archive is updated, new files are added and changed +files are updated but files that no longer exist on the OS are not +deleted from the archive. This option enables deleting of entries that +are not matched on the OS. Enabling this option should create archives +that are the same as new archives, but since existing entries are copied +instead of compressed, updating an existing archive with -FS can be much +faster than creating a new archive. If few files are being copied from +the old archive, it may be faster to create a new archive instead. +.sk +This option deletes files from the archive. If you need to preserve the +original archive, make a copy of the archive first, or use the -O +(--output) option to output the new archive to a new file. Even though +it's slower, creating a new archive with a new archive name is safer, +avoids mismatches between archive and OS paths, and is preferred. +.sk;.literal +-U --copy-entries +.end literal;.br +Select entries in an existing archive and copy them to a new archive. +Copy mode is like update mode, but entries in the existing archive are +selected by command line patterns rather than files from the file system +and it uses the -O (--output-file) option to write the resulting archive +to a new file rather than updating the existing archive, leaving the +original archive unchanged. +.sk +Normally, when updating an archive using relative file specifications +("[]", "[.xxx]", and so on), it helps to have the same default directory +as when the archive was created, but this is not a strict requirement. +.sk +Date-time information in a Zip archive may be influenced by time zone. +.!------------------------------------------------------------------------------ +.indent -4 +3 Examples +.br +When given the name of an existing archive, Zip will replace identically +named entries in the archive or add entries for new names. For example, +if foo.zip exists and contains foo/file1 and foo/file2, and the +directory [.foo] contains the files file1 and file3, then: +.sk;.indent 10 +$ zip foo [.foo...]*.* +.sk +will replace foo/file1 in foo.zip and add foo/file3 to foo.zip. After +this, foo.zip contains foo/file1, foo/file2, and foo/file3, with foo/file2 +unchanged from before. This is the default mode -u (update). +.sk +Update will add new entries to the archive and will replace +existing entries only if the modified date of the file is more recent than +the date recorded for that name in the archive. For example: +.sk;.indent 10 +$ zip -u stuff *.* +.sk +will add any new files in the current directory, and update any changed +files in the archive stuff.zip. Note that Zip will not try to pack +stuff.zip into itself when you do this. Zip avoids including its own +output files when selecting files to include in the archive, so it +should be safe, as in this case, to have the archive included in the +list of input files. +.sk +A second mode, -f (freshen), like update will only +replace entries with newer files. Unlike update, however, it will not +add files that are not already in the archive. For example: +.sk;.indent 10 +$ zip -f foo +.sk +Note that the -f option with no arguments freshens all the entries in the +archive. The same is true of -u, so "zip -u foo" and "zip -f foo" do +the same thing. +.sk +When these options are used, Zip should be run from the same directory +as when the original Zip command was run, so that the path names in the +archive will continue to agree with the path names in the file system. +Normally, it's also a good idea to keep the other options the same (-V, +-w, and the like), to keep the archive contents consistent. +.sk +The -t (--from-date) and -tt (--before-date) options can also be used +with adding, updating, or freshening to restrict further the files to be +included in the archive. For example: +.sk;.indent 10 +$ zip -rt 12071991 infamy [.FOO]*.* +.sk +will add all the files in [.FOO] and its subdirectories that were last +modified on December 7, 1991, or later to the achive infamy.zip. Dates +can be in format mmddyyyy or yyyy-mm-dd. +.sk +Also, files can be explicitly excluded using the -x option: +.sk;.indent 10 +$ zip -r foo [.FOO] -x *.obj +.sk +which will zip up the contents of [.FOO] into foo.zip but exclude all the +files that end in ".obj". +.sk +The -d (delete) mode will remove entries from an +archive. An example might be: +.sk;.indent 10 +$ zip -d foo foo/harry/*.* *.obj +.sk +which will remove all of the files that start with "foo/harry/" and all of +the files that end with ".obj" (in any path). +.sk +The last mode, -U (--copy-entries), selects entries from an existing +archive and copies them to a new archive. +.sk;.indent 10 +$ zip -U foo *.obj --out fooobj +.sk +will copy all .obj entries from foo.zip and put them in the new archive +fooobj.zip. +.sk +Note: By default, on VMS, archive name pattern matching (-R, -d, -i, -x, +and -U) is case sensitive, even when the file system is not case +sensitive (or even case preserving). This allows accurate matching of +mixed-case names in an archive which may have been created on a system +with a case sensitive file system, but it can involve extra effort on +VMS, where it may be necessary to use unnatural case names (or the same +names in multiple cases, like "*.obj *.OBJ") for this kind of pattern +matching to give the desired behavior. If completely case-blind pattern +matching behavior is desired, specify the -ic (--ignore-case) option. +.!------------------------------------------------------------------------------ +.indent -4 +2 Options_List +.br +"zip -h" provides a concise list of common command-line options. "zip +-h2" provides more details. "zip -so" provides a list of all available +options. "zip -v" shows the program version and available features. +(The list below was derived from a "zip -so" listing.) +.sk +Short-form options begin with a single hyphen ("-"). Long-form option +begin with a double hyphen ("--"), and may be abbreviated to any +unambiguous shorter string. For example: +.lm +10;.literal +-v +--verbose +--verb +.end literal;.lm -10 +.sk +To avoid confusion, if a negatable option contains an embedded hyphen +("-"), then avoid abbreviating it at the hyphen if you plan to negate +it. For example, if an option like --some-option were abbreviated to +--some-, the parser would consider that trailing hyphen to be part of +the option name, rather than as a negating trailing hyphen. This +behavior may change in the future, to interpret the trailing hyphen in +--some- to be negating. (So don't do it.) +.sk +Some options may be negated (or modified) by appending a "-": +.lm +10;.literal +-la- +--show-files- +.end literal;.lm -10 +.sk +Some options take a value, which may immediately follow the option, or +be separated by a space or "=". For example: +.lm +10;.literal +-ttmmddyyyy +-tt mmddyyyy +-tt=mmddyyyy +.end literal;.lm -10 +.sk +.lm -4;.literal + Sh Long Description +----+-------------------+-------------------------------------------------- + 0 store store (instead of compress) + 1 compress-1 compress faster (-2, -3, -4, ...) + 9 compress-9 compress better + ? show the Zip help screen + @ names-stdin read input file patterns from SYS$INPUT (1/line) + A adjust-sfx adjust self-extracting executable + b temp-path path use "path" directory for temporary files + C preserve-case preserve case of all file names added to archive + C- preserve-case- down-case all file names added to archive + C2 preserve-case-2 preserve case of ODS2 names added to archive + C2- preserve-case-2- down-case ODS2 file added to archive (default) + C5 preserve-case-5 preserve case of ODS5 names added to archive (dflt) + C5- preserve-case-5- down-case ODS5 names added to archive + c entry-comments add a comment for each entry added to archive + D no-dir-entries do not add archive entries for directories + DF difference-archive difference archive: add only changed or new files + d delete delete entries in archive + db display-bytes display running byte counts + dc display-counts display running file counts + dd display-dots display progress dots for files (dflt size = 10MB) + dg display-globaldots display progress dots for archive, not each file + ds dot-size size set progress dot interval to "size" (MB) + du display-usize display original uncompressed size for entries + dv display-volume display volume (disk) number as in_disk>out_disk + e encrypt encrypt entries, ask for password + F fix fix mostly intact archive (try F before FF) + FF fixfix salvage what can be salvaged (not as reliable) + FS filesync remove archive entries unmatched in file system + f freshen update existing entries (only changed files) + fd force-descriptors force data descriptors as if streaming + fz force-zip64 force use of Zip64 format + g grow grow existing archive (unless updating or deleting) + H show the Zip help screen + h help show the Zip help screen + h2 more-help show extended Zip help + i include pat1 [pat2 [...]] include only names matching the patterns + ic ignore-case ignore case (case-blind archive entry name matching) + J junk-sfx junk (remove) archive preamble (unzipsfx) + j junk-paths junk (don't store) directory names, only file names + k DOS-names simulate PKZIP-made archive (DOS 8.3 names) + L license show software license + l to-crlf translate end-of-lines (LF -> CRLF) + la log-append append to existing log file + lf logfile-path lfile log to log file at lfile (default: new version) + li log-info include informational messages in log + ll from-crlf translate end-of-lines (CRLF -> LF) + MM must-match input file spec must exist (wildcards must match) + m move delete files added to archive + n suffixes sfx1[:sfx2[...]] don't compress files with these suffixes + nw no-wild no wildcards during add or update + O output-file ozf use "ozf" as the output archive (dflt = inp archive) + o latest-time set archive date-time to match oldest entry + P password password encrypt with supplied "password" string + q quiet quiet operation (no info messages) + R recurse-patterns recurse into subdirs from cur dir, match names only + r recurse-paths recurse into directories from specified path pats + s split-size size split archive at "size" (K/MB) (0: don't split) + sb split-bell ring terminal bell at pause for split medium change + sc show-command show command line + sd show-debug show debug messages + sf show-files show files to process (only) + so show-options show list of all command-line options + sp split-pause pause to select split destination(s) + sv split-verbose be verbose about creating splits + T test test archive integrity (runs UnZip -T) + t from-date mmddyyyy only do files since (at or after) "mmddyyyy" + tt before-date mmddyyyy only do files before "mmddyyyy" + u update update changed files, add new files (default mode) + V VMS-portable save VMS file attributes + VV VMS-specific save VMS file attributes and all allocated blocks + v verbose verbose messages (print version info if only arg) + w VMS-versions save VMS version numbers in archive + ww VMS-dot-versions save VMS version numbers as ".nnn", not ";nnn" + X strip-extra strip all but critical extra fields + X- strip-extra- keep all extra fields + x exclude pat1 [pat2 [...]] exclude all names matching the patterns + Z compression-method mthd use compress method "mthd" (bzip2 or deflate) + z archive-comment ask for archive comment +.end literal;.lm +4 +.!------------------------------------------------------------------------------ +.indent -4 +2 Miscellaneous_Options +.sk;.literal +-D --no-dir-entries +.end literal;.br +Do not create entries in the archive for directories. By default, +directory entries are added to an archive, so that their attributes can +be saved in the archive. When an archive is created using -D, UnZip +will still create directories as needed (subject to user control), but +they will get the default attributes (date-time, permissions, ...) on +the destination system, rather than their original atributes. +.sk;.literal +-MM --must-match +.end literal;.br +All input patterns must match at least one file and all input files +found must be readable. Normally when an input pattern does not match +a file the "name not matched" warning is issued and when an input +file has been found but later is missing or not readable a "missing or +not readable" warning is issued. In either case Zip continues +creating the archive, with missing or unreadable new files being skipped +and files already in the archive remaining unchanged. After the +archive is created, if any files were not readable zip returns the OPEN +error code (18 on most systems) instead of the normal success return (0 +on most systems). With -MM, Zip exits as soon as an input pattern +is not matched (whenever the "name not matched" warning would be issued) +or when an input file is not readable. In either case Zip exits with +an OPEN error and no archive is created. +.sk +This option is useful when a known list of files is to be zipped so any +missing or unreadable files should result in an error. It may be less +useful when used with wildcards, but Zip will still exit with an error +if any input pattern doesn't match at least one file or if any +matched files are unreadable. If you want to create the archive anyway +and only need to know if files were skipped, then don't use -MM and just +check the exit status. Also, a log file (see -lf (--logfile-path)) +could be useful. +.sk;.literal +-O out_file --output-file out_file +.end literal;.br +Process the archive changes as usual, but instead of updating the +existing archive, send the output to a new archive, "out_file". The +output archive specified must be a different file from the input +archive. +.sk +This option can be used to create updated split archives. It can +also be used with -U to copy entries from an existing archive to +a new archive. See the EXAMPLES section below. +.sk +Another use is converting zip files from one split size to +another. For instance, to convert an archive with 700MB CD splits +to one with 2GB DVD splits, can use: +.sk;.indent 10 +zip -s 2g cd-split.zip --out dvd-split.zip +.sk +which uses copy mode. See -U below. Also: +.sk;.indent 10 +zip -s 0 split.zip --out unsplit.zip +.sk +will convert a split archive to a single-file archive. +.sk +Copy mode will convert stream entries (using data descriptors and which +may be incompatible with some unzip programs) to normal entries (which +should be compatible with all unzip programs), except if standard +encryption was used. For archives with encrypted entries, zipcloak +will decrypt the entries and convert them to normal entries. +.sk;.literal +-o --latest-time +.end literal;.br +Set the modification date-time of the Zip archive file to the latest +(newest) modification date-time found among the entries in the zip +archive. This can be used without any other operations, if +desired. For example: +.sk;.indent 10 +zip -o foo +.sk +will change the modification date-time of foo.zip to the latest time of +the entries in foo.zip. +.sk;.literal +-q --quiet +.end literal;.br +Quiet mode. Eliminates informational messages and comment prompts. +This mode may be useful in command procedures, or if the Zip operation +is being performed as a background task ("$ spawn/nowait zip -q foo +*.c"). +.sk +.sk;.literal +-T --test +.end literal;.br +Test the integrity of a zip archive (the new one, if -O (--output-file) +is specified). If the check fails, the old zip file is unchanged and +(with the -m option) no input files are removed. +.sk +Implementation +.br +"zip -T" actually runs an "unzip -t" command to do the testing, so UnZip +must be installed properly for this to work. +.sk;.literal +-TT unzip_cmd --unzip-command unzip_cmd +.end literal;.br +Specify the actual UnZip command, "unzip_cmd" (normally a DCL symbol) to +use for "zip -T". This can be useful if multiple versions of UnZip are +installed on a system, and the default DCL symbol "UNZIP" would run the +wrong one (or the logical name DCL$PATH would lead to the wrong one). +.sk +In "unzip_cmd", the string "{}" is replaced by the temporary name of the +archive to be tested, otherwise the name of the archive is appended +to the end of the command. The exit status is checked for success severity. +.sk;.literal +-v --verbose +.end literal;.br +Verbose mode or print diagnostic version info. +.sk +Normally, when applied to real operations, this option enables the +display of a progress indicator during compression (see -dd for more on +dots) and requests verbose diagnostic info about archive structure +oddities. +.sk +When -v is the only command line argument, a diagnostic report is +displayed, showing: +.lm +3;.br;.indent -2 +o Copyright and other legal notices +.br;.indent -2 +o Program name, version, and release date +.br;.indent -2 +o Pointers to Info-ZIP FTP and Web sites +.br;.indent -2 +o Program build information (compiler type and version, OS version, and +the compilation date +.br;.indent -2 +o Optional features enabled at compile-time +.br;.indent -2 +o Environment variable definitions (ZIP_OPTS, ZIPOPT) +.lm -3;.br +.sk +This information should be included in bug reports. +.sk;.literal +-y --symlinks +.end literal;.br +Store symbolic links as such in the Zip archive, instead of compressing +and storing the file referred to by the link. A symbolic link normally +requires less storage than the actual file, both in the archive, and on +the destination file system. +.sk +On VMS, symbolic links are supported on ODS5 disks where the C RTL +supports symbolic links. Full support for symbolic links seems to +require VMS V8.3, but a Zip program supporting symbolic links may be +built on VMS V7.3-2. +.!------------------------------------------------------------------------------ +.indent -4 +2 Progress_Display +.br +Various options control the display of progress messages during Zip +operation. +.sk;.literal +-db --display-bytes +.end literal;.br +Display running byte counts showing the bytes processed and the bytes to +go. +.sk;.literal +-dc --display-counts +.end literal;.br +Display running count of entries processed and entries to go. +.sk;.literal +-dd --display-dots +.end literal;.br +Display dots while each entry is processed (except on ports that have +their own progress indicator). See -ds below for setting dot size. The +default is a dot every 10 MB of input file processed. The -v +(--verbose) option also displays dots and used to at a higher rate than +this (at the same rate as in previous versions of Zip) but this rate has +been changed to the new 10 MB default, and is also controlled by -ds. +.sk;.literal +-dg --display-globaldots +.end literal;.br +Display progress dots for the archive instead of for each file. The +command +.sk;.indent 10 +zip -qdgds 10m +.sk +will turn off most output except dots every 10 MB. +.sk;.literal +-ds size --dot-size size +.end literal;.br +Set amount of input file processed for each dot displayed. See -dd to +enable displaying dots. Setting this option implies -dd. "size" is in +the format "nm" where n is a number and m is a multiplier. Currently +"m" can be k (KB), m (MB), g (GB), or t (TB), so if "n" is 100 and "m" +is k, "size" would be 100k which is 100KB. The default is 10MB. +.sk +The -v (--verbose) option also displays dots and used to default to a +higher rate than this (at the same rate as in previous versions of Zip) +but now the default is 10 MB and the -v dots are also controlled by this +option. A "size" of 0 turns dots off. +.sk +This option does not control the dots from the "Scanning files" message +as Zip scans for input files. The dot size for that is fixed at 2 +seconds or a fixed number of entries, whichever is longer. +.sk;.literal +-du --display-usize +.end literal;.br +Display the uncompressed size of each entry. +.sk;.literal +-dv --display-volume +.end literal;.br +Display the volume (disk) number each entry is being written to. +.!------------------------------------------------------------------------------ +.indent -4 +2 Self_Extracting_Archives +.br +A self-extracting archive (SFX) comprises a normal Zip archive appended +to a special UnZip program (such as UNZIPSFX.EXE) for the intended +target system. +.sk +The UnZip distribution includes a VMS command procedure, +[,vms]makesfx.com, which can be used directly or adapted to create an +SFX archive from a normal Zip archive. +.sk +The .ZIP file format includes offsets to data structures in the archive, +and these offsets are measured from the start of the archive file. +Appending an archive to an UnZip SFX executable effectively moves the +start of the archive file. That makes the original offsets wrong, and +that will cause the UnZip SFX program to emit warning messages when it +tries to unpack the archive. Zip -A can be used to adjust these offsets +in a self-extracting archive. For example, to adjust the offsets in +foo.sfx_exe: +.sk;.indent 10 +zip -A foo.sfx_exe +.sk +Similarly, the UnZip SFX program can be removed from a self-extracting +archive (and the offsets in the archive restored) using the -J +(--junk-sfx) option. For example: +.sk;.indent 10 +zip -J foo.sfx_exe +.sk +Note that a self-extracting archive contains a normal Zip archive, and a +normal UnZip program can be used to expand it in the normal way. You +may get a warning about extra bytes at the beginning of the archive (the +UnZip SFX program), but UnZip should work properly after that. This +allows data in a self-extracting archive to be accessed on any system, +not just the target system where its embedded UnZip SFX program runs. +.!------------------------------------------------------------------------------ +.indent -4 +2 Split_Archives +.br +Beginning with version 3.0, Zip supports split archives. A split +archive is one which is divided into multiple files, usually to allow it +to be stored on multiple storage media (floppy diskettes, CD-ROMs, or +the like) when a single medium would be too small to contain the whole +archive. (Note that split archives are not just unitary archives split +into pieces, as the .ZIP file format includes offsets to data structures +in the archive, and for a split archive these are based on the start of +each split, not on the start of the whole archive. Concatenating the +pieces will invalidate these offsets, but UnZip can usually deal with +it. Zip will usually refuse to process such a spliced archive unless +the -FF fix option is used to fix the offsets.) +.sk +For a split archive with, say, 20 split files, the files are typically +named ARCHIVE.z01, ARCHIVE.z02, ..., ARCHIVE.z19, ARCHIVE.zip, where +"ARCHIVE" is the archive name specified by the user on the Zip command +line. Note that the last split file is the ".zip" file. In contrast, +"spanned" archives are the original multi-disk archive generally +requiring floppy disks and using volume labels to store disk numbers. +Zip supports split archives but not spanned archives, though a procedure +exists for converting split archives of the right size to spanned +archives. The reverse is also true, where each file of a spanned +archive can be copied in order to files with the above names to create a +split archive. +.!------------------------------------------------------------------------------ +.indent -4 +3 Options +.br +Use "-s size" to create a split archive (and to set the split size). +The size is given as a number followed optionally by a multiplier suffix +of k (KB), m (MB, the default if no suffix is specified), g (GB), or t +(TB). (All are powers of 1024, not 1000). 64K is the minimum split +size. For example, the following command could be used to create a +split archive called "foo" from the contents of the "bar" directory with +splits of 670MB, which might be useful for burning on CDs: +.sk;.indent 10 +zip -s 670m foo [.bar...]*.* +.sk +Using -s without -sp as above creates all the splits in the directory +specified by "foo", in this case the current default directory. This +split mode updates the splits as the archive is being created, requiring +all splits to remain writable, but creates split archives that are +readable by any UnZip that supports split archives. See -sp below for +enabling split pause mode which allows splits to be written directly to +removable media. +.sk +The -sv option can be used to enable verbose splitting and display +details of how the splitting is being done. The -sb option can be used +to ring the terminal bell when Zip pauses for the next split +destination. +.sk +The -sp option can be used to pause Zip between splits to allow +changing removable media, for example, but read the descriptions and +warnings for both -s and -sp below. +.sk +Though Zip does not update split archives, Zip provides the option +-O (--output-file) to allow split archives to be updated and saved in a +new archive. For example: +.sk;.indent 10 +zip inarchive.zip foo.c bar.c -O outarchive.zip +.sk +reads archive inarchive.zip, even if split, adds the files foo.c and +bar.c, and writes the resulting archive to outarchive.zip. If +inarchive.zip is split, then outarchive.zip defaults to the same split +size. Be aware that outarchive.zip and any split files that are created +with it are always overwritten without warning. This may be changed in +the future. +.!------------------------------------------------------------------------------ +.indent -4 +2 Temporary_Files +.br +When creating a new archive or normally when changing an existing +archive, Zip will write a temporary file in the archive destination +directory ("ZIxxxxxxxx", where "xxxxxxxx" is the hexadecimal process ID) +with the new contents. Then, if and when the Zip job has completed with +no errors, it will rename the temporary file to the specified archive +name (replacing the old archive, if any). +.sk +You can use the -b (--temp-path) option to specify a different path +(device and/or directory) for the temporary file, but specifying a +different device will force Zip to copy the temporary file to its final +destination instead of simply renaming it, and that copying will take +more time than renaming, especially for a large archive. For example: +.sk;.indent 10 +$ zip -b disk$scratch:[tmp] stuff * +.sk +will cause Zip to put its temporary files in the directory +"disk$scratch:[tmp]", copying the temporary file back to the current +directory as stuff.zip when it's complete. +.!------------------------------------------------------------------------------ +.indent -4 +2 Text_Files +.br +Zip offers some options to help deal with line endings in text files. +These may have limited utility on VMS. +.sk;.literal +-l --to-crlf +.end literal;.br +Translate the UNIX end-of-line character LF (CR on MAC) into the MSDOS +convention CR-LF. This option should not be used on binary files. This +option can be used on UNIX if the Zip file is intended for PKUNZIP under +MSDOS. If the input files already contain CR-LF, this option adds an +extra CR. This ensure that "unzip -a" on Unix will get back an exact +copy of the original file, to undo the effect of "zip -l". See -ll +below for the binary checks. +.sk;.literal +-ll --from-crlf +.end literal;.br +Translate the MSDOS end-of-line CR LF into UNIX LF (CR on MAC). This +option should not be used on binary files. This option can be used on +MSDOS if the Zip archive is intended for UnZip under UNIX. +.sk +For both -l and -ll, if the file is converted and the file is later +determined to be binary, a warning is issued and the file is probably +corrupted. If Zip with -l or -ll detects binary (non-text) in the first +buffer read from a file, it issues a warning and skips line-ending +conversion on the file, avoiding corruption. This check seems to catch +all binary files tested, but the original check remains and if a +converted file is later determined to be binary, that warning is still +issued. The algorithm now being used for binary detection should allow +line-ending conversion of text files in UTF-8 and similar encodings. +.!------------------------------------------------------------------------------ +.indent -4 +2 VMS_Specifics +.br +VMS File Attributes +.sk;.literal +-V --VMS-portable +-VV --VMS-specific +.end literal;.br +The -V and -VV options cause Zip to store VMS file atributes (such as +file organization, record format, carriage control, and so on) in +VMS-specific "extra fields" in an archive along with the usual data. +These extra fields are ignored on non-VMS systems, but on a VMS system, +they allow UnZip to restore the files with their VMS attributes intact. +.sk +With -V, Zip ignores any data in the file after the end-of-file (EOF) +point (defined by FAT$L_EFBLK and FAT$W_FFBYTE), which works well for +well-formed files (that is, those with no valid data beyond EOF). +Portable-format files (Stream_LF, fixed-512) archived with -V should be +extracted properly on a non-VMS system. Files with more complex +structures, such as indexed files and files with embedded byte counts +or other such data may be of limited use on other systems. (UnZip on +non-VMS systems may be able to extract various VMS-format text files, +however.) +.sk +With -VV, Zip processes all allocated blocks for the file (including +those beyond EOF). When extracted on a VMS system, the original file +should be reproduced with as much fidelity as possible, but on a non-VMS +system, most files will be seen as corrupt because of the data from +beyond EOF. +.sk +VMS File Version Numbers +.sk;.literal +-w --VMS-versions +-ww --VMS-dot-versions +.end literal;.br +By default, for compatibility with non-VMS systems, Zip strips VMS file +version numbers from the names stored in an archive. The -w +(--VMS-versions) option causes Zip to retain file version numbers on +names in an archive. Without -w, a version number wildcard (";*") can +cause errors when multiple versions of a single file are treated as +multiple files with the same name. +.sk +For better compatibility with non-VMS systems where semi-colons are less +popular in file names, the -ww (--VMS-dot-versions) option stores the +file version numbers with a dot (".nnn") instead of a semi-colon +(";nnn"). +.!------------------------------------------------------------------------------ +.indent -4 +2 Copyright_and_License +.br +Zip has an option to display its copyright and license. +.sk;.literal +-L --license +.end literal;.br +The license is reproduced below. +.sk.lm +3 +This is version 2007-Mar-4 of the Info-ZIP license. The definitive +version of this document should be available at +ftp://ftp.info-zip.org/pub/infozip/license.html indefinitely and a copy +at http://www.info-zip.org/pub/infozip/license.html. +.lm -3;.sk +-------------------------------------------------------- +.sk +Copyright (c) 1990-2007 Info-ZIP. All rights reserved. +.sk +For the purposes of this copyright and license, "Info-ZIP" is defined as +the following set of individuals: +.sk;.lm +3 + Mark Adler, John Bush, Karl Davis, Harald Denker, Jean-Michel Dubois, + Jean-loup Gailly, Hunter Goatley, Ed Gordon, Ian Gorman, Chris Herborth, + Dirk Haase, Greg Hartwig, Robert Heath, Jonathan Hudson, Paul Kienitz, + David Kirschbaum, Johnny Lee, Onno van der Linden, Igor Mandrichenko, + Steve P. Miller, Sergio Monesi, Keith Owens, George Petrov, Greg Roelofs, + Kai Uwe Rommel, Steve Salisbury, Dave Smith, Steven M. Schweda, + Christian Spieler, Cosmin Truta, Antoine Verheijen, Paul von Behren, + Rich Wales, Mike White. +.lm -3;.sk +This software is provided "as is," without warranty of any kind, express +or implied. In no event shall Info-ZIP or its contributors be held +liable for any direct, indirect, incidental, special or consequential +damages arising out of the use of or inability to use this software. +.sk +Permission is granted to anyone to use this software for any purpose, +including commercial applications, and to alter it and redistribute it +freely, subject to the above disclaimer and the following restrictions: +.sk;.lm +7;.indent -4 + 1. Redistributions of source code (in whole or in part) must retain + the above copyright notice, definition, disclaimer, and this list + of conditions. +.sk;.indent -4 + 2. Redistributions in binary form (compiled executables and libraries) + must reproduce the above copyright notice, definition, disclaimer, + and this list of conditions in documentation and/or other materials + provided with the distribution. The sole exception to this condition + is redistribution of a standard UnZipSFX binary (including SFXWiz) as + part of a self-extracting archive; that is permitted without inclusion + of this license, as long as the normal SFX banner has not been removed + from the binary or disabled. +.sk;.indent -4 + 3. Altered versions -- including, but not limited to, ports to new operating + systems, existing ports with new graphical interfaces, versions with + modified or added functionality, and dynamic, shared, or static library + versions not from Info-ZIP -- must be plainly marked as such and must not + be misrepresented as being the original source or, if binaries, + compiled from the original source. Such altered versions also must not + be misrepresented as being Info-ZIP releases -- including, but not + limited to, labeling of the altered versions with the names "Info-ZIP" + (or any variation thereof, including, but not limited to, different + capitalizations), "Pocket UnZip," "WiZ" or "MacZip" without the + explicit permission of Info-ZIP. Such altered versions are further + prohibited from misrepresentative use of the Zip-Bugs or Info-ZIP + e-mail addresses or the Info-ZIP URL(s), such as to imply Info-ZIP + will provide support for the altered versions. +.sk;.indent -4 + 4. Info-ZIP retains the right to use the names "Info-ZIP", "Zip", + "UnZip", "UnZipSFX", "WiZ", "Pocket UnZip", "Pocket Zip", and + "MacZip" for its own source and binary releases. +.lm -7;.sk +.!------------------------------------------------------------------------------ +.indent -4 +2 Acknowledgements +.br + Thanks to R. P. Byrne for his Shrink.Pas program, which + inspired this project, and from which the shrink algorithm + was stolen; to Phil Katz for placing in the public domain + the zip file format, compression format, and .ZIP filename + extension, and for accepting minor changes to the file + format; to Steve Burg for clarifications on the deflate + format; to Haruhiko Okumura and Leonid Broukhis for providing + some useful ideas for the compression algorithm; to + Keith Petersen, Rich Wales, Hunter Goatley and Mark Adler + for providing a mailing list and ftp site for the Info-ZIP + group to use; and most importantly, to the Info-ZIP group + itself (listed in the file infozip.who) without whose + tireless testing and bug-fixing efforts a portable zip + would not have been possible. Finally we should thank + (blame) the first Info-ZIP moderator, David Kirschbaum, + for getting us into this mess in the first place. +.!------------------------------------------------------------------------------ +.indent -4 +2 Bugs +.br +All bug reports, patches, or suggestions should go to zip-bugs via the +web site contact form at http://www.Info-ZIP.org. Patches should be +sent as unified or context diffs only (diff -u or diff -c). +.sk +Any bug report should include the Zip version, any special compilation +options (see "zip -v" report), the host system type and operating system +version, and any other relevant information (compiler version, lunar +phase, ...). +.!------------------------------------------------------------------------------ diff --git a/samples/RUNOFF/contributing.rnh b/samples/RUNOFF/contributing.rnh new file mode 100644 index 00000000..cbd5090e --- /dev/null +++ b/samples/RUNOFF/contributing.rnh @@ -0,0 +1,324 @@ +.na +.ll 72 +.pl 90 +.m1 4 +.m2 4 +.m3 6 +.m4 6 +.sp 8 +.ds +.ce +CONTRIBUTING TO LINGUIST +.sp +.ce +by +.ce +GITHUB +.sp +.ce +and the +.sp +.ce +OPEN SOURCE COMMUNITY +.sp +.bp +.sp 5 +.ce +_I_N_T_R_O_D_U_C_T_I_O_N: +.sp + Hi there! We're thrilled that you'd like to contribute to this +project. Your help is essential for keeping it great. This project +adheres to the Contributor Covenant Code of Conduct. By participating, +you are expected to uphold this code. +.br +The majority of contributions won't need to touch any Ruby code at all. +.sp 5 +.ce +_A_d_d_i_n_g _a_n _e_x_t_e_n_s_i_o_n _t_o _a +_l_a_n_g_u_a_g_e +.sp + We try only to add new extensions once they have some usage on +GitHub. In most cases we prefer that extensions be in use in hundreds of +repositories before supporting them in Linguist. +.sp +To add support for a new extension: +.sp +.in 5 +.un 5 +1. Add your extension to the language entry in +_l_a_n_g_u_a_g_e_s_._y_m_l, keeping the extensions in +alphabetical order. +.br +.un 5 +2. Add at least one sample for your extension to the samples directory +in the correct subdirectory. +.br +.un 5 +3. Open a pull request, linking to a GitHub search result showing +in-the-wild usage. +.in 0 +.sp +In addition, if this extension is already listed in +_l_a_n_g_u_a_g_e_s_._y_m_l then sometimes a few more steps +will need to be taken: +.sp +.in 5 +.un 5 +1. Make sure that example .yourextension files are present in the +samples directory for each language that uses .yourextension. +.br +.un 5 +2. Test the performance of the Bayesian classifier with a relatively +large number (1000s) of sample .yourextension files. (ping @arfon or +@bkeepers to help with this) to ensure we're not misclassifying files. +.br +.un 5 +3. If the Bayesian classifier does a bad job with the sample files +then a heuristic may need to be written to help. +.in 0 +.sp 5 +.ce +_A_d_d_i_n_g _a _l_a_n_g_u_a_g_e +.sp + We try only to add languages once they have some usage on GitHub. +In most cases we prefer that each new extension be in use in hundreds of +repositories before supporting them in Linguist. +.sp +To add support for a new language: +.in 5 +.un 5 +1. Add an entry for your language to +_l_a_n_g_u_a_g_e_s_._y_m_l. +.br +.un 5 +2. Add a grammar for your language. Please only add grammars that have +a license that permits redistribution. +.br +.in +5 +.un 5 +i. Add your grammar as a submodule: +.br +.in +4 +git submodule add +https://github.com/Alhadis/language-roff +vendor/grammars/language-roff +.in -4 +.un 5 +ii. Add your grammar to grammars.yml: +.br +.in +4 +script/convert-grammars --add vendor/grammars/MyGrammar +.in -4 +.un 5 +iii. Download the license for the grammar by running script/licensed. +Be careful to only commit the file for the new grammar, as this script +may update licenses for other grammars as well. +.br +.in -5 +.un 5 +3. Add samples for your language to the samples directory in the +correct subdirectory. +.br +.un 5 +4. Open a pull request, linking to a GitHub search result showing +in-the-wild usage. +.br +.in 0 +.sp +In addition, if your new language defines an extension that's already +listed in _l_a_n_g_u_a_g_e_s_._y_m_l (such as `.foo`) then +sometimes a few more steps will need to be taken: +.sp +.in +5 +.un 5 +1. Make sure that example .foo files are present in the samples +directory for each language that uses .foo. +.br +.un 5 +2. Test the performance of the Bayesian classifier with a relatively +large number (1000s) of sample `.foo` files. (ping @arfon or @bkeepers +to help with this) to ensure we're not misclassifying files. +.br +.un 5 +3. If the Bayesian classifier does a bad job with the sample .foo +files then a heuristic may need to be written to help. +.br +.in 0 +.sp +Remember, the goal here is to try and avoid false positives! +.sp 2 +.ce +_F_i_x_i_n_g _a _m_i_s_c_l_a_s_s_i_f_i_e_d +_l_a_n_g_u_a_g_e +.br + Most languages are detected by their file extension defined in +_l_a_n_g_u_a_g_e_s_._y_m_l. For disambiguating between +files with common extensions, linguist applies some heuristics and a +statistical classifier. This process can help differentiate between, +for example, .h files which could be either C, C++, or Obj-C. +.sp + Misclassifications can often be solved by either adding a new +filename or extension for the language or adding more samples to make +the classifier smarter. +.sp +.m4 -2 +.ce +_F_i_x_i_n_g _s_y_n_t_a_x +_h_i_g_h_l_i_g_h_t_i_n_g +.br + Syntax highlighting in GitHub is performed using +TextMate-compatible grammars. These are the same grammars that TextMate, +Sublime Text and Atom use. Every language in languages.yml is mapped to +its corresponding TM `scope`. This scope will be used when picking up a +grammar for highlighting. +.sp + Assuming your code is being detected as the right language, in most +cases this is due to a bug in the language grammar rather than a bug in +Linguist. _g_r_a_m_m_a_r_s_._y_m_l lists all the grammars +we use for syntax highlighting on github.com. Find the one corresponding +to your code's programming language and submit a bug report upstream. +.sp +If you can, try to reproduce the highlighting problem in the text editor +that the grammar is designed for (TextMate, Sublime Text, or Atom) and +include that information in your bug report. +.sp + You can also try to fix the bug yourself and submit a Pull Request. +TextMate's documentation offers a good introduction on how to work with +TextMate-compatible grammars. You can test grammars using Lightshow. +.sp + Once the bug has been fixed upstream, we'll pick it up for GitHub +in the next release of Linguist. +.sp 2 +.ce +_T_e_s_t_i_n_g +.br + For development you are going to want to checkout out the source. +To get it, clone the repo and run Bundler to install its dependencies. +.sp +.in 4 +git clone https://github.com/github/linguist.git +.br +cd linguist/ +.br +script/bootstrap +.br +.in 0 +.sp +To run the tests: +.sp +.in 4 + bundle exec rake test +.in 0 +.sp + Sometimes getting the tests running can be too much work, especially +if you don't have much Ruby experience. It's okay: be lazy and let our +build bot Travis run the tests for you. Just open a pull request and the +bot will start cranking away. +.sp +.ce +_M_a_i_n_t_a_i_n_e_r_s +.br +Linguist is maintained with love by: +.sp +.in -2 +- @arfon (GitHub Staff) +.br +- @larsbrinkhoff +.br +- @pchaigno +.in 0 +.br +.sp +As Linguist is a production dependency for GitHub we have a couple of +workflow restrictions: +.sp +.in -2 +- Anyone with commit rights can merge Pull Requests provided that there +is a :+1: from a GitHub member of staff +.br +- Releases are performed by GitHub staff so we can ensure GitHub.com +always stays up to date with the latest release of Linguist and there +are no regressions in production. +.in 0 +.sp +.ce +_R_e_l_e_a_s_i_n_g +.sp +If you are the current maintainer of this gem: +.sp +.in 5 +.ul 5 +1. Create a branch for the release: +.sp +.in +2 +git checkout -b cut-release-vxx.xx.xx +.in -2 +.sp +.ul 5 +2. Make sure your local dependencies are up to date: +.sp +.in +2 +script/bootstrap +.in -2 +.sp +.ul 5 +3. If grammar submodules have not been updated recently, update them: +.sp +.in +2 +git submodule update --remote _&_& git commit -a +.in -2 +.sp +.ul 5 +4. Ensure that samples are updated: +.sp +.in +2 +bundle exec rake samples +.in -2 +.sp +5. Ensure that tests are green: +.sp +.in +2 +bundle exec rake test +.in -2 +.sp +.ul 5 +6. Bump gem version in lib/linguist/version.rb +.br +.ul 5 +7. Make a PR to github/linguist +.br +.ul 5 +8. Build a local gem: `bundle exec rake build_gem` +.br +.ul 5 +9. Test the gem: +.sp +.in +5 +.un 5 +i. Bump the Gemfile and Gemfile.lock versions for an app which relies +on this gem +.un 5 +ii. Install the new gem locally +.un 5 +iii. Test behaviour locally, branch deploy, whatever needs to happen. +.br +.in -5 +.sp +.ul 5 +10. Merge github/linguist PR +.sp +.ul 5 +11. Tag and push: +.sp +.in +2 +git tag vx.xx.xx; +.br +git push --tags +.in -2 +.sp +12. Push to rubygems.org +.br +.in +2 +gem push github-linguist-3.0.0.gem +.in -2 +.sp 2 diff --git a/samples/RUNOFF/longlib.rno b/samples/RUNOFF/longlib.rno new file mode 100644 index 00000000..5049f8ae --- /dev/null +++ b/samples/RUNOFF/longlib.rno @@ -0,0 +1,8644 @@ +.! documentation for the LONGLIB graphics routines and library +.! *** LAST REVISED ON 16-MAR-1988 08:22:32.49 +.! *** SOURCE FILE: [DL.GRAPHICS.LONGLIB]LONGLIB.RNO +.lm0.rm66.ps59,66 +- +.s12 +.flags index ~ +.c;The LONGLIB Graphics Library +.s2 +.c;Version 5.1 +.s3 +.flags substitute +.c;$$Month#$$Day,#$$Year +.no flags substitute +.no flags accept +.s5 +.c;David Long +.s1 +.c;Jet Propulsion Laboratory +.c;4800 Oak Grove Drive +.c;Pasadena, California 91109 + +.pg +.! note: TOC stuff is for VMS 3.x and is not required for VMS 4.0 +.style headers 6 +.send TOC .layout 1,3 +.send TOC .rm 70 +.send TOC .display number rl +.send TOC .c;Table of Contents +.send TOC .sk + +.require "LONGLIB.RNT" +.display number d +.lm0.rm66.ps59,66 + +.pg.f.j +.s3 +.CHAPTER Introduction + +.hl 1 General +.p +This manual was prepared to document the LONGLIB graphics library. +This latest revision of the library has been extensively modified though +every effort has been made to make any changes or additions to the library +compatible with previous versions of the LONGLIB graphics library. +It is anticipated that additional MASTER subroutines will be incorporated +in the future as they are needed. +.p +The LONGLIB graphics library is a set of FORTRAN subroutines for vector +plotting (line graphics). The library is similar to CALCOMP; +however, a great many extensions +are incorporated into the LONGLIB library including viewport +clipping, plot rotation, etc. In addition, +the LONGLIB library includes a large set of routines +for such things as 3-d plotting (with hidden line removal), extended character +sets, MASTER routines, graphics input routines, map routines, etc. +.p +The LONGLIB library is designed with three internal packages for plotting +on 3 major classes of output graphics devices: graphics terminals, +Ramtek display screens, and hardcopy devices via metafiles. +A large variety of graphics terminals are supported. Graphics output +to each type of device is discussed below. LONGLIB achieves virtual +output device independence by using only a minimum of low-level commands. +These include: initialization, a screen clear/new page command, +and drawing a vector. In addition, line types and color are utilized if +available. Graphics terminal and Ramtek output also support additional +features. Hardcopy devices which require rasterization are also supported +using the Metafile. +.p +The library is principally designed for vector (i.e. line plotting). +Lines are drawn by specifying the movement of an "electronic pen". +The color, width, and pattern of up/down motions in a line (the +line type) may be specified. The library consists of various subroutines which, +when called by a user written program, will produce line drawings on the desired +graphics device(s). The system is interactive in the sense that +the user can see and modify plots immediately (on screen devices). +The library can also produce a ~metafile which can then be processed by +programs supplied with the LONGLIB library to produce +hardcopy output on a variety of hardcopy devices. +Provisions have been incorporated for device-dependent graphics input to a +program (see ~CURSOR routines). +.p +The library is designed with several levels of graphics routine users in mind. +For the user who simply wants to obtain a plot of an array of data with a +minimum of effort, the ~MASTER routines offer a simple solution. These routines +handle opening/closing the plot package, scaling, and axis generation, etc, +a wide variety of formats. +For the user interested in more elaborate plots, access to several levels +of the plotting routines are provided. +.x LINSEQ +.x line type +.x color +.p +The LONGLIB graphics library supports both line type (such as +pen width and dot-dash patterns) and color attributes. In general, these +attributes are device dependent and specific line types or colors used on +one plotting device may appear differently on a second device. +Typically, line width is simulated for graphics terminals while line +typing relies on hardware support. A routine for software generation +of line types (LINSEQ) has been provided. + +.hl1 Machine Dependence +.x machine dependent +.p +LONGLIB was developed in a ~VAX/VMS environment and is written exclusively +in FORTRAN. While some machine-specific routines have been retained, +the present version of the library has been made as ~FORTRAN-77 compatible +as practical. Where the code is not FORTRAN-77 compatible, it is so noted +in the source code. These exceptions +were made for efficiency's sake and can be easily be modified or +be left out of the final library. The largest FORTRAN-77 incompatibilities +(outside of the Ramtek packages) occur when treating ~character ~string data +(see notes below). +.p +The auxilary, MASTER, and 3d plotting routines are FORTRAN-77 compatible +with a few minor exceptions (e.g. ~INTEGER*2 is used to save space +and some routine names exceed 6 characters). These exceptions +are noted in the source code file headers. +Routines in ~RAMLIB and ~REFLIB tend to be very machine specific +and may require extensive modification for use on other machines. +Unless specificially stated, integers are all assumed to be the standard +default machine length. On the ~VAX this is INTEGER*4. A 2's complement +representation is assumed for negative integers when specifying the +line type bit pattern (various routines and programs) and in storing the +pen motion data in the routines SYMBOL, SYM3D, and SYM3DH. +.x INTEGER*4 +.p +Some machine dependent constructs are used in the library for detection +of missing (and/or default) parameters (mainly in SYMBOL, NUMBER, +and AXIS ROUTINES). These can easily be modifed and/or adapted for +other machines. +.p +Note that when a subroutine is called with a Hollerith constant, +CALL SUB('string'), +~VAX ~FORTRAN passes the string as a ~BYTE array of ascii values. (see the +VAX FORTRAN User's Guide). ~CHARACTER variables are passed using a +different mechanism and can not be substituted. +If you wish to use a CHARACTER variable, use the %REF() function. i.e., +use CALL SUB(%REF(CHARACTER_VARIABLE)). +.x %REF() +.x character +.x byte +.p +The ~VAX extended ~FORTRAN data type "BYTE" (for an 8 bit variable) is used +in the REF and Ramtek library package. The terminal output +is via a WRITE(*,) command. +The ~cursor routines CURMOTION, CURRECT, CURBAND use the machine dependent +routine ~INXTCHR to read escape sequences from the terminal. +Note, however, that the library can be used without these cursor routines. +.x %loc() +.P +A ~VAX routine %LOC() is used in ~MVAX5D and ~VAX5D to determine the +address of an array. These routines may be modified or deleted as desired. +.p +The library contains files for VAX environment help libraries, etc. These +files can be deleted if not used. + + +.hl1 Using Longlib with Graphics Terminals +.p +One of three internal, separate packages used by LONGLIB is the +terminal screen graphics package. +The LONGLIB graphics library supports a variety of graphics ~terminal +devices which use ~Tektronix graphics formats including: +.x Selanar +.x vt100 +.x vt125 +.x vt240 +.s1 +.ls0 +.le;VT100 equipped with a Selanar GR100 or GR100+ +(Selanar Corporation, Santa Clara, Ca.) +.le;VT125 (VT100 + retrographics) +.le;VT240 and compatibles +.le;VT220 equipped with a Selanar SG220 +.le;Tektronix 4010/4014 and compatibles +.le;Tektronix 4107/4109 and compatibles +.le;Graphon GO-235 +.els +.s1 +.x PLOTVT +.x vtplot +.x newvpen +.x newvcol +Other graphics terminals can be used by appropriate modification of the +terminal driver routines (CTERM, VTPLOT, NEWVPEN, NEWVCOL). The routines +~FRAME and ~VPLOTS will also need to be modified. +Escape sequences need for terminal initialization and mode switching are +handled in the subroutine CTERM. +When plotting is not done to the terminal ~CTERM and other terminal +specific routines are +a dummy call. Note: plotting to the terminal is done by accumulating +a set of connected line segments created by ~PLOT or PLOTVT. +The line segments +are output to ~terminal only when the buffer length of 32 is exceeded or +a "pen up" occurs. +Consequently, a "pen up" should be issued to force all stored plot segments +to be output to the terminal prior to viewing screen. +.p +It is assumed that all terminals are configured in a standard fashion. +Because of the wide variety of terminal types, the specific settings +will not be given in this document. +.p +In designing the terminal driver routines, the design philosophy has been +to take advantage of the capability that many graphics terminals have to +display both text and graphics independently on the screen. That is, +the text and graphics "screens" can be independently cleared, etc. +This feature is heavily exploited in this library. +Of course not all terminals support this feature. +Terminals such as the VT240 and Tektronix 4010's do not support this feature. +In this case, the ~CTERM routine operates somewhat differently in that +it sets the terminal to graphics mode and leaves it there. +.p +Note that in the VAX environment, the SET TERM options of the terminal +driver must be properly configured. For example, +you must execute a SET TERM/FORM while in ~DCL to enable the screen clear +command to work properly. This permits a form feed to pass through to the +terminal. The NO ESCAPE qualifier should also be set to read from the +terminal. +.p +A command file, LONGLOC:CLEAR.COM, +has been provided which, when executed, will clear the screen of a VT100 +equipped with a ~Selanar card and set the ~VT100 into text mode. A simliar +routine for a ~VT125 (TCLEAR.COM) and a VT220 (VCLEAR.COM) is also provided. +These reset the graphics mode back to terminal mode and clear the screens. +The are very helpful during program development. +.p +LONGLIB also supports color on graphics terminals which permit color +plotting. + +.hl 2 Terminal Specific Application Notes +.p +The following sections describe the operation of the LONGLIB graphics +routines with some specific graphics terminal types. This list is +not comprehensive. + +.hl 3 VT100 (w/Selanar Graphics Cards) +.p +A reference to a VT100 indicates a VT100 equipped with a Selanar +equipped (GR100, or GR100+) VT100. +A SG100 equipped VT100 has three modes: the terminal (VT100) mode, the Selanar +terminal mode, and the Selanar graphics mode. The routine ~CTERM is used +to switch the terminal between modes. A call to ~FRAME +will set the mode to the Selanar terminal mode. Whenever a line is +plotted to the screen the mode is change to Selanar graphics and then +back to the Selanar terminal mode. If a program error occurs when the terminal +is in the Selanar graphics mode, it is possible to not see +any output. Running the ~CLEAR command file will reset the mode back +to terminal. The Selanar card does not provide linetypes or XOR capability +in the 4010 operation mode. + +.hl 3 VT125 +.p +A ~VT100 upgraded with the DEC upgrage package to a VT125 has two +modes used by the LONGLIB library: the normal terminal mode, and the +Tektronix 4010 graphics mode. Both text and graphics can be displayed +on the same screen but independently manipulated by swithing between +modes. +Running the ~TCLEAR command file will reset the mode back to terminal. + +.hl3 VT240 +.p +Unlike other terminals, the ~VT240 when switched between terminal modes +clears the screen. Thus CTERM sets the terminal mode to the Tektronix +4010 mode when terminal graphics are initiated. The mode is not changed. +Limited linetypes are supported though XOR plot mode is not. + +.hl 3 VT220 (w/Selanar Graphics Card) +.p +Reference to a ~VT220 terminal is intended to indicate a VT220 terminal +equipped with a Selanar SG220 graphics upgrade board. +The SG220 board operates through the VT220's printer port. In +addition, it uses some of the keys on the VT220 keyboard. It is possible +to enable the graphics board when the printer port is disabled. This causes +some of the keys (notably the keypad and cursor keys) to not work for editing, +etc. To correct this, deselect the graphics board using CNTRL-SELECT. +.p +In order for the graphics board to plot graphics commands from the library +routines, the printer port must be +in the controller mode and the board enabled. All this is automatically +handled by the LONGLIB graphics library routines. Note, however, that +you will need to use the CTERM commands correctly to obtain proper operation. +.p +The DCL command file ~VCLEAR will reset printer port, clear the graphics +card and terminal the screens under most situations. +.x getcursor +.p +When using GETCURSOR, a large cross-hair will appear on the screen. +Use the cursor keys and the shift key to move the intersection point to +the desired location and press a key. This ends the graphics input. +The cross-hair will disappear, there will be a pause, and the program +will continue. NOTE: DON'T USE THE RETURN KEY TO END GRAPHICS INPUT AS +THIS WILL CAUSE THE PROGRAM TO NOT READ THE LOCATION AND MESS UP YOUR +TYPE-AHEAD BUFFER. +.p +The SG220 board stores the starting and ending points of each vector in memory +then dynamically redraws the screen for each refresh (this is how it can do +zooming and windowing). However, this also limits the number of vectors +that can be drawn on the screen at once. +If a very large number of vectors are plotted, a zoom in/out may cause +a portion of them to not reappear. +.p +Note: Since the actual SG220 screen resolution is only 832x350 +and the board is emulating a Tektronix 4014 (4096x3200) there is some +quantization error associated with the cross-hair operation. +.p +Note: When the manual zoom in/out feature is used +the cross-hair cursor does not work properly. The cross-hair is initially +plotted then erased. When you move the cross-hair, it is replotted. +A copy of the cross-hair stays at the start location. Otherwise, it is +useable. + +.hl 3 Tektronix 4010/4014 Compatible Terminals +.x 4010 +.x 4014 +.p +A generic ~Tektronix 4010/4014 compatible terminal is defined in LONGLIB. +Linetypes are supported. +Since most ~Tektronix 4010/4014 compatible terminals do not support +dual text/graphics screens, this feature +is unavailable. + +.hl 3 Tektronix 4107/4109 Compatible Terminals +.x 4107 +.x 4109 +.p +The ~Tektronix 4107/4109 terminals support a dual (text and graphics) +screen mode which is exploited by LONGLIB. Most of the advanced features +available on these terminals are not exploited. Color and linetypes +are supported. The command file ~TEKCLR (executed from DCL) +can be used to clear the screen +and reset the terminal into the ANSI mode. + +.hl 3 Graphon Terminals +.p +The ~Graphon GO-235 is a terminal compatible with a VT100/VT200 and +Tektronix 4014. It permits both text and graphics on the same screen +in separate planes when properly configured. This configuration is +assumed by the LONGLIB graphics library. The Graphon terminal supports +linetypes, graphics input, and XOR plot mode. +A command file GCLEAR (executed +from DCL) is provided to clear the screen and reset the text mode. + +.hl1 The LONGLIB Metafile (Hardcopy Output) +.p +The second internal package used by LONGLIB is the ~metafile or +printer history file package. +The library can optionally produce a plot metafile containing +scaled, clipped pen motion commands. This "history" file +can be processed by other programs to produce hardcopy output on the +appropriate device. Using the ~REPLOT program, the plot history file can +be redisplayed on a screen device. Raster scan converter programs produce +a dot-image printable file from the metafile for printing to a dot matrix +printer. Other metafile processing programs convert the LONGLIB metafile +to other graphics description languages including POSTSCRIPT, HPGL, QUIC, etc. +.x postscript +.x hpgl +.x quic +.x stripping +.x strips +.p +Many of the LONGLIB metafile processing programs permit "striping" of the +graphics image. When the graphics image contained in the LONGLIB metafile +exceeds the size of a single page (or whatever) of the output device, the +the metafile image is "cut" into "strips" which fit on the output page. +Then each page is output. Normally, blank pages are suppressed. At the +same time redundant pen motions, changes, etc. are filtered out. + +.hl 2 Dot Matrix Printers +.x raster scan +.x dot matrix printers +.p +Dot matrix printers, in general, require graphics data in a bit-image +image format. This requires converting the LONGLIB metafile pen +motion file into a bit-image file using a raster scan process. +Using one of the supplied raster scan converter programs, the LONGLIB +metafile can be processed to produce a printable file of graphics for +several types of dot matrix printers. The raster scan converter programs +supports linetypes and widths. Currently, raster scan +converter programs which including "stripping" exist for the following +printers: +.s1 +.ls0 +.le;Printronix +.le;Trilog TIP-300 +.le;DEC LA50 (or compatible) +.els +.p +The raster scan converter programs using "stripping" with a strip +size which depends on the printer. Ordinarily the strip is 56.5 by +13.2 inches (or the width of the printer page). +To generate a raster scan data file suitable for printing on a +dot matrix printer from the vector plot command file, the +raster scan converter program must be used. Versions of this +program exist for ~LA50 printers (LA50), ~Printronix printers +(PRNTRX), and ~Trilog Printers (TRILGLO or TRILGHI--see below). +.p +Two raster scan programs have been provided for the +~Trilog printer to take advantage of its higher printing resolution. +~TRILGLO prints the same resolution on the Trilog printer as on the +Printronix printer. ~TRILGHI plots at almost twice the across-the-page +resolution and the same down-the-page resolution. Execution time is longer +for the high resolution program. +.x raster scan conversion +.p +An example of the use of the TRILGLO program in the ~VAX environment +follows. The LONGLIB metafile input is FOR003.DAT. The output +is OUT.LIS. +.lit + + $ TRILGLO :== $LONGLOC:TRILGLO + $ TRILGLO FOR003.dat ! run raster scan converter + $ print/que=Trilog OUT.LIS ! print output + +.end lit +.p +~VAX ~DCL command files in the directory pointed to by the logical name +LONGLOC: contain command files for execution of these commands. +(PLOT183.COM = printronix printer, PLOTLO.COM = trilog printer lo-res +PLOTHI.COM = trilog printer hi-res). + +.hl 3 Subprocesses +.p +Two subroutines have been provided to spawn a subprocess from +a FORTRAN program (in a ~VAX ~VMS environment) to execute the raster scan +converter programs. + +.hl4 SUBROUTINE PSUBPRO +.lit +CALL PSUBPRO(i,opt,ip) + +i (I): raster scan conversion program type + = 0 printronix printer + = 1 low res trilog printer + = 2 hi res trilog printer +opt (I): concurrent process option + = 0 wait for completion + = 1 no wait +ip (I): print flag + = 0 do not print + = 1 print + +.end lit +~PSUBPRO creates a ~subprocess using ~SUBPROC to run the raster scan conversion +program. PSUBPRO should be used with FOR003.dat file after the plot package +has been closed. The output is OUT.LIS which can be printed if desired. +The command files used are located in LONGLOC:. + +.hl 4 SUBROUTINE SUBPROC +.lit +CALL SUBPROC(in,out,i) + +in (C) : input command file name (CHARACTER variable) +out (C) : output log file (CHARACTER variable) +i (I) : concurrent processing option + = 0 wait for completion + = 1 no wait +.end lit +.p +~SUBPROC creates a ~subprocess which executes the command file IN. The output +is places in the file OUT (if OUT is NL: the output is discarded). + +.hl2 HPGL Compatible Pen Plotter +.x pen plotter +.p +Metafile conversion programs which convert the LONGLIB metafile into +an HPGL (~Hewlett-Packard graphics language) command data file +are included in LONGLIB. Three programs are available, HPGL, HPGL2, +and HPGLS. +.p +~HPGL reads the LONGLIB metafile, processes it into appropriate commands +and sends the commands to the terminal printer port (either a VT100 or VT220 +compatible terminal or a VT100 equipped with a Selanar GR100 graphics board) +to which is connected +an HPGL-compatible pen plotter. No "stripping" of the image is done. +The user is prompted for page changes. +Pen changes on the plotter occur in response to a color change in the +metafile. Line types are supported but line widths are ignored. +.p +~HPGL2 reads the LONGLIB metafile and produces a separate output file of HPGL +commands for each page of LONGLIB metafile input. HPGL2 does not +include "stripping" of the image. HPGL2 plots all of the vectors of a +given color before changing +pens. Line types are supported but line widths are ignored. +.p +~HPGLS is similar to HPGL2 but includes stripping of the image. +HPGL2 produces a separate output file of HPGL commands for each strip +and page of LONGLIB metafile input. +.p +An example of the use of the HPGL2 program in the ~VAX environment +follows. The LONGLIB metafile input is FOR003.DAT. The output +is a file, OUT.LIS which can then be sent to an HPGL-compatible plotter. +.lit + + $ HPGL2 :== $LONGLOC:HPGL2 + $ HPGL2 FOR003.dat ! run HPGL conversion program + ! several out.lis files may be produced + $ print/que=HPGL out.lis;* ! send output file(s) to plotter +.end lit + +.hl2 QMS QUIC Laser Printer +.p +Three programs, LASER, LASERS, and RLASER, are included to convert the +LONGLIB metafile into a printable file in the ~QMS ~QUIC laser printer +control language. +Line width and line types are supported though color is not. +Programs LASERS and RLASER "strip" the metafile into 8.5 by 11 page strips +while LASER does not do stripping. +~LASER and ~LASERS produce +a full size, normal orientation output, while ~RLASER scales the output +by 3/4 and rotates the page -90 deg. +.p +An example of the use of the LASER program in the ~VAX environment +follows. The LONGLIB metafile input is FOR003.DAT. The output +is OUT.LIS. +.lit + + $ QMS :== $LONGLOC:LASER + $ QMS FOR003.dat ! run QMS metafile conversion + $ print/que=QMSLASER OUT.LIS ! print output to printer +.end lit + +.hl2 PostScript +.x applewriter +.p +A program titled ~POSTSCRIPT is included which will convert the LONGLIB +meta file into a PostScript page language format. This can then be printed +to PostScript compatible printer (such as an AppleWriter). No "strips" +are used. Linetypes and width are supported. Input color changes +are output as grey tones. +.p +An example of the use of the POSTSCRIPT program in the ~VAX environment +follows. The LONGLIB metafile input is FOR003.DAT. The output +is OUT.LIS. +.lit + + $ POST :== $LONGLOC:POSTSCRIPT + $ POST FOR003.dat ! run POSTSCRIPT conversion + $ print/que=POSTSCRIPT OUT.LIS ! print output to printer +.end lit + + +.hl 2 Plotting the LONGLIB Metafile to a Screen Device +.p +A program ~REPLOT has been provided which will read the LONGLIB ~metafile +created by an eariler program and plot the file to a screen +device (terminal or Ramtek). This program may be run from DCL in the +VAX environment by: +.lit + + $ REPLOT :== $LONGLOC:REPLOT + $ REPLOT + +.end lit +Note that the default meta file name is FOR003.DAT. + +.hl1 Plotting on the RAMTEK Screen Graphics Device +.x ramtek emulation +.x ref +.p +The third internal package (which will not be available in some +installations) used by LONGLIB is the ~Ramtek Screen display package. +The plotting device is the Ramtek family of displays. +Currently, only some (but not all) of the +functions of the Ramtek 9460 (1280x1024) or 9050 (512x512) +Ramtek screen display are supported. +The Ramtek screen display can be replaced by the +Ramtek Emulation File (REF) package which simulates the Ramtek display +as an internal image array. The LONGLIB library can be configured without +the Ramtek package. +.x rplots +.x PLOTRM +.p +The Ramtek package is initialized by a call to ~FRAME (which calls RPLOTS). +When the Ramtek package is not being used, calls to Ramtek routines +are dummy calls. Note: plotting to the Ramtek is done by accumulating +a sequence of connected line segments (defined by ~PLOT or PLOTRM) +in a storage buffer. The line segments are output to the +~Ramtek only when the buffer length of 128 is exceeded or a "pen up" occurs. +Consequently, a final "pen up" should be issued to make all plot segments +are output to the display prior to viewing screen. +.p +The current version of the software drivers for the Ramtek display are +machine specific to VAX/VMS. The ~REF subpackage uses some ~VAX FORTRAN +specific constructs (for efficiency) but could easily be modified for +other machines. +.x vax/vms +.p +~Ramtek display drivers expects the logical name "RM" be assigned to Ramtek +device (example: assign RMA0: RM:). +When the Ramtek device supports multiple diplays, interaction between the +displays complicates matters. To distiguish between different displays on +the same device it is suggested that the 0th device be named xxx0:, second +device xxx1:, etc. +~Color plotting is done on the Ramtek using the previously loaded color table. +The LONGLIB "color" is the color table index. +The default Ramtek color table index is 255. The main LONGLIB package +uses only vector plotting. However, auxilary routines have been included +which permit writing image mode data to the Ramtek (or REF) and for +color table manipulation (see RMWRITEWORD or RMWRITECOL). +.x RMWRITEWORD +.x RMWRITECOL +.p +The Ramtek supports line types and scale factors but simulates line widths. + +.hl2 Ramtek Emulation File Plotting +.x ramtek emulation file +.x REF +.p +When a Ramtek display is not available or +for off-line plotting to a "simulated" Ramtek device, a set of routines +known as the ~Ramtek Emulation File (REF) routines can be used. +These routines replace the Ramtek communications routines (RAMLIB) in +a version of the LONGLIB graphics library named LONGLIBR.OLB. This software +emulates many (but not all) of the important functions of the Ramtek +communication routines to a 9460 or 9050 Ramtek +display using an internal byte array. +.p + +.hl 3 Using the REF Routines +.x RMWRITEWORD +.p +To use the REF routines, link to the LONGLIBR version of the LONGLIB library, +and plot to the Ramtek device. +The REF routines use a 1280x1024 BYTE array as the simulated Ramtek +display. Each byte of the array stores the color table index for each +pixel of the simulated Ramtek display. An empty "screen" consists +of all zeros. When a line is drawn to the +display using ~PLOT or ~PLOTRM the appropriate pixel bytes are set +to the line color. REF routines also permit image mode writing/reading +of horizontal or vertical lines of bytes (see RMWRITEWORD, for example). +When the plot package is closed (by a call to PLOTND) the user will be +prompted to output the internal BYTE array to a specific +device (a graphics terminal, a metafile, or a special REF file). To +avoid the interative prompt, the user can call ~REFDIS (with its appropriate +arguments) prior to the ~PLOTND call. This will disable the prompts. +See REFDIS for additional details. +.p +Note: the Ramtek color table routines and cursor routines are dummy calls +when using the REF routine library. + +.hl3 REF File Output +.p +The REF file consists of a direct access file with a record length of +one horizontal line of pixels. The number of records and record size +depends on the type of Ramtek chosen (RECL=1280, 1024 records for the +large Ramtek and RECL=512, 512 records for the small Ramtek). +REFDIS places each horizontal line of the output array into each +record of the REF file. +The REF file can subsequently be read by the ~REFTERM program and +plotted to the "real" Ramtek device. To produce a hardcopy output +of the REF file on a ~QMS laser printer, the program ~REFLAS reads +the file and produces a simulated gray scale image with 4 grey levels. +REFLAS prompts the user for the appropriate inputs. In the ~VAX/VMS +environment, the program ~REFLAS2 can be used. REFLAS2 provides significantly +faster run times by using the VAX paging utility and downloadable fonts. + +.hl3 REF Terminal or Metafile Output +.p +When outputing the byte array data to a terminal or printer history file, +the array is converted to a series of horizontal vectors. As the array +scanned left to right, top to bottom, all ajacent pixels of the same color +are combined into a single vector. When a pixel of a different color is +encountered the vector is output. Pixels of color "0" (background) are +not output. +See REFDIS for additional details. + + +.hl 1 Library Location +.p +All LONGLIB libraries, source files, and support programs are located in +the same directory. In the ~VAX environment, +The logical name ~LONGLOC: should be assigned to be this directory, i.e., +.lit + + $ assign disk:[directory] LONGLOC: +.end lit +.p +The LONGLIB object library is self contained. In order to link to the +normal library use the command (see also the shareable image library +section below), +.lit + + $ link ,LONGLOC:LONGLIB/LIB + +.end lit +If your installation has a Ramtek display, this link command will include +the Ramtek display routines. If your installation does not have a Ramtek +display, this link command will include only dummy routines for Ramtek +routines. In order to link to the REF version the library (which is normally +available on every installation) use the LONGLIBR.OLB object library, +.lit + + $ link ,LONGLOC:LONGLIBR/LIB +.end lit + +.hl 2 LONGLIB Source Code +.p +.x source code +.x FORTRAN +.X C +The source code for LONGLIB is all in FORTRAN and is included +in the distribution package. +Source code may be found in the following files: +.lit + +LONGLIB.FOR (device dependent routines) +AUXLIB.FOR (auxilary device independent routines) +MLIB.FOR (MASTER routines) +MLIB2.FOR (more MASTER routines) +HIDELIB.FOR (3-d hidden line routines) +LONGLIB3D.FOR (3-d w/no hidden lines) +RAMLIB.FOR (Ramtek communication code) +MAPLIB.FOR (map routines) +CURSORLIB.FOR (cursor routines) +REFLIB.FOR (Ramtek emulation file routines) +etc. +.end lit +.p +In addition, the LONGLIB support program such as the example programs, +metafile processing programs, etc., are located in LONGLOC:. + +.hl1 User Notes -- VAX/VMS Environment +.p +In the ~VAX/VMS environment LONGLIB provides an on-line help library +accessable from either a user program or DCL as well as a shareable +image library. + +.hl2 Using the LONGLIB VAX/VMS On-line HELP Library +.x help library +.p +In the ~VAX/VMS environment an on-line ~help library is available in addition to this +documentation. The On-line help library can be accessed from ~VAX DCL by, +.lit + + $ HELP @LONGLIB +or + $ HELP @LONGLOC:LONGLIB.HLB + +.end lit +.x helpme +A subroutine for accessing the library is also included +in the LONGLIB package HELPME. From a user program calling HELPME with +a ~CHARACTER string corresponding to the initial help string will call +the VAX librarian for an interactive search through the LONGLIB help library. + +.hl2 Using the LONGLIB VAX/VMS Shareable Image Library +.p +A shareable image library for the ~VAX/VMS may be created for the LONGLIB +graphics library. To obtain the most advantage from using the shareable +image library, the library must be "installed" by the system manager. +Not all installations will have an installed LONGLIB library. +Linking to the shareable image library +(LONGLIB.EXE rather than LONGLIB.OLB) produces executable files which +are small and run faster. +The main difference is in how they are linked. To link to the "normal" +library, +.lit + + $ LINK your_file_name.OBJ,LONGLIB/LIB + +.end lit +To link to the shareable image library you have to use a linker option +file: +.lit + + $ LINK your_file_name.OPT/OPT + +where your_file_name.OPT contains: + + your_file_name.obj,LONGLIB/SHARE + +or you may use the longlib linker option file: + + $ LINK your_file_name,LONGLIB/OPT + +.end lit +This second option for the linker option file is the easiest to use. +Note that the LONGLIB/OPT should be last on the link list. On most +installations, the REF version of the library, LONGLIBR, is not installed +as a shareable image library. +.p +Although the linking is somewhat more complex, the shareable image file +does allow program using the graphics library to run slightly faster and +the executeable to be significantly smaller. +.p +The shareable image library is designed to be upwardly compatible. + +.hl1 Disclaimer +.p +LONGLIB is very powerful graphics package for line-graphics. +Unfortunately, +the desire to maintain compatibility with earilier LONGLIB versions +has resulted in less than optimal design decisions. There are, however, +some incompatibilities with earlier versions of LONGLIB; notably +the color array used in AXIS, AXIS2, and AXIS, the working space +specifications of PLT3D and NXTVU, and metafile internal format which +results in the fact that previous metafile processing programs will +not work with new metafiles and vice versa. +.p +LONGLIB was developed in the ~VAX ~VMS environment. +With the possible exception of the Ramtek package routines, every +attempt has been to keep LONGLIB FORTRAN-77 compatible and machine +independent with the exceptions previously noted. No claim is made +regarding the transportability of LONGLIB to non-VAX machines. It is +felt, however, that only small modifications would be required. +.p +As with any software system, there may be bugs in either the documentation +or software though every attempt to eliminate them has been made. + +.CHAPTER Programming Examples +.p +In this chapter several ~examples of using some of the basic plotting +routines of this library are included. The ~VAX environment permits +the linking of object code segments compiled from different languages. +Thus, examples for both ~FORTRAN and ~C routines are shown. + +.hl1 FORTRAN Programming Examples +.p +For the user interested in obtaining very simple plots of curves without +being concerned with the details of LONGLIB, the ~MASTER routines provide +the most simple approach. Greater control of the output plot can +be obtained by customizing user version of MASTER-like routines from +the auxilary routines. + +.hl2 Simple MASTER Routine Example +.p +A very simple example of using the ~MASTER routines of this library is shown +below. For more detailed examples see the following sections. +.p +This example plots a +damped sine wave on both the terminal screen, the Ramtek (in color), +and the LONGLIB metafile. +The master routine ~PLOTSC handles all graphics intialization and +closing. (See the chapter on MASTER routines for additional details). +.TP 16 +.lit + + DIMENSION X(100),Y(100) + DATA P,U,PL,A,B,PHI/112,85,25.,.013,.3/ + DATA PI/3.141593/ +C FILL DATA ARRAYS + DO 10 I=1,100 + X(I)=I-1 + Y(I)=SIN((I-1)*PI/A+PHI)*EXP(-I*B) + 10 CONTINUE +C CALL LONGLIB PLOTTING ROUTINE TO PLOT CURVE. +C OUTPUT ONLY 35 OF THE 100 POINTS ON A 6X5 PLOT WITH TITLE +C AND A GRID. iflag IS SET TO PROMPT FOR A SCREEN OUTPUT DEVICE. +C NOTE THAT WHEN A MASTER ROUTINE INITIALIZES LONGLIB, A +C METAFILE IS ALWAYS PRODUCED. + CALL PLOTSC(X,Y,100,5,6.,5.,'X TITLE',7,'Y TITLE',7, + 1 'TOP TITLE',-10) + STOP + END + +.end lit + +.hl2 Lower Level Routines +.p +An example of using the auxilary routines of LONGLIB library from +~FORTRAN is illustrated below. +An example for using this library from ~C follows. +.p +This example plots a damped sine wave on both the terminal screen, +the Ramtek (in color), and the LONGLIB metafile. No MASTER +routines are used. +.lit + + PROGRAM DEMO + DIMENSION X(100),Y(100),ICOL(3) + DATA P,U,A,B,PHI/112,85,25.,.013,.3/ +C ICOL IS THE COLOR ARRAY FOR AXES + DATA PI/3.141593/,ICOL/1,2,3,4/ +C FILL DATA ARRAYS WITH Y=F(X) + DO 10 I=1,100 + X(I)=I-1 + Y(I)=SIN((I-1)*PI/A+PHI)*EXP(-I*B) + 10 CONTINUE +C INITIALIZE LONGLIB WITH SCREEN PROMPT OPTION +C AND CREATE METAFILE TO FORTRAN UNIT 3. + CALL FRAME(3,0,2.,2.,1.) +C COMPUTE SCALING FACTORS FOR X AND Y + CALL SCALE(X,8.,100,1,1,XMIN,DX) + CALL SCALE(Y,6.,100,1,1,YMIN,DY) + Y0=-YMIN/DY +C PLOT COORDINATE AXISES WITH COLOR OPTION ENABLED + CALL AXIS(0.,Y0,'X-AXIS',-6-100000,20.,0., + 1 XMIN,DX,N1,N2,ICOL) + CALL AXIS(0.,0.,'SINE',4+100000,17.,90., + 1 YMIN,DY,N1,N2,ICOL) +C SET LINE COLOR + CALL PLOT(5.,0.,0) +C PLOT DATA POINTS AS A LINE WITH SYMBOLS + CALL LINE(X,Y,100,1,5,2,1,1,XMIN,DX,YMIN,DY) +C PICK UP PEN AT END OF LINE (FORCES OUTPUT TO SCREENS) + CALL PLOT(0.,0.,3) +C PROMPT FOR SCREEN CLEAR ON RAMTEK/TERMINAL + CALL CTERM(2) + CALL RTERM(2) +C CLOSE LONGLIB + CALL PLOTND + STOP + END +.end lit + +.hl 1 C Language Programming Example +.x c language +The following is an illustration of how to use lower level LONGLIB +routines to produce a plot from ~VAX C. +.tp15 +.lit + +/* Example in VAX C */ + +main +{ + real x[100],y[100],dx,xmin,dy,ymin; + real exp(),sin(),y0; + int icol[4] = 1 , 2, 3, 4; + int i,n1,n2; + real pi = 3.141592654; + real p = 112., u = 85., a = 25., b = .013, phi = .3; + + for (i = 1; i < 100 ; i++) { + x[i] = i - 1; + y[i] = sin( (i-1) * pi / a + phi) * exp(-i * b); + } + frame(&3,&-3,&0.,&0.,&1.); /* Initialize */ + scale(x,&8.,&100,&1,&1,&xmin,&dx); + scale(y,&6.,&100,&1,&1,&ymin,&dy); + y0 = -ymin / dy; + plot(&2.,&2.,&-3); /* new origin */ + axis(&0.,&y0,"X-AXIS",&-6-100000,&20.,&0.,&xmin,&dx,&n1,&n2,icol); + axis(&0.,&0.,"SINE",&4+100000,&17.,&90.&ymin,&dy,&n1,&n2,icol); + plot(&4.,&0.,&0); /* new color */ + line(x,y,&100,&1,&5,&2,&1,&1,&xmin,&dx,&ymin,&dy); + plot(&0.,3&0.,&3) /* pen up */ + cterm(&2); /* ask if screen clear */ + plotnd; /* terminate plotting */ + +} +.end lit + +.hl1 MASTER Routine Examples (FORTRAN) +.P +The subsections that follow illustrate additional examples of how to use +MASTER routines from FORTAN. + +.hl2 Adding Additional Annotation to a MASTER Routine Plot +.X PLOTSC +.x plottests +.p +The following is an ~example of using a MASTER +subroutine more than once and/or adding additional text or +another plotting line and/or two MASTER subroutines: (see also the +program PLOTTESTS) +.TP16 +.S1 +.lit + ... +C INCLUDE PLOTSC ROUTINE COMMON BLOCK WHICH RETURNS +C SCALE FACTORS USED IN PLOTTING + COMMON /CPLOTSC/XMR,DXR,YMR,DYR + ... +C CALL PLOTSC WITH -10000 iflag < 0 TO INITIALIZE LONGLIB +C BEFORE CALL BUT NOT CLOSE LONGLIB AFTER CALL +C SET iflag TO PROMPT FOR SCREEN DEVICE TYPE WITH TICKED GRID + CALL PLOTSC(X,Y,25,4,8.,6.,'X AXIS',6, + 1 'Y AXIS',6,'TITLE',-5,ICOL) +C PUT GRAPHICS TERMINAL IN GRAPHICS MODE + CALL CTERM(-1) +C PLOT ADDITIONAL TEXT AFTER PLOT TITLE + CALL SYMBOL(999.,999.,0.15,' TEXT',0.,5,-1) +C PLOT ADDITIONAL ANNOTATION ABOVE PLOT + CALL SYMBOL(0.0,6.5,0.15,'NUMBER=',0.,7,-1) +C ADD NUMBER AFTER ANNOTATION WITH 3 DIGITS AFTER DECIMAL PT. + CALL NUMBER(999.0,999.0,0.15,3.1415,0.,3,-1) +C CHANGE LINE TYPE TO DOTTED + CALL NEWPEN(1) +C ADD ANOTHER LINE OF DATA ON PLOT USING PLOTSC SCALE FACTORS + CALL LINE(X,Y2,N,1,0,0,1,1,XMR,DXR,YMR,DYR) + ... +C ASK IF SCREEN CLEAR ON TERMINAL (METAFILE NOT AFFECTED) + CALL CTERM(2) + CALL PLOTND + ... +.end lit + +.hl2 Using Multiple MASTER Routines in the Same Program +.x plottests +.p +The following is an ~example of how to use several MASTER +subroutines in the same program. (see also the program PLOTTESTS) +The basic idea is to use the first call to a MASTER routine to +initialize the LONGLIB graphics library. On later calls to MASTER +routines you must use "iflag" to instruct the routine NOT to +re-initialize LONGLIB. The last call to a MASTER routine closes +LONGLIB. +.x PLOTLG +.x PLOTSC +.tp16 +.S1 +.lit +C FIRST CALL TO MASTER ROUTINE, SET -10000 < iflag < 0 +C TO INITIALIZE LONGLIB BUT NOT CLOSE IT +C SET iflag TO PROMPT FOR SCREEN DEVICE TYPE WITH +C AXIS ON TOP AND SIDES AND NO GRID + CALL PLOTSC(X,Y,N,-1,...) + ... +C SECOND CALL TO MASTER ROUTINE, SET iflag < -10000 TO +C PREVENT INITIALIZING LONGLIB OR CLOSING IT +C SET iflag TO PRODUCE AXIS TICKED GRID (SINCE +C LONGLIB OPEN, NO PROMPT FOR SCREEN DEVICE) + CALL PLOTSC(X,Y,N,-10004,...) + ... +C LAST CALL TO MASTER ROUTINE, SET iflag > 10000 TO +C PREVENT INITIALIZING LONGLIB AND CLOSE IT AFTER PLOTTING +C SET iflag TO PRODUCE AXIS TICKED GRID AND LOG/LOG FORM +C (SINCE LONGLIB OPEN, NO PROMPT FOR SCREEN DEVICE) + CALL PLOTLG(X,Y,N,10053,...) +.end lit + +.HL2 MASTER Routine Color Example +.x PLOTSC +.p +The following is a very elaborate example of how to use color in a particular +MASTER routine (PLOTSC). +.tp16 +.s1 +.lit +C DIMENSION AND LOAD COLOR ARRAY + DIMENSION ICOL(6) + DATA ICOL/1,2,3,4,5,6/ + ... +C CALL PLOTSC WITH NUMBER OF TITLE CHARACTERS NEGATIVE TO +C USE COLOR ARRAY. SET iflag TO INITIALIZE/CLOSE LONGLIB +C SET iflag TO PRODUCE AXIS TICKED GRID + CALL PLOTSC(X,Y,25,4,8.,6.,'X AXIS',6, + 1 'Y AXIS',6,'TITLE',-5,ICOL) + ... +.end lit + +.PG +.HL2 Using Multiple MASTER Plots on Same Page/Screen +.x PLOTSC +.p +The following is a very elaborate example of how to to place several +MASTER routine plots on the same Ramtek and terminal screen but different +metafile pages. +.tp16 +.s1 +.lit +C OPEN LONGLIB OUTSIDE OF MASTER ROUTINE +C SELECT BOTH TERMINAL AND RAMTEK SCREEN OUTPUT WITH NO +C SCREEN CLEAR ON RAMTEK OR TERMINAL + CALL FRAME(3,-3,1.,1.,1.) +C CHANGE COLOR AND ADD A SEPARATE PLOT TITLE + CALL PLOT(7.,0.,0) + CALL SYMBOL(6.,11.5,.3,'TITLE',0.,5,-1) +C CHANGE ORIGIN AND SHRINK SUBSEQUENT PLOTS ON RAMTEK/TERMINAL +C BUT NOT METAFILE + CALL PLOT(1.,1.,-3) + CALL VFACTOR(.5) + CALL RFACTOR(.5) +C LOOP TO PLOT FOUR MASTER PLOTS ON ONE SCREEN + DO 10 I=1,4 +C CALL PLOTSC WITH iflag < 10000 TO NOT INITIALIZE +C LONGLIB OR CLOSE IT AFTER PLOT +C SET iflag TO PRODUCE AXIS TICKED GRID +C (SINCE LONGLIB OPEN, NO PROMPT FOR SCREEN DEVICE) + CALL PLOTSC(X,Y,25,-10004,8.,6.,'X AXIS',6, + 1 'Y AXIS',6,'TITLE',5) +C MOVE ONLY RAMTEK AND TERMINAL ORIGINS BUT NOT METAFILE + CALL PLOTRM(0.,2.*5.,-3) + CALL PLOTVT(0.,2.*5.,-3) + IF (I.EQ.2) CALL PLOTRM(11.,-20.,-3) + IF (I.EQ.2) CALL PLOTVT(11.,-20.,-3) +C NEWPAGE ON METAFILE (DOES NOT AFFECT TERMINAL/RAMTEK) + CALL NEWPAGE +10 CONTINUE + ... +C PROMPT FOR SCREEN CLEAR ON RAMTEK/TERMINAL + CALL CTERM(2) + CALL RTERM(2) +C CLOSE LONGLIB + CALL PLOTND + ... +.end lit + + +.CHAPTER Description of Plotting Routines +.p +This chapter details the central LONGLIB graphics library routines. +A brief description of each routine is shown along with an example +of its call and a description of the required parameters. +Optional parameters are shown in <> brackets. +.p +The name of each parameter is followed by a letter indicating +the variable type. Unless otherwise specified, integers are the +default integer length of the machine (which is ~INTEGER*4 on the VAX). +.x byte +.x integer +.x real +.x character +.x logical +.LIT + + B = BYTE array string (see notes in section 1.2) + I = INTEGER + R = REAL + C = CHARACTER + L = LOGICAL + +.end lit + +NOTE: In ~VAX ~FORTRAN, +when a subroutine is called with a Hollerith constant such +as 'string', CALL SUB(... ,'string', ...), +VAX FORTRAN passes the string as a +BYTE array of ~ASCII values. A CHARACTER variable can not be substituted. +If you wish to use a CHARACTER variable, use %REF() to convert the +CHARACTER variable to a BYTE array, i.e., +call SUB(..., %REF(CHARACTER_VARIABLE), ...). +.x %REF() +.p +Lengths are given in the standard plot units of inches. The routine +~FACTOR can be used to change the plot unit length. Angles are specified +in degrees counter-clockwise from the x axis. +.p +Unless specifically +noted all parameters passed into a routine via the call statement will +be used on a "read-only" basis, i.e., they will not be modified by the +routine. + +.hl1 SUBROUTINE ABSPLT +.p +The routine ~ABSPLT changes the ABSOLUTE (versus relative as in PLOT) +rotation angle and scale factor of the metafile, terminal, and ~ramtek +plot routines to the values specified. Normally, the routine ~PLOT should be +used to change the origin, rotation angle, or scale factor. This routine +is provided for a skilled user to use in error recovery. Note, however, +that no error checking is provided in ABSPLT. +.lit + +CALL ABSPLT (x,y,a,z) + +x,y (R): coordinates of new absolute origin (in inches) +a (R): new absolute angle CCW from horizontal in degrees +z (R): new absolute scale factor +.end lit + +.hl1 SUBROUTINE ARROW +.p +~ARROW plots a vector arrow at any desired point and with any desired +angle. The type of arrowhead drawn may be selected. +.lit + +CALL ARROW (x,y,al,a,p,b) + +x,y (R): location coordinates for vector-arrow tail +al (R): length of arrow in plot units + if al=0, only a single point at (x,y) is output +a (R): angle from horizontal at which the arrow is to be drawn + (deg counterclockwise) +p (R): length of arrowhead in plot units + > 0 open arrowhead ( --> ) + = 0 no arrowhead + < 0 closed arrowhead ( -|> ) +b (R): angle between arrowhead side and arrow line (deg) +.end lit + +.hl 1 SUBROUTINE AXIS +.p +~AXIS plots a single coordinate axis with numeric labels at any desired +location and angle. The routine has to be +called separately for the x and y axis. A possible exponent +is determined and placed at the end of the axis title in the form +of 10**n. In order to leave room for the labelling the +axis should be removed at least by 3/4 inch from the edge of the plotter page. +The length of the axis should be integer-valued. The (i)th (i=0 to ml-1) +axis major tick is labeled with the value, xm+dx*i. +For a log axis see LGAXS. +.lit + +CALL AXIS (x,y,s,n,al,a,xm,dx<,nm,ml<,ic>>) + +x,y (R): location of starting point of the axis +s (B): alpha string containing the axis title +n (I): number of characters in the string s + > 0 : axis labelling on positive side (anti-clockwise) + < 0 : axis labelling on negative side (clockwise) + (100's digit) = 0 : coordinate line, ticks and labels drawn + = 1 : line and ticks only--no labeling + (1000's digit) = 0 : numeric labels paralel to axis line + = 1 : numeric labels orthogonal to axis line + (10000's digit) = 0 : additional optional parameters ignored + = 1 : additional optional parameters used + (100000's digit) = 0 : color list ignored + = 1 : color list used +al (R): length of axis in plot units (real number, integer-valued) + > 0 : tick marks placed on same side of axis as title + = 0 : no action (return with no plotting) + < 0 : tick marks placed on opposite side of axis from title +a (R): angle at which the coordinate axis is to be drawn +xm (R): value of first marking on the axis +dx (R): increment for numeric axis labels +(NOTE: the following optional parameters are needed only if + the magnitude of n is > 10000) +mn (I): minor tick marks between labeled major ticks + if not specified, 0 is used +ml (I): number of labeled major tick marks + if not specified, int(l) is used +ic (I): array of color values, if color not enabled, + current color is unchanged + ic(1) : color value for axis line and ticks + ic(2) : color value for numbers on axis + ic(3) : color value for axis label + (color upon return if no exponent plotted) + ic(4) : color for auto exponent scale + (color upon return if exponent shown) +.end lit + +.hl1 SUBROUTINE AXIS2 +.p +~AXIS2 is similar to AXIS but allows additional flexibility to draw +different tick sizes and types. +Optionally, a possible exponent +is determined and placed at the end of the axis title in the form +of 10**n. In order to leave room for the labelling the +axis should be removed at least by 3/4 inch from the edge of the plotter page. +The length of the axis should be integer-valued. The (i)th (i=0 to ml-1) +axis major tick is labeled with the value, xm+dx*i. +AXIS2 plots a coordinate axis and its markings at any desired location +and angle. +For a log axis see LGAXS. +.lit + +CALL AXIS2 (x,y,s,n,al,a,xm,dx<,nm,nn,ml,ts,nd,sm<,ic>>) + +x,y (R): location of starting point of the axis +s (B): alpha string containing the axis title +n (I): number of characters in the string + > 0 : axis labelling on positive side (anti-clockwise) + < 0 : axis labelling on negative side (clockwise) + (100's digit) = 0 : coordinate line, ticks and labels drawn + = 1 : line and ticks only--no labeling + (1000's digit) = 0 : numeric labels paralel to axis line + = 1 : numeric labels orthogonal to axis line + (10000's digit) = 0 : optional parameters ignored + = 1 : optional parameters used + (100000's digit) = 0 : color list ignored + = 1 : color list used +al (R): length of axis in plot units (real number, integer-valued) + > 0 : tick marks placed on same side of axis as title + = 0 : no action (return with no plotting) + < 0 : tick marks placed on opposite side of axis from title +a (R): angle at which the axis is to be drawn +xm (R): value of first marking on the axis +dx (R): increment for the axis markings +(NOTE: the following optional paramters are needed only if + the magnitude of n is > 10000) +nm (I): number of minor tick marks between major ticks, + if not specified, 0 is used +nn (I): nn-th minor tick is high-lited in length, if + not specified, 0 is used (none) +ml (I): number of labeled major tick marks, if not specified + then one major tick per inch is used + < 0 use following additional optional parameters used + > 0 use following additional parameters ignored +(NOTE: the following optional paramters are needed only if + the magnitude of n is > 10000 and ml < 0) +ts (R): character size of title and numbers, if not + specified, 0.15 is used + > 0 auto exponent scaling (x10 to power) is enabled + < 0 auto exponent scaling (x10 to power) disabled +nd (I): number of digits to right of decimal point, if not + specified 1 is used +sm (R): major tick length, if not specified 0.1 is used + note that minor tick length is 1/2 major tick length +ic (I): array of color indexes for axis colors + ic(1) : color value for axis line and ticks + ic(2) : color value for numbers on axis + ic(3) : color value for axis label + (color upon return if no exponent plotted) + ic(4) : color for auto exponent scale + (color upon return if exponent shown) +.end lit + +.hl 1 SUBROUTINE AXIS3 +.p +~AXIS3 plots a single axis and its markings at any desired location and +angle. Optionally, a possible exponent +is determined and placed at the end of the axis title in the form +of 10**n. The length of the axis can take any value. The (i)th (i=0 to ml-1) +axis major tick is labeled with the value, xm+i*(xx-xm)/le. +This version of axis is more flexible than other versions +and permits specifying the axis number labeling format. +For a log axis see LGAXS. +.lit + +CALL AXIS3 (x,y,s,n,al,a,xm,xx,t,c,f,ic) + +x,y (R): starting location of the axis +s (B): alpha string containing the axis title +n (I): number of characters in the string + > 0 : axis labelling on positive side (anti-clockwise) + < 0 : axis labelling on negative side (clockwise) + (100's digit) = 0 : coordinate line, ticks and labels drawn + = 1 : line and ticks only--no labeling + (1000's digit) = 0 : numeric labels paralel to axis line + = 1 : numeric labels orthogonal to axis line + (100000's digit) = 0 : color list ignored + = 1 : color list used +al (R): length of axis + > 0 : tick marks placed on same side of axis as title + = 0 : no action + < 0 : tick marks placed on opposite side of axis from title +a (R): angle at which the axis is to be drawn +xm (R): value of first marking on the axis +xx (R): value of last marking on the axis +t (R): number of tick marks + specification is coded in the form MMM.mmss where + MMM is the number of major tick marks ( MMM > 0), mm is + the number of minor tick marks between major tick marks + (100 > mm => 0), and ss is the number of subminor tick + marks between minor tick marks (100 > ss => 0). + (example 1.0102 produces I_._._i_._._I) +c (R): size of characters + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +f (R): axis number label format (see NUMBER) + Note: if an integer -1 is passed in place of f, AXIS3 + will used f=1003.00 if autoscaling is enabled. If an + integer 0=a1) + if a2-a1=360 a full circle is used otherwise + the area is a pie segment +l (I): shade format control + = -3 : clear area and outline + = -2 : clear area + = -1 : clear outline + = 0 : no action + = 1 : draw outline + = 2 : shade area + = 3 : shade area and outline +d (R): distance between shading lines +t (R): angle of shading lines in degrees +w (R): working array dimensioned at least 3*n where + n=int((a2-a1)/(180*atan(s/r)/pi)+1) +m1 (R): line type of shading + < 0 : shading done with current line type + => 0 : new line type (see NEWPEN) +m2 (R): line type for area outline + < 0 : use prior line type + => 0 : new line type (see NEWPEN) +.end lit + +.hl1 SUBROUTINE CTERM +.p +~CTERM is the central subroutine for controling the state of the graphics +terminal. It is used to switch a graphics terminal +in and out of the graphics and text modes. It is a dummy call when not in +~terminal plotting mode. Note that not all options are available on all +terminals. Results of operation of this routine is thus terminal dependent. +In some cases the graphics and text modes are the same while in others, +the mode is switched only at init/de-init. +See the introduction to the documentation under terminal types. +.p +Note: for CTERM(2), the user will be prompted for a "clear screen". +The reply may be "Y" for yes, "N" for no (the default), "Q" (quit), +"S" (skip one), "P" (pass many), or "D" (dump). "Y" and "N" clear +the screen as indicated and the program continues normally. +A reply of "Q" permanently disables terminal screen plotting until +the package is reinitialized by FRAME. A replot of "S" disables +screen plotting until the next CTERM(2) call whereupon the +"clear screen" prompt reappears as before. A reply of "P" is similar +to "S", but the user will be prompted for the number of ~CTERM(2) calls +to pass before reissuing the prompt. In this manner multiple terminal +screen "pages" can be skipped. A reply of "D" will enable a dump +of the screen to the attached terminal printer (if supported on the +particular terminal/printer). Note that during a skip that any changes +of origin by PLOT, scale factors by FACTOR or VFACTOR, or pen color +or linetype will NOT take place. +.lit + +CALL CTERM (iarg) + +iarg (I): terminal operation code + = 0 : initialize graphics mode on terminal + = 1 : return terminal from graphics to text mode + =-1 : return terminal text to graphics mode + = 2 : return terminal to text mode, and prompt + user for clear screen (see note above) + =-2 : return terminal to text mode, clear graphics screen + = 3 : clear text screen, leave in text mode + =-3 : clear graphics screen, leave in terminal mode + = 4 : dump graphics screen to printer + =-4 : clear text, graphics, leave in graphics mode + = 5 : turn off graphics screen, return to text mode + =-5 : turn on graphics screen, return to graphics mode + = 6 : toggle reverse video + = 8 : de-initialize graphics terminal +.end lit + +.hl 1 SUBROUTINE DASHL +.p +.x software line type +.x line type +~DASHL plots a software-generated dashed ~line through the coordinate points +stored in x and y. See also LINE. +.lit + +CALL DASHL (x,y,n,k,j,l,ix,iy,xm,dx,ym,dy) + +Parameter list description same as LINE. +.end lit + +.hl SUBROUTINE ELLIPSE +.p +~ELLIPSE will plot all or part of a parametric ellipse of the form, +.lit + + (x,y) = (maj*cos(t), min*sin(t)) + +.end lit +where maj and min are the major and minor ellipse axes, respectively +and where t is the parametric angle specification. Part of the ellipse +can be plotted by specifying only part of the range of t. +The major axis center line is offset by the angle am. +The angles ast and aend define the starting and ending +angles for t. Note that aend should be greater than ast. +The ellipse is approximated by short, straight line segments. The number +and length of the segments depend on the size of the ellipse. +.lit + +CALL ELLIPSE (x,y,maj,min,am,ast,aend) + +x,y (R): center of ellipse (halfway between foci) +maj (R): length of semi-major axis (distance between center and + curve through one focus) +min (R): length of minor axis (distance between center and + curve perpendicular to semi-major axis) +am (R): angle of semi-major axis from horizontal + (deg counter-clockwise) +ast (R): start angle of curve from semi-major axis + (deg counter-clockwise) +aend (R): end angle of curve from semi-major axis + (deg counter-clockwise) note: aend > ast +.end lit + +.hl SUBROUTINE FACTOR +.p +Positional information is usually expressed in inches. A conversion ~factor +can be given for other units, such as "cm". The new coordinate values are +derived from the product "fac*x" where x is the input value. +A negative value or zero resets the +scaling factor to unity. Note that the initial factor can be specified +in FRAME. The subroutine ~FACTOR calls PFACTOR, RFACTOR, and VFACTOR which +change the scale factors for the metafile, Ramtek, and terminal +packages, respectively. These routines can be called separately to +affect only the scale factor of the particular package. +.x FRAME +.x PFACTOR +.x RFACTOR +.x VFACTOR +.lit + +CALL FACTOR (fac) + +fac (R): new conversion factor for coordinate values (all packages) + <= 0 : scale factor reset to unity + > 0 : new scale factor +.end lit + +.hl SUBROUTINE FRAME +.p +.x Selanar +.x vt100 +.x vt125 +.x vt240 +.x vt220 +.x Tektronix 4010/4014 +.x Tektronix 4107/4109 +~FRAME initializes the graphics metafile/terminal/Ramtek software and +resets internal variables. This routine is usually the first LONGLIB +routine called (also see ~PLOTS which calls FRAME). FRAME must be activated +before plotting calls are issued by the user program. FRAME should +normally be called only once in a program. MASTER routines optionally +handle the FRAME call. +.p +FRAME intializes the graphics output device packages. The FORTRAN +unit number used for the LONGLIB metafile can be specified. Normally, +unit 3 is used. If unit 0 is specified, FRAME will prompt the user +for a yes/no response to create a metafile. A negative unit number +disables the metafile package. All calls to metafile routines (such +as PPLOT) are dummy calls when the metafile package is disabled. +.p +FRAME also initializes the screen graphics device. A screen device +code is used to determine whether the Ramtek or Terminal screen device +packages are open. If a negative value for the screen device code +is used the screen device is not cleared prior to use, otherwise it is. +If the screen device code is +/- 4, no screen device package is used and +all calls to screen +specific routines (such as PLOTRM or PLOTVT) are dummy calls. +If a screen device code of 0 is used, the user is prompted for +a screen device to use. The screen devices may then be selected using +a character code. +A reply of "?" will list the available options. +.p +FRAME also intializes the origin and scale factor for plotting. +The default origin on the ~terminal and the ~Ramtek is the lower +left of screen (0.,0.). The +X axis runs horzontally, while the Y axis runs vertically. The +default origin on the printer is the upper left corner of page. +The X axis runs vertically down page, while the Y axis runs +horizontally across the page. +.p +When the ~Ramtek Screen device is selected, FRAME opens a +communications channel to the Ramtek. +If no channel is available or the Ramtek is in use an +error message is typed and the calling program is terminated. +.lit + +CALL FRAME (pl,id,vpx,vpy,zom) + +pl (I): Fortran file unit number (normally 3) used for LONGLIB + Metafile. If pl < 0 then no metafile is generated. + If pl = 0 then the user will be prompted for a yes/no + metafile. In this case unit number used will be 3. +id (I): Screen device code number. + < 0 : Do not clear Ramtek/terminal screens prior to use. + > 0 : Clear Ramtek/terminal screens prior to use. + = 0 : Prompts user for which screen device to use. + A ? response will list the available devices. + = 1 : Use VT100 as Screen Output (only) (Selanar GR100) + = 2 : Use Ramtek as Screen Output (only). + = 3 : Use both Ramtek and VT100 as Screen Output. + = 4 : Do not produce Screen output. + = 5 : Use VT125 as Screen Output (only) + = 6 : Use VT100 as Screen Output (only) (Selanar GR100) + = 8 : Use VT240 as Screen Output (only) + = 9 : Use VT220 as Screen Output (only) (Selanar SG220) + =10 : Use Tektronix 4010/4014 as Screen Output + =11 : Use Tektronix 4107/4109 as Screen Output + (color Tektronix) + =12 : Use Graph-On GO-235 as Screen Output +vpx, (R): relative x,y offset of the bottom left hand corner of +vpy the screen/page. Equivalent to PLOT(vpx,vpy,-3). +zom (R): The value of 'zom' scale factor. (see FACTOR) +.end lit + +.hl 1 SUBROUTINE GRID +.x LGRID +.p +~GRID plots a ~Cartesian grid or solid lines or ticks at +grid intersections. See also LGRID. +.lit + +CALL GRID (x,y,dx,dy,nx,ny) + +x,y (R): coordinates in the bottom left corner of grid +dx,dy (R): spacing of grid lines in x and y directions +nx,ny (I): number of grids in x and y direction + if nx > 0 and ny > 0 then solid grid plotted + if nx < 0 or ny < 0 then tick grid plotted + if nx < 0 and ny < 0 then boxed tick grid plotted +.end lit + +.hl1 SUBROUTINE HLT3D +.p +.x PLT3D +.x 2-d surface plotting +~HLT3D plots a 2 dimensional array to produce a 2-d histogram similar +to PLT3D. Hidden lines are supressed. +Transformation from the array indices (i,j) to (x,y,z) is: +.lit + + x = xl * .5 * float(2*j-n-1)/float(n-1) + y = yl * .5 * float(2*i-m-1)/float(m-1) + z = zs * (a(i,j) + z0) + +Thus, + + (1,1) is (-xl/2,-yl/2) (m,1) is (-xl/2,+yl/2) + (1,n) is (+xl/2,-yl/2) (m,n) is (+xl/2,+yl/2) + + xplotted = x*cos(az) - y*sin(az) + x0 + yplotted = x*sin(az)*sin(al) + y*sin(az)*sin(al) + z*cos(al) + y0 +.end lit +.p +The common block ~PLT3B returns these ~transformation parameters so +that the plotted location (xp,yp) of the corner of the cube corresponding +to the point (i,j,zr) may be computed as: +.lit + + xp = a1 * j + a2 * i + a3 + yp = b1 * j + b2 * i + b3 * zr + b4 +.end lit +.p +The dimension of the working array is dependent on the +surface complexity -- the greater the surface complexity, the greater +l2 must be. As a minimum, l2 > 4*min(m,n). See also ~NXTVU and PLT3D. +.x PLT3D +.lit + +CALL HLT3D (a,md,nd,m,n,w,l,w2,l2,al,az,xl,x0,yl,y0,zs,z0,ierr) + +a (R): array of values to be plotted dimensioned a(md,nd) +md,nd (I): array dimensions +m,n (I): size of data in array to be plotted +w (R): dummy variable so that call is compatible with PLT3D +l (I): dummy variable so that call is compatible with PLT3D +w2 (R): working storage array dimensioned w2(l2) +l2 (I): working storage array dimension (see note) +al (R): viewing altitude angle (deg) +az (R): viewing azimuth angle (deg) +xl,yl (R): length of unprojected axes in plot units +x0,y0 (R): plot origin in plot units +zs (R): z coordinate scale factor +z0 (R): z coordinate offset +ierr (I): (returned) error code + = 0 : ok + = 1 : l2 not large enough in NXTVU + +COMMON /PLT3B/ a1,a2,a3,b1,b2,b3,b4 +.end lit + +.hl 1 SUBROUTINE HELPME +.p +~HELPME calls the ~VAX ~VMS interactive ~help utility for the LONGLIB help +library with an initial help request string. The librarian is interactive +so that the user is prompted for additional input until a control-Z +is typed at which point control is returned to the calling program. +.lit + +CALL HELPME(s) + +s (C): initial help request string +.end lit + +.hl 1 SUBROUTINE JPLTAG +.p +~JPLTAG plots the JPL logo (JPL). Optionally, it can produce only a line +outline or fill the outline with a line pattern using SHADE. +.lit + +CALL JPLTAG (x,y,h,a,i,d,m,sa,w) + +x,y (R): coordinates of the lower left corner of the initial j +h (R): letter height in plot units +a (R): angle of baseline relative to horizontal +i (I): option flag + (1's digit) = 0 no action + = 1 draw outline only + = 2 draw shading only + = 3 shade area and draw outline + (10's digit) = pen color (if = 0, pen color is not changed) +d (R): distance between shading lines +m (I): shading line type + => 0 line type (see NEWPEN) +sa (R): angle of shading lines +w (R): working array dimensioned at least w(56+54*H) +.end lit + +.hl 1 SUBROUTINE LGAXS +.p +~LGAXS plots a single ~logarithmic coordinate ~axis. Complete +decades are produced. See also ~AXIS and LGLIN. +.x LGLIN +.lit + +CALL LGAXS (x,y,s,n,al,a,nmin,dx<,ic>) + +x,y (R): location starting point of the axis +s (B): axis label string +n (I): number of characters in string + > 0 : label on positive side + < 0 : label on negative side + (100's digit) = 0 : coordinate line, ticks and labels drawn + = 1 : line and ticks only--no labeling + (1000's digit) = 0 : numeric labels paralel to axis line + = 1 : numeric labels orthogonal to axis line + (10000's digit) = 0 : color list ignored + = 1 : color list used +al (R): length of axis + > 0 : axis ticks placed on same side of axis as title + = 0 : no action (return with no plotting) + < 0 : ticks placed on opposite side of axis from title +a (R): angle at which the axis should be plotted +nmin (R): number to be printed at the first axis tick (power of ten) +dx (R): scaling factor in the form dx=(nmax-nmin)/l where + nmax, nmin are the exponent powers at the start + and end of the axis +ic (I): color array (required if mag(n)>10000)) + ic(1) : color for axis line and ticks + ic(2) : color for numbers + ic(3) : color for axis title +.end lit + +.hl 1 SUBROUTINE LGLIN +.x LINE +.p +~LGLIN plots a solid curve through a set of values from x to y. +Either x or y or both may in the process be converted to +~logarithmic form. Symbols may be used at selected intervals. +(see also ~SCALG and LINE). The plotted x values are computed according to, +.lit + + for logarithmic scaling, + + xplotted= (alog10(abs(x(i))+1.e-38)-xm)/dx + + for linear scaling, + + xplotted= (x(i)-xm)/dx + +.end lit +and similarily for y. +.lit + +CALL LGLIN (x,y,n,k,j,l,lg,ix,iy,xm,dx,ym,dy) + +x (R): array containing the x coordinates +y (R): array containing the y coordinates +n (I): number of data points in x and y + (the number of data points in x,y must be equal) +k (I): take every first (k=1), second (k=2) value etc. + (normally k=1) +j (I): plotting symbol spacing flag + > 0 : symbol is plotted at every jth plotted point + connected by lines + = 0 : no symbols, lines only + < 0 : symbol is plotted at every abs(j)th plotted point + with no connecting lines +l (I): plot symbol number (see SYMBOL) +lg (I): log option + = - 2 : x and y are plotted using logarithmic scaling + = - 1 : x logarithmic, y linear + = 1 : x linear, y logarithmic +ix,iy (I): start index if arrays (normally ix,iy=1) +xm (R): minimum value scale factor for x array +dx (R): increment scale factors for x array +ym (R): minimum value scale factor for y array +dy (R): increment scale factors for y array +.end lit + +.hl1 SUBROUTINE LGRID +.p +~LGRID plots a ~logarithmic or linear ~grid using solid lines, +dotted lines, or ticks. See also GRID. +.lit + +CALL LGRID (x,y,dx,dy,nx,ny,i) + +x,y (R): location coordinates for the bottom-left corner of grid +dx,dy (R): spacing of major grid lines in x and y directions +nx (I): number of major grid lines in x direction + < 0 : log spacing of minor lines + > 0 : no minor lines/ticks +ny (I): number of major grid lines in y direction + < 0 : log spacing of minor lines + > 0 : no minor lines/ticks +i (I): option flag + = 0 : solid major/minor lines + = 1 : dotted major/minor lines + = 2 : solid major lines with minor ticks +.end lit + +.hl1 SUBROUTINE LINE +.p +~LINE plots a solid curve through a set of coordinate pairs +stored in two arrays. Symbols may be inserted at selected +intervals and points of curves may be skipped. +The coordinates are calculated as follows: +.lit + + xplotted(i)=(x(i)-xm)/dx, i=ix to n, step k + yplotted(m)=(y(m)-ym)/dy, m=iy to n, step k + +.end lit +The routine ~SCALE may be used to compute the scale factors xm, dx, +ym, and dy from the x and y arrays. +.lit + +CALL LINE (x,y,n,k,j,l,ix,iy,xm,dx,ym,dy) + +x (R): array containing the x coordinates +y (R): array containing the y coordinates +n (I): number of data points in x and y + (the number of data points in x, y should be equal) +k (I): plot every first (k=1), second (k=2) value etc + (normally k=1) +j (I): plotting symbol spacing flag + > 0 : symbol is plotted at every jth plotted point + connected by lines + = 0 : no symbols, lines only + < 0 : symbol is plotted at every abs(j)th plotted point + with no connecting lines +l (I): plot symbol number (see SYMBOL) +ix,iy (I): starting indexs in array (normally ix,iy=1) +xm (R): minimum value scale factor for x array +dx (R): increment scale factors for x array +ym (R): minimum value scale factor for y array +dy (R): increment scale factors for y array +.end lit + +.hl1 SUBROUTINE LINSEQ +.x line type +.x software line type +.p +~LINSEQ plots line curves using software generated line types. +Cubic spline interpolation is used in the generation of the specified +long dash/short dash sequence. The cubic spline "smoothing" prior +to plotting may also be specified. Closed curves and loops are permitted. +A word of caution: due to the limitations of cubic splines, the +plotted curve may not exactly represent the underlying function. +The code used by this routine is an adaptation of the ~COSMIC routine +LAR-11123. +.p +LINSEQ can be used to plot the same curve at different locations +by first calling LINSEQ with the desired data, then calling LINSEQ +again with n set to zero and h changed. +.lit + +CALL LINSEQ (x,y,z,n,ns,h,s,l1,l2,l3,l4,l5) + +x (R): array containing the x coordinates +y (R): array containing the y coordinates +z (R): working array dimensioned at least z(3*n+3) +n (I): number of points in x,y arrays + if n=0 then arc parameters from the last + call to LINESEQ are used again + (used to replot the same curve at different location) +ns (I): number of smoothing passes (normally 0) +h (R): x axis plotting offset (normally 0). Setting h <> 0 + and n=0 permits replotting last curve, shifted right + the specifed amount. +s (R): approximate interval between interpolated points on + curve. Actual interval is internally computed. + If s<0 pre-interpolation to 2*n-1 points is done. +l1-l5 (I): dash pattern control flags + l1 = Number of INTERVALS BETWEEN dashes + l2 = Number of LONG dashes per CYCLE + l3 = Number of INTERVALS per LONG dash + l4 = Number of SHORT dashes per CYCLE + l5 = Number of INTERVALS per SHORT dash +Note: if l1=0, l2-l5 are ignored and a solid curve is drawn + if l4=0, l5 is ignored. All dashes same length. +.end lit + +.hl SUBROUTINE NEWPAGE +.p +.x form feed +.x page +~NEWPAGE inserts a change page command into the LONGLIB metafile. The +hardcopy conversion program use the change page command to issue a form +feed to the metafile output. Note that NEWPAGE only affects the metafile page +and does not change origin, etc. +It is a dummy call for ~Ramtek or ~terminal plotting. This command is +equivalent to CALL PLOT(0.,0.,10). +.lit + +CALL NEWPAGE + (no arguments) +.end lit + +.hl1 SUBROUTINE NEWPEN +.p +.x line type +.x ppen +.x rmpen +.x vpen +~NEWPEN calls PPEN, RMPEN, and VPEN which +change the hardware line type and/or width of the plotting +line for subsequent plotting on the metafile, Ramtek, and terminal +output devices. +The precise effects depend on the particular graphics device. There are +10 standard line types which are shown in the last chapter. The output device +will use the nearest hardware-supported line type to the standard line +type. Some +devices support additional types including permitting a specification +of the scale factor of the line type (the length of the dot/dash pattern). +If a device does not support line types, the default type is used. +Line widths are not support on the Ramtek packages and are simulated +in softwared for the terminal. The metafile package supports all features +although the metafile processing programs may only use the +features supported by the particular hardcopy graphics output device. +Default line type is a solid line of width 1 dot. +.lit + +CALL NEWPEN (i) + +i (I): selects a line type for all additional plotting + for all output devices + < 0 : resets line type to solid line of unit width. + = 0 : line type 0 no change in line width + > 0 : line type and width changed according to, + (1's digit) : line type (0-9) + (10's digit) : line width (1-7) (value of 0 does not change width) + (100's digit) : line type pattern scaling (1-7) (0 is no change) +.end lit + +.hl1 SUBROUTINE NUMBER +.p +~NUMBER plots a floating point number in a specified format using +a fortran format-like specification. It also permits +free-format and exponential notation formats. The number is converted +to an ~ASCII string plotted at a specified location and baseline angle +using SYMBOL. The following table illustrates the dependence of the output +string on the type (integer/real) and value of the parameter e. The table +shows the output for an input f=103.356 and i=-1. +.tp 17 +.lit + + Output integer e real e + -------- ---------- -------- + 103 -1 1003.0 + 103. 0 0.0 + 103. 0 3.00 + x103.36 7.02 + 103.36 2 0.02 + 103.356000 6 10.06 + xx103 1005.0 + ** 1002.0 (format overflow) + x103.4 6.01 + *.**** 6.04 (format overflow) + .103E+02 -8.03 + *.*** -5.03 (format overflow) + +note: x=space, * indicates overflow +.end lit + +.lit + +CALL NUMBER (x,y,h,f,a,e,i) + +x,y (R): location position (x,y returned if i=-2 or -3) + If x=999 then x is continued from lower right of + prior call to SYMBOL or NUMBER. If y=999 then + y is continued. +h (R): size (height) of digits +f (R): floating point number to be plotted +a (R): baseline angle at which to plot +e (R): output format (e=n.j) + (similar to format statement Fn.j) + n is the total number of characters (max 18) + including the decimal point and j is a two digit number + specifying the number of digits to the right of + the decimal point (to get F6.4 use e=6.04) + if e < 0 number is plotted in exponential notation. + if e = 0 then number is output in free format + if n = 0 then number is output in free format + integer with no decimal point shown + The number will be shown as an m digit integer + if using e=1000+m. +NOTE for VAX usage: if an integer in the range (-1 to 12) is passed + for e, NUMBER detects and uses the integer value + to specify a free-format specifying + the number of digits to the right of the decimal point. + a -1 inhibits decimal point +i (I): centering flag (see SYMBOL) + = -3 : same as -2 but string is not plotted and + last position is not affected + = -2 : same as -1 but returns end point in x,y + = -1 : (x,y) is lower left corner of plotted array + = 0 : (x,y) is center of plotted array + = 1 : (x,y) is lower right corner of plotted array + = 2 : no action +.end lit + +.hl SUBROUTINE PFACTOR +.p +~PFACTOR is called by ~FACTOR to change the input scale conversion factor +for the LONGLIB metafile package. It may be called separately if desired. +Only the metafile plotting package +is affected. The routines ~RFACTOR and ~VFACTOR may be separately +called to change the input scale conversion factor on the Ramtek and +terminal packages, respectively. See FACTOR. +.lit + +CALL PFACTOR (fac) + +fac (R): new conversion factor for coordinate values + (only the metafile scaling is affected) + <= 0 : scale factor reset to unity + > 0 : new scale factor +.end lit + +.hl1 SUBROUTINE PLOT +.x view port +.x origin +.x plotting window +.x PLOTRM +.x PPLOT +.x PLOTVT +.p +~PLOT is the central routine for controlling the motion of the electronic +pen for all LONGLIB graphics device packages. +PLOT calls the Ramtek, metafile and terminal PLOT routines PLOTRM, PPLOT, PLOTVT +based on the graphics devices initialized by FRAME. These individual +"package PLOT" routines can be called separately if desired to affect +only the particular package. Via these package-specific plot routines +PLOT can moves the pen, change the origin or +pen color, issue a page change command, etc. +A relative rotation angle for all successive plotting may also be specified. +LONGLIB defines a +plotting ~window or viewport, the size of which is device dependent, within +which pen motions are clipped. The viewport may be set to an arbitrary +size within the device plotting window (e.g. terminal screen). An attempt to +make the viewport bigger than the device output will force the viewport +to be the device output window (this is the default). +.lit + +CALL PLOT (x,y,i) + +x,y (R): coordinate values +i (I): plot function parameter + = 0: color control + x is the new line color + if x < 0 the screen is cleared + if x >= 0 then plotting angle becomes y + = 2: draw to (x,y) with 'pen down' + = -2: same as i=2. (x,y) becomes new origin + = 3: move to (x,y) with 'pen up' + = -3: same as i=3. (x,y) becomes new origin + = 4: upper right corner of viewport set to (x,y) + = -4: lower left corner of viewport set to (x,y) + = 5: pick pen up at last point + = 9: erase to (x,y) (plot with color 0) + = -9: erase to (x,y) (x,y) becomes new origin + = 10: issue change page command to metafile + = 11: end plot (close LONGLIB) + =999: end plot (close LONGLIB) +.end lit + +.hl1 SUBROUTINE PLOTND +.p +~PLOTND is used to signal LONGLIB that all plotting is complete. It +sends the final output buffers to the respective graphics devices, closes +files and channels, and resets the terminal to the normal ~text mode. PLOTND +is equivalent to a CALL PLOT(0.,0.,11) command. +.lit + +CALL PLOTND + (no arguments) +.end lit + +.hl1 SUBROUTINE PLOTS +.p +~PLOTS initializes the LONGLIB graphics package via a call to FRAME. +PLOTS provides compatibility with existing CALCOMP or PLOTS-10 compatible +code. It simply calls ~FRAME with argurments which cause FRAME to prompt +for optional usage of the Longlib meta file output and a graphics +screen. For new code use FRAME. +.lit + +CALL PLOTS (...) + +(arguments are ignored) +.end lit + +.hl1 SUBROUTINE PLOTRM +.p +~PLOTRM is the central routine for controlling the plotting of lines to +the Ramtek or REF package. PLOTRM is called by the ~PLOT routine but +can be called separately. Any call to PLOTRM when the Ramtek package +is not initialized is a dummy call. Options for PLOTRM are similar +to PLOT (see documentation on PLOT). +An attempt to make the viewport bigger than the Ramtek screen window +will force the viewport to be the size of the Ramtek screen window +(this is the default). Typically the Ramtek screen window is +either 13.75 or 11 by 11 inches depending on the type (1280x1024 and +512x512, respectively), with the lower +left corner at (0,0) and the upper right corner at (13.75,11). +.lit + +CALL PLOTRM (x,y,i) + +x,y (R): coordinate values +i (I): plot function parameter + = 0: Ramtek color control + x is the Ramtek color table index + if x < 0 the Ramtek screen is cleared + if x >= 0 then rotation angle becomes y + = 2: Ramtek draw to (x,y) with 'pen down' + = -2: same as i=2. point (x,y) becomes new origin + = 3: Ramtek move to (x,y) with 'pen up' + = -3: same as i=3. Point (x,y) becomes new origin + = 4: upper right corner of viewport set to (x,y) + = -4: lower left corner of viewport set to (x,y) + = 5: pick pen up at last point + = 9: draw to (x,y) 'pen down' color 0 (erase) + = -9: same as i=9. Point (x,y) becomes new origin + = 11: end plot (close Ramtek package) + =999: end plot (close Ramtek package) +.end lit + +.hl1 SUBROUTINE PLOTVT +.p +~PLOTVT is the central routine for controlling the plotting of lines to +the terminal screen device REF package. PLOTVT is called by the ~PLOT +routine but +can be called separately. Any call to PLOTVT when the terminal package +is not initialized is a dummy call. Options for PLOTVT are similar +to PLOT (see documentation on PLOT). +An attempt to make the viewport bigger than the terminal screen window +will force the viewport to be the size of the terminal screen window +(this is the default). Typically the terminal screen window is +9.5 by either 9.5 or 7.2 inches (depending on the terminal) with the lower +left corner at (0,0) and the upper right corner at (9.5,9.5). +.lit + +CALL PLOTVT (x,y,i) + +x,y (R): coordinate values +i (I): plot function parameter + = 0: if x < 0 the terminal graphics screen is cleared + if x >= 0 then rotation angle becomes y + if x = 0 set terminal to erase mode plotting + if x <> 0 and x <> 999 set line color to x + if x = 999 set terminal to XOR mode plotting + (only if terminal has capability) + = 2: draw to (x,y) with 'pen down' on terminal + = -2: same as i=2. Point (x,y) becomes new origin + = 3: move to (x,y) with 'pen up' on terminal + = -3: same as i=3. Point (x,y) becomes new origin + = 5: pick pen up at last point + = 4: upper right corner of viewport set to (x,y) + = -4: lower left corner of viewport set to (x,y) + = 9: erase to (x,y) on terminal (if supported) + = -9: same as i=9. Point (x,y) becomes new origin + = 11: end plot (close terminal package) + =999: end plot (close terminal package) +.end lit + +.hl1 SUBROUTINE PLRAX +.p +.x polar axis +~PLRAX plots a circular ~axis for plotting in polar form. A series +of concentric circles are drawn around (x,y) at increasing radi +to the maximum radius. Provisions are included for half circle, +quarter circle, etc. Labeling of starting points and ending points +may be changed. +.lit + +CALL PLRAX (x,y,r,as,ae,a0,a1) + +x (R): x coordinate of center of polar axis +y (R): y coordinate of center of polar axis +r (R): radius of polar axis in plot units +as (R): starting angle of axis in degrees from horizontal +ae (R): ending angle of axis in degrees from horizontal + Note: as=0 and ae=360 yields full circle axis +a0 (R): number label of starting angle +a1 (R): number label of ending angle + Note: if a0=a1 then angles are not labeled. +.end lit + +.hl1 SUBROUTINE PLRLN +.p +.x polar line +~PLRLN plots a solid curve through the set of coordinate points +in polar form stored in r and t arrays. Symbols may be inserted +at selected intervals. Angle values stored in the t array are +in degrees referenced to horizontal. Coordinates are calculated +as follows: +.lit + r=(r-rmin)/dr + xplotted=r*cos(t*pi/180) + yplotted=r*sin(t*pi/180) + +.end lit +.lit + +CALL PLRLN (r,t,n,j,l,ir,rmin,dr) + +r (R): array of radial values to be plotted +t (R): array of angle values +n (I): number of points to plot +j (I): plotting symbol option flag + > 0 : symbol plotted every jth point with connecting lines + = 0 : line plotted only with no symbols + < 0 : symbols plotted only, no connecting line +l (I): symbol number (see SYMBOL) +ir (I): start index in r and t arrays +rmin (R): minimum radius scale factor +dr (R): scale factor +.end lit + +.hl1 SUBROUTINE PLT3D +.p +.x 2-d surface plotting +~PLT3D plots a 2 dimensional array as a surface scribed with a +linear grid parallel to the x and y axes, i.e., a mesh. +Hidden lines are supressed. +Transformation from the array indices (i,j) to (x,y,z) is: +.lit + + x = xl * .5 * float(2*j-n-1)/float(n-1) + y = yl * .5 * float(2*i-m-1)/float(m-1) + z = zs * (a(i,j) + z0) + +Thus, + + (1,1) is (-xl/2,-yl/2) (m,1) is (-xl/2,+yl/2) + (1,n) is (+xl/2,-yl/2) (m,n) is (+xl/2,+yl/2) + + xplotted = x*cos(az) - y*sin(az) + x0 + yplotted = x*sin(az)*sin(al) + y*sin(az)*sin(al) + z*cos(al)+y0 +.end lit +.p +The common block ~PLT3B returns these ~transformation parameters so +that the plotted location (xp,yp) of a point (i,j,zr) may be computed as: +.lit + + xp = a1 * j + a2 * i + a3 + yp = b1 * j + b2 * i + b3 * zr + b4 +.end lit +.p +The dimension of the second set of working arrays is dependent on the +surface complexity -- the greater the surface complexity, the greater +l2 must be. As a minimum, l2 > l. See also ~NXTVU and HLT3D. +.x HLT3D +.lit + +CALL PLT3D (a,md,nd,m,n,w,l,w2,l2,al,az,xl,x0,yl,y0,zs,z0,ierr) + +a (R): array of values to be plotted dimensioned a(md,nd) +md,nd (I): array dimensions +m,n (I): size of data in array to be plotted +w (R): working array dimensioned w(l) l=>4*min(m,n) +l (I): working array dimension +w2 (R): working storage array dimensioned w2(l2) +l2 (I): working storage array dimension (see note) +al (R): viewing altitude angle +az (R): viewing azimuth angle +xl,yl (R): length of unprojected axes (plot units) +x0,y0 (R): plot origin +zs (R): z coordinate scale factor +z0 (R): z coordinate offset +ierr (I): (returned) error code + = 0 : ok + = 1 : l2 not large enough in NXTVU + = 2 : l not large enough + +COMMON /PLT3B/ a1,a2,a3,b1,b2,b3,b4 +.end lit + +.hl 1 SUBROUTINE PPLOT +.p +~PPLOT is the central routine for controlling the plotting of lines to +the LONGLIB metafile package. PPLOT is called by the ~PLOT +routine but +can be called separately. Any call to PPLOT when the metafile package +is not initialized is a dummy call. Options for PPLOT are similar +to PLOT (see documentation on PLOT). +An attempt to make the viewport bigger than the metafile plotting window +will force the viewport to be the size of the metafile plotting window +(this is the default). +The metafile plotting window is 56.5 by 56.5 inches with the lower +left corner at (0,0) and the upper right corner at (56.5,56.5). +Since most hardcopy devices can not produce such a large output page, +the LONGLIB metafile processor programs which convert the metafile to +an output file, "strips" the metafile window into separate, overlapping output +pages. Only non-blank page strips are output to the device. +.lit + +CALL PPLOT (x,y,i) + +x,y (R): coordinate values +i (I): plot function parameter + = 0: line color control + x is the new line color + if x >= 0 then plotting angle becomes y + = 2: draw to (x,y) with 'pen down' + = -2: same as i=2. (x,y) becomes new origin + = 3: move to (x,y) with 'pen up' + = -3: same as i=3. (x,y) becomes new origin + = 4: upper right corner of viewport set to (x,y) + = -4: lower left corner of viewport set to (x,y) + = 5: pick pen up at last point + = 9: erase to (x,y) + = -9: erase to (x,y), (x,y) becomes new origin + = 10: issue change page command to metafile + = 11: end plot (close metafile package) + =999: end plot (close metafile package) +.end lit + +.hl1 SUBROUTINE PPEN +.p +.x line type +.x rmpen +.x vpen +~PPEN is called by ~NEWPEN to change the hardware line type and/or width of +the plotting line for subsequent plotting on the metafile. It may be +called separately to change only the metafile line type. +Ramtek and terminal output device line types may be changed using +RMPEN and VPEN, respectively. While the metafile output device supports +line types, widths and type scale factors (the length of the linetype +dot/dash pattern), the programs which process the LONGLIB metafile into +the output format required by the hardcopy device may not support all +features. The precise effects depend on the particular graphics device. +Raster scan converter programs for dot matrix printers support all options +and the 10 standard line types shown in the last chapter. On other +hardcopy devices, the metafile processing program uses the +the nearest hardware-supported line type to the standard line +type. Line widths are defined in terms of the minimum line widths. +The default line type is a solid line of width 1 dot. +.lit + +CALL PPEN (i) + +i (I): selects a line type for all additional plotting + to the LONGLIB metafile + < 0 : resets line type to solid line of unit width. + = 0 : line type 0 no change in line width + > 0 : line type and width changed according to, + (1's digit) : line type (0-9) + (10's digit) : line width (1-7) (value of 0 does not change width) + (100's digit) : line type pattern scaling (1-7) (0 is no change) +.end lit + +.hl1 SUBROUTINE RECT +.p +~RECT plots a rectangle defined by the lower left and upper right hand +corners. The pen moves UP to lower left hand of the rectangle, plots +the rectangle, and leaves the pen DOWN at the lower left corner. +.lit + +CALL RECT (x1,y1,x2,y2) + +x1,y1 (R): lower left hand corner coordinates +x2,y2 (R): upper right hand corner coordinates +.end lit + +.hl1 SUBROUTINE RESPL +.P +~RESPL performs a penup, then restores the current plotting origin, color, +line type, scale, and plotting angle saved by the ~SAVPL command. In conjunction +with ~SAVPL (which saves a previous condition) context changes can be easily +made. RESPL calls ~PRESPL (metafile restore), ~RRESPL +(Ramtek restore), and ~VRESPL (terminal restore) +which can be independently used if desired. If the stack is empty, +no restore occurs. (NOTE: graphics devices must be in the graphics +mode when this routine is executed). When using PRESPL, RRESPL, or VRESPL +a pen up operation should be executed imediately prior to the call. +.lit + +CALL RESPL + (no arguments) +.end lit + +.hl SUBROUTINE RFACTOR +.p +~RFACTOR is called by ~FACTOR to change the input scale conversion factor +for the LONGLIB metafile package. It can be called separately if desired. +Only the Ramtek plotting package +is affected. The routines ~PFACTOR and ~VFACTOR may be separately +called to change the input scale conversion factor on the metafile and +terminal packages, respectively. See FACTOR. +.lit + +CALL RFACTOR (fac) + +fac (R): new conversion factor for coordinate values + (only the Ramtek scaling is affected) + <= 0 : scale factor reset to unity + > 0 : new scale factor +.end lit + + +.hl1 SUBROUTINE RMPEN +.p +.x line type +.x ppen +.x vpen +~RMPEN is called by ~NEWPEN to change the hardware line type and/or width of +the plotting line for subsequent plotting on the Ramtek. It may be +called separately to change only the Ramtek line type. +Metafile and terminal output device line types may be changed using +PPEN and VPEN, respectively. While the Ramtek output device supports +line types and type scale factors (the length of the linetype +dot/dash pattern) it does not support line widths in hardware. +The default line type is a solid line of width 1 dot. +.lit + +CALL RMPEN (i) + +i (I): selects a line type for all additional plotting + to the LONGLIB Ramtek + < 0 : resets line type to solid line of unit width. + = 0 : line type 0 no change in line width + > 0 : line type and width changed according to, + (1's digit) : line type (0-9) + (10's digit) : line width (0-7) (ignored) + (100's digit) : line type pattern scaling (1-7) (0 is no change) +.end lit + +.hl1 SUBROUTINE RTERM +.x REFDIS +.p +~RTERM is designed to be similar to the ~CTERM routine but for use with the +Ramtek. It is a dummy call when not in ~Ramtek plotting mode. When using +the ~REF package, it calls REFDIS. +.lit + +CALL RTERM (iarg) + +iarg (I): operation code + = 0 : clear Ramtek screen + = 2 : ask if clear screen desired. + reply should be: "Y" or "N". Default is "N". + NOTE: a reply of "Q" will execute RTERM(3). + a reply of "S" will close channel and stop + Ramtek plotting until next RTERM(2) (see CTERM) + =-2 : clear Ramtek screen + = 3 : close Ramtek plotting (closes old channel) + =-3 : reopen Ramtek plotting (opens new channel--does + not reinitalize Ramtek plotting package) + =-4 : clear Ramtek screen +.end lit + +.hl1 SUBROUTINE SAVPL +.P +~SAVPL performs a penup, then stores the current plotting origin, color, +line type, scale, etc. on a stack which will store up six calls. +In conjunction +with ~RESPL (which restores previous condition) context changes can be easily +made. SAVPL calls ~PSAVPL (metafile save), ~RSAVPL +(Ramtek save), and ~VSAVPL (terminal save) +which can be independently used if desired. When the stack is +full no save is performed. +.lit + +CALL SAVPL +.end lit + +.hl1 SUBROUTINE SCALE +.x LINE +.p +~SCALE calculates the minimum and a scaled (smoothed) increment from +an array of values. The maximum and minimum of the array are computed +and the difference is divided by a length parameter. The resulting +values are "smoothed" so that numeric labels appear "nice" when labeled at +xm and at one inch increments. +The smoothed numbers are taken from the set of values 1,2,4,5,8 * 10n +that equals or is smaller than the true value. SCALE is useful +in determaning the scale factors for LINE. It is used extensively +in the MASTER routines. SCALE is not very intelligent and does not +always make good choices. SCALE selects xm and dx so that the plotted +x values may be computed using the following formula such that if +x=xm, xplotted=0 and if x=xlen*dx+xm, xplotted=xlen. +.lit + + xplotted = ( x - xm ) / dx + +.end lit +.lit + +CALL SCALE (x,xlen,n,k,ix,xm,dx) + +x (R): array of data points from which scale is determined +xlen (R): scale length +n (I): number of data points in x (n>1) +k (I): use every first (k=1) value, second (k=2) value, etc. + normally k=1. +ix (I): first data point index for x (normally ix=1) +xm (R): contains smoothed minimum after the call (returned) +dx (R): contains smoothed increment after call (returned) +.end lit + +.hl1 SUBROUTINE SCALG +.x LGLIN +.p +~SCALG calculates a scaled minimum and increment factor similar +to ~SCALE but uses the log (actually alog10(abs(val)+1.e-38)) +of the input array. See also SCALE and LGLIN. +SCALG selects xm and dx so that the plotted +x values may be computed using the following formula such that if +alog10(abs(x)+1.e-38)=xm then xplotted=0 and if +alog10(abs(x)+1.e-38)=xlen*dx+xm then xplotted=xlen. +.lit + + xplotted = ( alog10(abs(x)+1.e-38) - xm ) / dx + +.end lit +.lit + +CALL SCALG (x,xlen,n,k,ix,xm,dx) + +x (R): array of data points from which scale is determined +xlen (R): length +n (I): number of data points in x (n>1) +k (I): use every first (k=1) value, second (k=2) value, etc. + normally k=1 +ix (I): first data point index for x (normally ix=1) +xm (R): contains smoothed minimum after the call (returned) +dx (R): contains smoothed increment after call (returned) +.end lit + +.hl1 SUBROUTINE SHADE +.p +The ~SHADE subroutine fills in the ~area inclosed by the line defined +by the x and y arrays with equally spaced lines at a given angle using +a specified line type. The first and last +point of the x and y array are assumed to be connected. +.lit + +CALL SHADE (x,y,n,i,l,d,t,w,ma,xm,dx,ym,dy) + +x (R): array of x values +y (R): array of y values +n (I): number of points in array +i (I): increment between points +l (I): shade format control + = -3 : clear area and outline + = -2 : clear area + = -1 : clear outline + = 0 : no action + = 1 : draw outline + = 2 : shade area + = 3 : shade area and outline +d (R): distance between shading lines +t (R): angle of shading lines in degrees +w (R): working array dimensioned at least 3*n +ma (R): line type of shading + => 0 : line type (see NEWPEN) +xm (R): minmum scale factor for x (see LINE) +dx (R): x increment scale factor +ym (R): minmum scale factor for y +dy (R): y increment scale factor +.end lit + +.hl1 SUBROUTINE SYMBOL +.p +The ~SYMBOL routine plots an ~ASCII string. Upper and lower +case ~characters can be plotted as well as special plotting +symbols and characters. A list of symbols is shown in the last +chapter. +The plotting symbols 0 to 16 are centered vertically and horizontally, +while other symbols have a reference point on the lower left edge +of the character. Hence, i=-1 should be used for centered plot symbols +0 thru 16. +The number of characters in the input string which should be plotted +can be specified. +If an ASCII null (0) is encountered in the string beyond the +first position, the routine terminates. +.p +The string can be plotted left-justified, centered, or right-justified. +When the string is left-justified, the location of the end of the +plotted string can be optionally returned. The length of the +plotted string can be computed by calling SYMBOL first with i=-3 +and computing the difference between the start and ending points of the +string. +.p +More elaborate characters and different fonts +may be obtained using SYMS. ~MASTER routines, ~AXIS routines, and ~NUMBER +all use ~SYMBOL characters. If the user desires to use ~SYMS in place +of SYMBOL throughout a program, the user can add the following routine +to the program. The subroutine should be titled SYMBOL with the +arguments described below. This routine +simply passes the arguments (in the same order) to SYMS. +.lit + + SUBROUTINE SYMBOL(x,y,h,s,a,n,i) ! symbol replacement + INTEGER S(1) + A = SYMS(x,y,h,s,a,n,i) ! call syms + RETURN + END +.end lit +.x %REF() +.x descriptor +.p +Note: ~VAX ~FORTRAN ~CHARACTER types +can not be used directly since calling subroutines with CHARACTER types +is done by DESCRIPTOR. Use ~BYTE or ~INTEGER arrays for s or use %REF() +for character variables, i.e., call SYMBOL(0., 0., .25, %REF(S), 0., 10,-1). +See the section on machine dependency. +.lit + +CALL SYMBOL (x,y,h,s,a,n,i) + +x,y (R): location position (x,y returned if i=-2 or -3) + If x=999 then x continued from last position in + prior SYMBOL or NUMBER call. If y=999 then y continued. +h (R): height of the string to be printed +s (B): alpha string containing the text to be plotted +a (R): angle at which the string is to be plotted +n (I): number of characters in string s to plot + = -2 : draws pen down to (x,y) before symbol plotted + = -1 : plots a single symbol + > 0 : number of characters to plot +i (I): location flag + = -3 : same as -2 but string is not plotted and + last position is not affected + = -2 : same as -1 but returns end point in x,y + = -1 : (x,y) is lower left corner of plotted string + = 0 : (x,y) is center of plotted array + = 1 : (x,y) is lower right corner of plotted string + = 2 : no action +.end lit + +.hl1 REAL FUNCTION SYMS +.p +.x character plots +~SYMS is similar to SYMBOL in that it will plot +an ~ASCII string (i.e. a byte array). However, SYMS provides additional +math and plotting symbols as well as several character fonts (including +~Greek characters). SYMS has several additional enhancements to permit +complicated equations to be plotted. All but the 9th font have variable +width characters. Several fonts are designed to produce solid characters +when the plotting scale is small. +The number of characters in the input string s plotted and/or +interpreted can be specified. +If an ASCII null (0) is encountered in the string after the +first position, the routine terminates. +.p +The ASCII character "|" (decimal 124) is used as a control character to +change fonts or subscripting options. The character following the +"|" character is used according to the following table: +.s3 +.tp 30 +.c;SYMS Options +.lit + + ASCII Character Decimal Effect +________________ _________ ________ + + 0-9 48-57 Change to font (0-9) + W 87 Move forward one space + X 88 Move forward 1/2 space + Y 89 Move backward one space + Z 90 Move backward 1/2 space + [ 91 Reset to default + \ 92 Begin subscripting + ] 93 "Back up" one character + ^ 94 Begin superscripting + _ 95 Un sub/super + ` 96 Change scale (requires + another character-- "+" + indicates increase size by 2, + "-" indicates shrink by 1/2. + a 97 Begin over printing + b 98 Begin under printing + +.end lit +The number of characters in the string should include control characters. +.p +The width of one space is moved when moving forward or backward. +"Back up" returns the positioning to the start of the last character. +Up to 6 "back up" commands can be issued. Super/sub scripting can be +done recursively. Only one level is "popped off" by the +un-sub/super command. Scale changes require an additional character +(either a "+" or "-" to indicate the direction). Over/under printing +permit summation and integral limits to be added. Available fonts are listed +in the following Table: +.tp 15 +.s2 +.x character fonts +.c;Fonts Available in SYMS +.lit + + Font Characters Description + ______ ____________ _____________ + + 0 [default] ASCII 0-31 Plotting Symbols + ASCII 32-127 Simplex font--variable width + 1 ASCII 32-127 Roman + 2 ASCII 64-127 Greek Simplex + 3 ASCII 32-127 Roman Italic + 4 ASCII 32-127 Duplex bold + 5 ASCII 64-127 Special math symbols + 6 ASCII 32-127 Greek bold + 7 ASCII 32-127 Simplex Italic + 8 ASCII 32-127 Crude Simplex--fixed width +.end lit +.p +For example, the following summation using Greek characters, a +~math symbol, and a super scripted variable can be wrtten: +.TP7 +.lit + + alph string = 'A = |6R a|^2|_|]|]|]|]|b|1|2n=1|]|]|]|_|a|5K' + + infinity 2 + A = SIGMA alpha + zeta=1 + +.end lit +.p +Note: SYMS can be called as a real function. The returned value +is the final length of the plotted string. When i=2 no plotting +is done but the length is returned. When i=-2 the string is plotted +and the lower left corner of the next character position after +the end of the string is returned in x,y. +.p +Note: VAX FORTRAN CHARACTER types +can not be used directly since calling subroutines with CHARACTER types +is done by DESCRIPTOR. Use BYTE or INTEGER arrays for s or use %REF() +for character variables, i.e., call SYMS(0., 0., .25, %REF(S), 0., 10, -1). +See the section on machine dependency. +.lit + +rlen = SYMS (x,y,h,s,a,n,i) + +x,y (R): string position (x,y returned if i=-2 or i=-3) + If x=999 then x is continued from last position in + prior SYMS call. If y=999 then y continued. +h (R): height of the string to be printed +s (B): alpha array containing the text to be plotted +a (R): angle at which the string is to be plotted +n (I): number of characters in string s +i (I): centering flag + = -3 : same as -2 but string is not plotted and + last position is not affected + = -2 : same as -1 but returns end point in x,y + = -1 : (x,y) is lower left corner of plotted string + = 0 : (x,y) is center of plotted array + = 1 : (x,y) is lower right corner of plotted string + = 2 : no plotting, plotted length of string returned + +rlen (R): (returned) length of plotted text string +.end lit + +.hl1 REAL FUNCTION SYMSS +.p +.x character plots +~SYMSS is identical to SYMS except that it plots "smoothed" characters +using the software linetype generation routine LINSEQ. +Smoothing improves the appearance of most of the fonts +when the characters are plotted at large scale. See ~SYMS and ~LINSEQ for +additional details. +.lit + +rlen = SYMSS (x,y,h,s,a,n,i,al,l1,l2,l3,l4,l5) + +x,y (R): string position (x,y returned if i=-2 or i-3) + If x=999 then x continued from from last position in + prior SYMS call. If y=999 then y continued. +h (R): height of the string to be printed +s (B): alpha array containing the text to be plotted +a (R): angle at which the string is to be plotted +n (I): number of characters in string s +i (I): centering flag + = -3 : same as -2 but string is not plotted and + last position is not affected + = -2 : same as -1 but returns end point in x,y + = -1 : (x,y) is lower left corner of plotted array + = 0 : (x,y) is center of plotted array + = 1 : (x,y) is lower right corner of plotted array + = 2 : no plotting, plotted length of string returned +al (R): smoothed arc length (typically 0.05 to 0.01) +l1-5 (I): LINSEQ arc type, use l1=0 for a solid line. + +rlen (R): (returned) length of plotted text string +.end lit + +.hl SUBROUTINE VFACTOR +.p +~VFACTOR is called by ~FACTOR to change the input scale conversion factor +for the LONGLIB metafile package. It may be called separately if desired. +Only the terminal plotting package +is affected. The routines ~PFACTOR and ~RFACTOR may be separately +called to change the input scale conversion factor on the metafile and +Ramtek packages, respectively. See FACTOR. +.lit + +CALL VFACTOR (fac) + +fac (R): new conversion factor for coordinate values + (only the terminal scaling is affected) + <= 0 : reset scale factor to unity + > 0 : new scale factor +.end lit + +.hl1 SUBROUTINE VPEN +.p +.x line type +.x rmpen +.x ppen +~VPEN is called by ~NEWPEN to change the hardware line type and/or width of +the plotting line for subsequent plotting on the terminal screen device. +It may be called separately to change only the terminal line type. +Metafile and Ramtek and terminal output device line types may be changed +separatly using PPEN and RMPEN, respectively. While the terminal output +device driver supports line types in hardware, line widths are supported in +software by outputing multiple single-width lines offset by one pixel. +Line type scale factors (the length of the linetype +dot/dash pattern) are not used. Not all terminals support all +standard line types. If a particular terminal does not support the +requested line type, normally a solid line is used. +The default line type is a solid line of width 1 dot. +.lit + +CALL VPEN (i) + +i (I): selects a line type for all additional plotting + to the terminal screen output device + < 0 : resets line type to solid line of unit width. + = 0 : line type 0 no change in line width + > 0 : line type and width changed according to, + (1's digit) : line type (0-9) + (10's digit) : line width (1-7) (0 value does not change width) + (100's digit) : line type pattern scaling (ignored) +.end lit + +.hl1 SUBROUTINE WHERE +.p +~WHERE returns the location from the last call to PLOT. +The Zoom scale factor value is returned from the LONGLIB graphics device +packages in the priority order: ~terminal if open or ~Ramtek if open or +else from the metafile. Does nothing when no device is open. +.lit + +CALL WHERE (x,y,z) + +x,y (R): (returned) values of x,y from last call to plot +z (R): (returned) zoom value. +.end lit + +.hl1 SUBROUTINE WHEREPR +.p +~WHEREPR returns information on the metafile plotting parameters. If lu <= 0 +then metafile has not been initialized. A routine ~FIXPR0 (which +has the same parameters) may be used +to set these variables to absolute values without error checking. +.lit + +CALL WHEREPR (x,y,ax,ay,z,a,rx,ry,lu,m,iw,ic) + +x,y (R): (returned) current origin +ax,ay (R): (returned) last scaled and shifted origin point +z (R): (returned) current zoom scale factor +a (R): (returned) current plotting angle +rx,ry (R): (returned) resolution of metafile +lu (I): (returned) FORTRAN file output unit number + (if lu <= 0 metafile package not initialized) +m (I): (returned) current line type +iw (I): (returned) current line width +ic (I): (returned) current line color +.end lit + +.hl1 SUBROUTINE WHERERM +.p +~WHERERM returns information on the ~Ramtek plotting parameters. If c <= 0 +then ramtek has not been initialized. A routine ~FIXRM0 (with +same parameters) may be used +to set these variables to absolute values without error checking. +.lit + +CALL WHERERM (x,y,z,a,rx,ry,nt,ns,i,ic) + +x,y (R): (returned) current origin +z (R): (returned) current zoom scale factor +a (R): (returned) current plotting angle +rx,ry (R): (returned) current pixel resolution +nt (I): (returned) current line bit pixel pattern +ns (I): (returned) current line bit scale factor +i (I): (returned) Ramtek color +ic (I): (returned) Ramtek channel + (if ic <= 0 ramtek is not initialized) +.end lit + +.hl1 SUBROUTINE WHEREVT +.x Selanar +.x vt100 +.x vt125 +.x vt240 +.x vt220 +.p +~WHEREVT returns information on the ~terminal plotting parameters. If nv <= 0 +then terminal graphics have not been initialized. A routine +~FIXVT0 (with same arguments) may be used to set these variables to +~absolute values without error checking. +.lit + +CALL WHEREVT (x,y,z,a,rx,ry,iv,ns,it,iw,ic) + +x,y (R): (returned) current origin +z (R): (returned) current zoom scale factor +a (R): (returned) current plotting angle +rx,ry (R): (returned) current pixel resolution +iv (I): (returned) terminal code + (if nv <= 0 terminal is not initialized) +ms (I): (returned) internal terminal-type code + = 1 VT100 with Selanar GR100 + = 2 VT125 + = 3 VT240 + = 4 VT220 with Selanar GR220 + = 5 Tektronix 4010 + = 6 Tektronix 4109 + = 7 Graphon GO-235 +it (I): (returned) current line type +iw (I): (returned) current line width +ic (I): (returned) current line color +.end lit + +.CHAPTER Description of 3-d Plotting Routines +.x 3-d plotting +.p +The following paragraphs contain detailed descriptions of the subroutines +included in the LONGLIB library for 3-d plotting. For added flexibility, +two distinct families of 3-d plotting routines have been provided. +One family is designed for plotting with hidden line removal; +the other family is more flexible but does not perform hidden line removal. +Both options assume that ~FRAME has already been called, i.e. the plot +package is already opened. The 3-d routines call ~PLOT as output so +that the 2-d plot origin, scaling, rotation, etc. are used in addition +to any 3-d operations. +.p +The nominal Z axis of the 3-d plot packages for plotted objects runs out +of the screen. The X and Y axes are defined as before. +.p +.x hidden line removal +Two separate, independent 3-d packages exist. These are identified by +the initialization routines used for each package. The hidden line +removal package is ~INIT3DH and is a modification of the ~COSMIC hidden +line code package (ARC-11446). The other is INIT3D. ~INIT3D does +not perform any hidden line removal. These package differ not only in +hidden line removal but also in speed of operation and memory requirements. +The packages are completely independent. Only routines designed for a +particular package will work with that package. It is possible to +use both simultaneously. + +.hl 1 INIT3D Routines +.p +The INIT3D 3d plotting package permits 3-d plotting but does not include +hidden line removal. +The family of routines used with ~INIT3D include: +.s1 +.ls0 +.le;PLOT3D -- the central plot routine for INIT3D +.le;AXIS3D -- plots axes using PLOT3D, NUM3D, and SYM3D +.le;NUM3D -- plots numbers using PLOT3D +.le;SYM3D -- plots symbols using PLOT3D +.le;WHERE3D -- returns the screen coordinates of the last point +drawn by PLOT3D. +.els +.p +The ~INIT3D family of 3-d plotting routines are desiged to plot +wireframe line plots with no hidden line removal. Memory requirements +are modest and plotting is more rapid than for the ~INIT3DH routines. +For an example of the use of the INIT3D package see the ~EXAMP3D +program included with the LONGLIB graphics library. + +.hl2 SUBROUTINE INIT3D +.p +~INIT3D sets the ~absolute origin, rotations, and ~scale ~factor of +the 3-d package. These functions are distinct from the functions of +PLOT. INIT3D may be called at any time to reset these functions without +closing the plot package. The plot package must be opened with ~FRAME +prior to the call to INIT3D. +.lit + +CALL INIT3D (x,y,z,xa,ya,za,t,ds,sf,i) + +x,y,z (R): coordinates of view point (looking from) +xa,ya,za (R): coordinates of center point (looking to) +t (R): rotation angle around line from (x,y,z) to + (xa,ya,za) in degrees CCW. +ds (R): perspective scale factor (image size/viewing distance) +sf (R): relative scale factor +i (I): plotting flag ( -1 = do not plot, scaling only) +.end lit + +.hl2 SUBROUTINE AXIS3D +.x AXIS3 +.x PLOT3D +.x NUM3D +.x SYM3D +.p +~AXIS3D plots an axis and its markings in 3-d. In order to draw a +coordinate system, the routine has to be called separately for the x, +y, and z axis. A possible exponent is determined and placed behind the +axis label in the form of 10**n in the auto scaling mode (see AXIS3). +AXIS3D calls PLOT3D, NUM3D, and SYM3D. See also AXIS3. +.lit + +CALL AXIS3D (x,y,x,a,b,g,s,n,ale,xm,xx,t,c,f) + +x,y,z (R): location of start of axis +a,b (R): angles from the x-y, x-z planes (in deg) of the ray + from (x,y,z) along the character string +g (R): angle of rotation about the ray defined by a,b (deg) +s (B): alpha string containing the axis title +n (I): number of characters in the string + > 0 : axis labelling on positive side (anti-clockwise) + < 0 : axis labelling on negative side (clockwise) + (100's digit) = 0 : axis is labeled + = 1 : line and ticks only--no labeling +ale (R): length of axis + < 0 : tick marks placed on same side of axis as title + = 0 : no action + < 0 : tick marks placed opposite side of axis from title +xm (R): value of first marking on the axis +xx (R): value of last marking on the axis +t (R): number of tick marks + specification is coded in the form MMM.mmss where + MMM is the number of major tick marks ( MMM > 0), mm is + the number of minor tick marks between major tick marks + (100 > mm => 0), and ss is the number of subminor tick + marks between minor tick marks (100 > ss => 0). + (example 1.0102 produces I_._._i_._._I) +c (R): size of characters + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +f (R): number label format (see NUMBER) +.end lit + +.hl2 SUBROUTINE NUM3D +.x number +.x plot3d +.p +~NUM3D plots a floating point number (see NUMBER) in 3-d using +PLOT3D. The symbols are plotted in the plane defined by a,b,g. +.lit + +CALL NUM3D (x,y,z,a,b,g,f,e) + +x,y,z (R): lower-left corner of string + If x=999, y=999, z=999 then string is continued from + lower right of previous SYM3D or NUM3D call +a,b (R): angles from the x-y, x-z planes (in deg) of the ray + from (x,y,z) along the base of the character string +g (R): angle of rotation about the ray defined by a,b (deg) +h (R): height of the number to be plotted +f (R): number to be plotted +e (R): format of number representation n.j + (see NUMBER for detailed description) +.end lit + +.hl2 SUBROUTINE PLOT3D +.x CPLOT3D +.p +~PLOT3D is the 3-d version of PLOT. A relative ~rotation matrix and +~origin is maintained (separate from viewing matrix and PLOT parameters). +By setting the plotting option flag i in ~INIT3D to -1, plotting will be +inhibited. A common block, CPLOT3D, returns a 4 element vector V +with the screen transformed coordinates. +PLOT3D transforms the 3d input coordinates +to 2d coordinates, clips to a 3d clipping window, and calls ~PLOT with +the 2d coordinates screen coordinates of the visible line segments. +.x screen coordinates +.lit + +CALL PLOT3D (x,y,z,i) + +x,y,z (R): coordinates of point (in 3 space) +i (I): plot function parameter + = 0: color control + x is the line color + if x < 0 the screen is cleared + if x >= 0 2d plot angle (PLOT) becomes y + = -1: change relative scale factor by x + = 1: change relative rotation matrix + rotate x degrees CCW around x axis + rotate y degrees CCW around y axis + rotate z degrees CCW around z axis + = 2: draw to (x,y,z) with 'pen down' + = -2: same as i=2. (x,y,z) becomes new origin + = 3: move to (x,y,z) with 'pen up' + = -3: same as i=3. (x,y,z) becomes new origin + = 9: erase to (x,y,z) (erase is color 0) + = -9: same as i=9. (x,y,z) becomes new origin + +common /CPLOT3D/V(4) : returned screen coordinates (x,y) of last + call to PLOT3D v(1)=x, v(2)=y +.end lit + +.hl2 SUBROUTINE SYM3D +.x SYMBOL +.p +~SYM3D plots an ~ASCII string (see SYMBOL) in 3-d using +PLOT3D. The ~symbols are plotted in the plane defined by a,b,g. +.lit + +CALL SYM3D (x,y,z,a,b,g,s,n) + +x,y,z (R): lower-left corner of string + If x=999, y=999, z=999 then string is continued from + lower right of previous SYM3D or NUM3D call +a,b (R): angles from the x-y, x-z planes (in deg) of the ray + from (x,y,z) along the base of the character string +g (R): angle of rotation about the ray defined by a,b (deg) +h (R): height of the string to be plotted +s (B): alpha array containing the text to be plotted (byte array) +n (I): number of characters in string s +.end lit + +.hl2 SUBROUTINE WHERE3D +.p +~WHERE3D returns the 2d screen coordinates of the last line drawn using +PLOT3D. +.lit + +CALL WHERE3D (x,y) + +x,y (R): (returned) screen coordinates of last point +.end lit + +.hl1 INIT3DH Routines +.p +The family of plotting routines included in the hidden line 3-d +packge INIT3DH include: +.s1 +.ls0 +.le;PLT3DH -- the central visible line plot routine for INIT3DH +.le;SKETCH -- the central hidden line plot routine for INIT3DH +.le;AXIS3DH -- plots axes using PLT3DH or SKETCH +.le;CUBE -- plots the polygons of the sides of a "cube" +.le;SYM3DH -- plots symbols using PLT3DH or SKETCH +.le;WHERE3H -- returns the screen coordinates of the last PLT3DH call +.le;XFRM3D -- transforms a point (x,y,z) into the perspective point +defined by INIT3D. +.els +.x hidden line removal +.p +The central hidden line plot routine SKETCH is an adaptation of the +~COSMIC routine ARC-11446 hidden line code. It has been modified +and extended for additional features. The INIT3DH can be used either +with or without the hidden line removal. However, the memory and +computational requirements for hidden line removal can be large for +complicated scenes. Essentially, planar polygons are defined and +entered into the SKETCH internal list. Upon the last call to +~SKETCH the visible lines are plotted using PLOT. Line segments can also be +entered into the SKETCH list prior to the last call. They will not +"hide" any other lines but can be hidden by planes. The SKETCH +routine can be set to plot both visible and invisible lines. +~PLT3DH does not use SKETCH. Lines plotted with PLT3DH will always +be visible. The auxilary routines (NUM3DH, AXIS3DH, and SYM3DH) +have options to either use ~SKETCH or PLT3DH. +.p +For an example of the use of the ~INIT3DH package see the ~EXAMP3DH +program included with the LONGLIB graphics library package +or see the ~MASTER routines TRIG3DH, HIST3D, or T3DH. +.x TRIG3DH +.x T3DH +.x HIST3D + +.hl2 SUBROUTINE INIT3DH +.p +.x hidden line removal +~INIT3DH sets the relative ~origin and ~scale ~factor of the 3-d +package which includes hidden line removal. These functions are distinct +from the functions of PLOT or PLOT3D. INIT3DH may be called at any time +to reset these functions without closing the plot package. However, a +call to INIT3DH resets the internal SKETCH list of polygons. The plot +package must be opened with FRAME prior to a call INIT3DH. INIT3DH must +be called prior to SKETCH or PLT3DH. ~SKETCH uses an internal common +block for storage of its internal list. The user is required to provide +sufficient common block storage space. This common block is defined: +.lit + + COMMON /GO/ ISIZE, WORK(ISIZE) +where + ISIZE >=(25 + 5*MNE + 4*(2+MNE+2*MNH))*NPOLYS + MNE = maximum number of edges per polygon + MNH = maximum number of edges per polygon + NPOLYS= maximum number of polygons + +.end lit +If SKETCH is not used, this common block need not be dimensioned. +Note that ISIZE must be given a value in the user's code. +.p +The angles ya,ro,pi are defined as the sequence of rotations ya-ro-pi +(yaw, roll, and pitch) +where ya is the angle or rotation about the z axis (positive is +from x to y). ro is the angle of rotation about the x axis +(positive is from y to z). pi is the angle of roation about the y +axis (positive is from z to x). +.lit + +CALL INIT3DH (x,y,z,ya,ro,pi,zom,ds,mne,mnh) + +x,y,z (R): coordinates of relative origin +ya,ro,pi (R): yaw, roll, pitch angles (Eulerian) in degrees + (see above for angle definitions) +zom (R): relative scale factor +ds (R): viewing distance (9999. = infinity or no pespective) +mne,mnh (I): maximum number of edges and holes on one polygon +.end lit + + +.hl2 SUBROUTINE AXIS3DH +.x SKETCH +.x NUM3DH +.x SYM3DH +.x hidden line removal +.x AXIS3 +.p +~AXIS3DH plots an axis and its markings in 3-d. In order to draw a +coordinate system, the routine has to be called separately for the x, +y, and z axis. A possible exponent is determined and placed behind the +axis labelling in the form of 10**n in the auto scaling mode. AXIS3DH +calls ~PLT3DH or SKETCH, NUM3DH, and SYM3DH. See AXIS3. +.lit + +CALL AXIS3DH (x,y,x,a,b,g,s,n,ale,xm,xx,t,c,f,i) + +x,y,z (R): location of start of axis +a,b (R): angles from the x-y, x-z planes (in deg) of the ray + from (x,y,z) along the character string +g (R): angle of rotation about the ray defined by a,b (deg) +s (B): alpha string containing the axis title +n (I): number of characters in the string + > 0 : axis label on positive side (anti-clockwise) + < 0 : axis label on negative side (clockwise) + (100's digit) = 0 : labeled axis + = 1 : line and ticks only--no labeling +ale (R): length of axis + > 0 : tick marks placed same side of axis as title + = 0 : no action + < 0 : tick marks placed opposite side of axis from title +xm (R): value of first marking on the axis +xx (R): value of last marking on the axis +t (R): number of tick marks + specification is coded in the form MMM.mmss where + MMM is the number of major tick marks ( MMM > 0), mm is + the number of minor tick marks between major tick marks + (100 > mm => 0), and ss is the number of subminor tick + marks between minor tick marks (100 > ss => 0). + (example 1.0102 produces I_._._i_._._I) +c (R): size of characters + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +f (R): number label format (see NUMBER) +i (I): hidden line option flag + = 0 : use PLT3DH + = 1 : use SKETCH +.end lit + + +.hl2 SUBROUTINE CUBE +.p +~CUBE plots the 6 surface polygons of a 3-d "cube" into the +~INIT3DH 3-d plotting package. Either ~SKETCH or ~PLT3DH may be used. +.lit + +CALL CUBE (x1,x2,y1,y2,z1,z2,i,h) + +x1,y1,z1 (R): corner of cube +x2,y2,z2 (R): oposite corner of "cube" from corner 1 +i (I): SKETCH flag for last SKETCH call in routine + Note: (returned) value is the SKETCH return +h (L): hide flag + = .TRUE. SKETCH routine used + = .FALSE. PLT3DH routine used +.end lit + +.hl2 SUBROUTINE NUM3DH +.p +.x SKETCH +.x number +.x hidden line removal +~NUM3D plots a floating point number (see NUMBER) in 3-d using either +~PLT3DH or SKETCH. The symbols are plotted in the plane defined by a,b,g. +.lit + +CALL NUM3DH (x,y,z,a,b,g,f,e,i) + +x,y,z (R): lower-left corner of string + If x=999, y=999, z=999 then string is continued from + lower right of previous SYM3DH or NUM3DH call +a,b (R): angles from the x-y, x-z planes (in deg) of the ray + from (x,y,z) along the base of the character string +g (R): angle of rotation about the ray defined by a,b (deg) +h (R): height of the number to be plotted +f (R): alpha array containing the text to be plotted (byte array) +e (R): format of number representation n.j + (see NUMBER) +i (I): hidden line option flag + = 0 : use PLT3DH + = 1 : use SKETCH +.end lit + +.hl2 SUBROUTINE PLT3DH +.p +.x hidden line removal +~PLT3DH is a routine which operates in a similar as PLOT but in 3-d. +It is, however, independent of PLOT3D. A relative ~origin is +maintained (separate from the PLOT routine parameters) which is +initalized by INIT3DH. PLT3DH calls PLOT after transforming (x,y,z). +PLT3DH is also independent of the ~SKETCH routine. Lines plotted with +PLT3DH are always completely visible. +To use the hidden line removal SKETCH must be used. +.lit + +CALL PLT3DH (x,y,z,i) + +x,y,z (R): coordinates of point (in 3 space) +i (I): plot function parameter + = 0: line color control + x is the line color + if x < 0 screen is cleared + if x >= 0 plotting angle (in PLOT) becomes y + = 2: draw to (x,y,z) with 'pen down' + = -2: same as i=2. Point (x,y,z) becomes new origin + = 3: move to (x,y,z) with 'pen up' + = -3: same as i=3. Point (x,y,z) becomes new origin + = 9: erase to (x,y,z) (erase on Ramtek is color 0) + = -9: erase to (x,y,z) becomes new origin +.end lit + +.hl2 SUBROUTINE SKETCH +.p +.x hidden line removal +~SKETCH is the central plot routine for hidden line removal 3-d plotting. +SKETCH is called for each ~polygon or line segment. Each polygon or +line segment is described by a set of points in (x,y,z) arrays. +For polygons, +these should be in either clockwise or counter-clockwise direction with +the last point equal to the first. Holes in polygons are created by +continuing the last outer edge point (which is also the first outer edge +point) to the inner hole edges and back. The option flag, i, should be 0 +for all but the last polygon. When i=0, SKETCH stores the input polygons. +When i is set to be 1, the resulting scene visible lines are computed and +plotted by calls to PLOT. This process may take considerable cpu time +as well as memory storage space when the number of polygons is large. +The maximum number of edges of a polygon is 160. +.p +Note that SKETCH requires a large working area in a named ~COMMON area +described in INIT3DH. Note SKETCH will fail if the memory limits are +exceeded. For the most part an error flag will be set. Ocassionally, +the scene will be corrupted when the memory limits are exceeded without +the error flag being set. +.lit + +CALL SKETCH (x,y,z,np,i) + +x,y,z (R): arrays contain polygon edges (max 160) +np (I): number of points in x,y, and z +i (I): option flag. Should be 0 for all input polygons + except the last, when it should be 1. + + (Note: if i+10 is used for i then the first z value + is used for all (x,y) points.) + + i set to -1 (returned) if a memory error occurs +.end lit + +.hl2 SUBROUTINE SYM3DH +.x SKETCH +.x SYMBOL +.x hidden line removal +.p +~SYM3DH plots an ASCII string (see SYMBOL) in 3-d using either ~PLT3DH +or SKETCH. The symbols are plotted in the plane defined by a,b,g. +.lit + +CALL SYM3DH (x,y,z,a,b,g,s,n,i) + +x,y,z (R): lower-left corner of string + If x=999, y=999, z=999 then string is continued from + lower right of previous SYM3DH or NUM3DH call +a,b (R): angles from the x-y, x-z planes (in deg) of the ray + from (x,y,z) along the base of the character string +g (R): angle of rotation about the ray defined by a,b (deg) +h (R): height of the string to be plotted in plot units +s (B): alpha array containing the text to be plotted +n (I): number of characters in string s +i (I): hidden line option flag + = 0 : use PLT3DH + = 1 : use SKETCH +.end lit + +.hl2 SUBROUTINE WHERE3H +.x PLT3DH +.p +~WHERE3H returns the 2d screen coordinates of the last point in a call to +PLT3DH. +.lit + +CALL WHERE3H (x,y) + +x,y (R): screen coordinates of last point of call to PLT3DH +.end lit + +.hl2 SUBROUTINE XFRM3D +.p +~XFRM3D uses the same scaling and origin as PLT3DH and SKETCH to +transform a 3-d points to screen (PLOT) coordinates. +.lit + +CALL XFRM3D (x,y,z,x1,y1,z1) + +x,y,z (R): input coordinates of point (in 3 space) +x1,y1,z1 (R): (returned) transformed coordinates of point (in 3 space) +.end lit + + +.CHAPTER Cursor Routines +.x INXTCHR +.p +The routines described in this chapter provide interactive cursor control. +When supported by the terminal, the Tektronix Graphics Inputs (GIN), +BITCURSOR or GETCURSOR, routines can be used. If the terminal has +a VT100-compatible text mode, the routines CURMOTION, CURRECT, and CURBAND, +can be used to simulate a GIN device. These routines use the VT100 +keypad and cursor keys. They rely on a machine-dependent routine +(INXTCHR) to read escape characters from the terminal. CURMOTION, +CURRECT, and CURBAND return the internal screen "resolution" used +in computing the location of the cursor. This may not correspond to the +actual hardware resolution of the terminal screen. +.p +The routine CURLOCATE provides +a technique for placing a fixed "cursor mark" on the screen. +.p +A program CURTEST is provided to test and evaluate these cursor routines. + +.hl1 SUBROUTINE BITCURSOR +.x cursor +.x graphics tablet +.x bit pad one +.x vt125 +.p +~BITCURSOR moves a cross-hair cursor on a VT100 equipped with a retro-graphics +card (VT125) and a BIT PAD ONE graphics tablet. The VT125 is used in the +Tek 4010 mode with a graphics point returned when a key is pressed on the +bit pad puck (or stylus). +.lit + +CALL BITCURSOR (x,y,k,rx,ry) + +x,y (R): (returned) selected cursor position (in plot units) +k (I): (returned) key code + = 0 (Z) key pressed on bit pad puck + = 1 (1) key pressed on bit pad puck + = 2 (2) key pressed on bit pad puck + = 3 (3) key pressed on bit pad puck +rx (R): resolution of screen in x direction (returned) +ry (R): resolution of screen in y direction (returned) +.end lit + +.x cursor +.hl1 SUBROUTINE CURLOCATE +.p +~CURLOCATE produces a simulated "x" cursor mark on the screen graphics +device (~Ramtek or ~terminal device) +When only the metafile is initialized a call to CURLOCATE is a dummy call. +The terminal takes precidence over the Ramtek when both are in use. +Erasure of cursor on requires the correct location where it was first plotted. +CURLOCATE uses the ~XOR capbility of graphics terminal to place and +remove the cursor. If the terminal has neither erase or XOR capability, +the graphics cursor can not be erased without clearing the entire screen. +If the (x,y) position is off the screen, the cursor will be located on +closest edge of the screen to the desired point. +.lit + +CALL CURLOCATE (x,y,n,ir) + +x,y (R): cursor position +n (I): cursor number/size (0-4) + < 0 erase cursor + > 0 locate cursor +ir (I): Ramtek cursor control (recognized if Ramtek is output) + = 0 Ramtek cursor device used + = 1 plotted Ramtek cursor mark used +.end lit + +.hl1 SUBROUTINE CURMOTION +.p +~CURMOTION produces a graphics ~cursor on the ~Ramtek or ~terminal +When no screen devices are initialized a call to CURMOTION is a dummy call. +Terminal is used in preference to Ramtek. +This routine is supported only on terminals which can emulate the VT100 +numeric keypad. The terminal text cursor and VT100 numeric keypad +keys are used to move the graphics cursor to a desired location and +a return function key is pressed to select the cursor location. Only +, , PF keys and the numeric key pad keys will be recognized +as return command keys. PF1 changes the cursor step movement size in three +sizes. As this happens the cursor changes sizes on the screen. +The cursor position is typed to the terminal when the Ramtek is used. +The cursor is moved in multiples of the pixel resolution. The +formula below shows the conversion. All other PF keys and the numeric +key pad keys will return the arguments shown below. Other keys are +not recognized. NOTE: The input buffer is 128 characters. If you exceed +this buffer the program may bomb. Each cursor key input uses 3 characters. +.lit + + pixel number = (scalefactor * x + origin)/pixelresolution + +.end lit +.lit +CALL CURMOTION (x,y,is,rx,ry) + +x,y (R): (returned) selected cursor position +is (I): (returned) status flag + < 0 error + = 0 return key pressed + = 1 space key pressed + = 2,3,4 PF2,PF3,PF4 keys on VT100 pressed + = 10...19 VT100 numeric key pad keys 0...9 pressed + = 20 numeric key pad period key pressed + = 21 numeric key pad enter key pressed + = 22 numeric key pad comma key pressed + = 23 numeric key pad dash key pressed +rx (B): resolution of screen in x direction (returned) +ry (R): resolution of screen in y direction (returned) +.end lit + +.hl1 SUBROUTINE CURBAND +.p +CURBAND is similar to the ~CURMOTION subroutine except that two +lines are "rubber banded" with the simulated cursor motion. This +routine is supported only on terminals which can emulate the VT100 +numeric keypad. The line segment rubberbanding can be disabled if desired. +.lit + +CALL CURBAND (x,y,is,rx,ry,x1,y2,x2,y2) + +x,y (R): (returned) selected cursor position +is (I): (returned) status flag + < 0 error + = 0 return key pressed + = 1 space key pressed + = 2,3,4 PF2,PF3,PF4 keys on VT100 pressed + = 10...19 VT100 numeric key pad keys 0...9 pressed + = 20 numeric key pad period key pressed + = 21 numeric key pad enter key pressed + = 22 numeric key pad comma key pressed + = 23 numeric key pad dash key pressed +rx (R): resolution of screen in x direction (returned) +ry (R): resolution of screen in y direction (returned) +x1,y1 (R): starting point of rubber banded line 1 + if x1=999, this line segment is not used +x2,y2 (R): starting point of rubber banded line 2 + if x2=999, this line segment is not used +.end lit + +.hl 1 SUBROUTINE CURRECT +.p +~CURRECT is similar to the ~CURBAND subroutine except that a +~rectangle is moved with cursor motion. This +routine is supported only on terminals which can emulate the VT100 +numeric keypad. +.lit + +CALL CURRECT (x,y,is,rx,ry,x1,y2,x2,y2) + +x,y (R): (returned) selected cursor position/start position +is (I): (returned) status flag + < 0 error + = 0 return key pressed + = 1 space key pressed + = 2,3,4 PF2,PF3,PF4 keys on VT100 pressed + = 10...19 VT100 numeric key pad keys 0...9 pressed + = 20 numeric key pad period key pressed + = 21 numeric key pad enter key pressed + = 22 numeric key pad comma key pressed + = 23 numeric key pad dash key pressed +rx (R): resolution of screen in x direction (returned) +ry (R): resolution of screen in y direction (returned) +x1,y1 (R): lower left corner of rectangle +x2,y2 (R): upper right corner of rectangle +.end lit + +.hl SUBROUTINE GETCURSOR +.p +~GETCURSOR inquires the ~Tektronix GIN device for the location +pointed to by the GIN device. Return code is screen device +dependent. This routine is does support all screen devices. When +a device is not supported, the routine returns without doing anything. +Screen device must be in the graphics mode. +GETCURSOR assumes that the ~GIN terminator is a CR (carriage return). +Note: When using an Alpha +key for the return status DO NOT use the key as this will prevent +the correct reading of the returned data. +.lit + +CALL GETCURSOR (x,y,k,rx,ry) + +x,y (R): (returned) cross-hair location (in LONGLIB coordinates) +k (I): (returned) GIN status code return (ascii code) +rx (R): resolution of screen in x direction (returned) +ry (R): resolution of screen in y direction (returned) +.end lit + +.CHAPTER MAP SUBROUTINES + +.x map routines +.x earth.dat +.x lndsea1.dat +.p +LONGLIB also supports the plotting of maps of the physical earth's surface +by providing map routines. +Two data files (EARTH.DAT and LNDSEA1.DAT) are included in the LONGLIB +graphics library package. EARTH.DAT contains the digitized locations of +the edges of the earth's landmasses. It forms the basis of a set of +EARTH OUTLINE map routines discussed below. LNDSEA1.DAT contains a bit map +of land/sea areas. It forms the basis of the LAND AREA map routines discusses +in the second section. +.p +Note: these routines assume that the plot package has already been opened. + +.hl 1 EARTH OUTLINE MAPS +.p +To date only a small number of routines have been generated for using this data +file but more will be added in the future. Current routines allow for +plotting the ~earth outline map in 3d or in a linear projection. +.p +A data file (EARTH.DAT) which contains a ~map of the land/ocean interface +and a set of routines to access this data has been included in the LONGLIB +graphics library. The data file (of unknown origin) contains a list of +latitudes and longitudes of the land/ocean edges at about a 10 km resolution. +It is only a geographic map and does not contain political boundries. +Although imperfect, it is more than adequate for map drawing, etc. +Due to the high resolution, the EARTH.DAT file contains a lot of pen +motions, requiring a long plotting time. +.p +Fortran file unit 2 should be reserved for accessing the map data +file by these routines. The logical name ~LONGLOC: must be assigned +to be the location of the EARTH.DAT file. +.p +Routines using the land outline file include those for plotting on +3d spheres, flat surfaces, etc. + +.hl 2 SUBROUTINE EARTH3D +.p +~EARTH3D permits 3d plotting of the earth land map. This routine +uses the ~INIT3D and ~PLOT3D 3d graphics package. It will plot the +entire earth map with the option of either a spherical earth or +an ellipsoidal earth. The radius may be specified. The transformation +from a latitude/longitude pair (a,b) in radians on the earth's suface to the +3d plotting vector v is: +.lit + + rad = r * (1 - f*sin(a)) + call sprect1(v,b,a-pi/2,rad) + call plot3d(v(1),v(2),v(3),2) +where + pi = 3.141592654 + v is dimensioned v(3) +.end lit +.lit + +CALL EARTH3D(r,f) + +r (R): nominal earth radius (in plotting units) +f (R): earth flatness + = 0 for spherical earth + = 3.3528132e-3 for an ellipsoidal earth +.end lit + +.hl 2 SUBROUTINE LANDMAP +.x projection +.p +~LANDMAP plots the earth land map using a linear projection. The latitude +and longitude are assumed to be a linear grid on a flat surface. +This routine will plot the entire map surface. Use +of the PLOT routine clipping option will permit plotting only limited +of the map surface if desired. The transformation of a latitude/longitude +pair (a,b) in degrees to an (x,y) pair for plotting is: +.lit + + x = (b - s) * long / 360 + y = (a + 90) * lat / 180 +.end lit +.lit + +CALL LANDMAP(alat,along,s) + +alat,along (R): latitude, longitude scale factor (degrees/plot unit) +s (R): longitude of left-mode edge of map (-180 to +180) +.end lit + +.hl 2 SUBROUTINE POLARMAP +.x projection +.p +~POLARMAP plots the earth land map using a polar projection. The latitude +is plotted as a linear radius. This routine will plot the entire northern +or southern hemisphere. The transformation from a visible point (in the +appropriate hemisphere) latitude/longitude pair (a,b) in degrees to a +plotted (x,y) pair is: +.lit + + a = b * sgn(r) + a + x = cos( a * pi / 180) * r / 90 + x0 + y = sin( a * pi / 180) * r / 90 + y0 +where + pi = 3.141592654 +.end lit +.lit + +CALL POLARMAP(x0,y0,r,a) + +x0,y0 (R): pole location (in plot units) +r (R): radius of equator (in plot units) + > northern hemisphere + < southern hemisphere +a (R): angle of prime meridian from horizontal (deg CCW) +.end lit + +.hl 2 SUBROUTINE SPRECT1 +.p +~SPRECT1 converts a ~spherical coordinate value (in a latitude/longitude +style spherical system) to ~rectangular coordinates. +The transformation from a latitude/longitude pair (a,b) in degrees to a +rectangular (x,y) pair is: +.lit + + a = b * sgn(r) + a + x = cos( a * pi / 180) * r / 90 + x0 + y = sin( a * pi / 180) * r / 90 + y0 +where + pi = 3.141592654 +.end lit +.lit + +CALL SPRECT1(v,t,p,r) + +v (R): output vector containing rectangular (z,y,z) coordinates + dimensioned v(3) (returned) +t (R): theta (longitude) angle (rad) +p (R): phi (latitude) angle (rad) +r (R): radius +.end lit + +.HL1 Land Area Map Routines +.x LNDSEA +.p +The LNDSEA1.DAT file contains a bit ~map of the land/sea area of the earth. +Using the file, a specified point of latitude and longitude can be +determined to be land or sea. +A routine, LNDSEA, opens the file and provides a flag to indicate +if the specified point is land or sea. +.p +Fortran file unit 1 should be reserved for accessing the map data +file by these routines. The logical name ~LONGLOC: must be assigned +to be the directory containing the LNDSEA1.DAT file. + +.hl 2 LNDSEA1.DAT Format +.p +The LNDSEA1.DAT is a direct access file is a world land/sea map +quantized to every 1/12 degree of +both latitude and longitude. An individual bit is used to indicate whether +a particular point is land or sea. The data is stored as 648 records +each of which contains all of the data for a 10 degree by 10 degree square. +Each record consists of 14400 (120*120) bits stored 30 bits per word +(4 words per each 1/12 degree strip of data). +The first word of the record indicates whether the entire 10 by 10 square +is all land or water using the following definition: +.lit + + -1 : square contains both land and sea + 0 : square contains all land + 1 : square contains all water + +.end lit +The next 4 words in each record are the bits for the bottom 1/12 degree +(lowest latitude) row of the 10 degree by 10 degree square with +longitude bins left to right. For each bit a 0 indicates land and a +1 indicates water. The records are ordered: +.lit + + record # Latitude range Longitude range +_________ _______________ _________________ + + 1 -90 to -80 0 to 10 + 2 -90 to -80 10 to 20 + . . . + 35 -90 to -80 340 to 350 + 36 -90 to -80 350 to 360 + 37 -80 to -70 0 to 10 + 38 -80 to -70 10 to 20 + . . . + 648 80 to 90 350 to 360 +.end lit +.p +See the source code for ~LNDSEA function for additional information. + +.hl 2 SUBROUTINE BITMAP +.x projection +.p +~BITMAP plots a land area by testing each point of the area using LNDSEA. +The plotting area is segmented into (nx X ny) regions. Each point is tested +for the presence of land/sea. For each resolutoin line of latitude, +a horizontal line is drawn through all points that are land (or sea as desired). +A linear projection is used. The latitude +and longitude are assumed to be a linear grid on a flat surface. +This routine will plot the entire map surface. Use +of the PLOT routine clipping option will permit plotting only limited +of the map surface if desired. The transformation of a latitude/longitude +pair (a,b) in degrees to an (x,y) pair for plotting is: +.lit + + x = (b - s) * along / 360 + y = (a + 90) * alat / 180 +.end lit +.lit + +CALL BITMAP(alat,along,s,nx,ny,i) + +alat,along (R): latitude, longitude axis length (plot units) +s (R): longitude of left-mode edge of map (-180 to +180) +nx,ny (I): x,y resolution specified as the number of lat/longs + to test for land/sea +i (I): plot flag + = 0 plot land area + = 1 plot sea area +.end lit + +.hl 2 INTEGER FUNCTION LNDSEA +.x projection +.p +~LNDSEA tests the point (lat, long) for land/sea using the LNDSEA1.DAT file. +It returns a 0 for land, 1 for sea. Uses Fortran file unit 1. +.lit + +iflag = LNDSEA(alat,along) + +alat (R): latitude (-90. to +90. degrees) +along (R): longitude (0. to +360. degrees) +iflag (I): land/sea flag (returned) + = -1 : error + = 0 : land + = 1 : sea (ocean, lake, sea) +.end lit + + +.chapter MASTER Subroutines + +.p +By popular request, a set of the most commonly used general-purpose +subroutines for complete function plots, charts, etc., +were included in the LONGLIB graphics library. +These subroutines are called "MASTER" Subroutines. +Each of these subroutines is self contained. When called, it +will initialize the plotting package, plot the required data, +and close the plotting package. Normally, +only one ~MASTER subroutine is called in a program. +However, options are available for +multiple calls to MASTER subroutines. +When the LONGLIB is initialized by a MASTER subroutine (which calls FRAME) +a metafile using Fortran file unit 3 is always created. +.p +Programming examples using MASTER routines are given in the chapter +on programming examples. +.p +To call a MASTER subroutine more than once in +a program the option flag must be set negative for all calls +but the last one which should be positive. (See also the PLOTTESTS program.) +To use more than one MASTER subroutine in a program: +.ls.dle'(',,')' +.le; On first MASTER subroutine call +set the option flag negative--this does not close plot package. +.le; on all additional calls to +MASTER subroutines set the option negative and greater than 10000--this +prevents re-opening plot package and does not close it. +.le; On the last call to a MASTER subroutine set option flag positive +but greater than zero--this closes plot package. +.els +.p +In summary, when LONGLIB is already open set the magnitude of the option flag +to greater than 10000. To prevent closing the plot package set option +flag negative. +When the plot package is closed in a MASTER subroutine CTERM(-2) is used +to ask if a termina lscreen clear (terminal plotting only) should be done. +MASTER subroutines always return the terminal to the text mode after call. +When color options are enabled, the color marked "(return)" is +the color in current use after call. +.p +Note: when passing varables ~ASCII strings do not use ~VAX ~FORTRAN +~CHARACTER data type. Use ~BYTE data type arrays or use %REF(). See +the comments under the section on machine dependency and the introduction +to the plot routine section. +.x common block +.p +Most MASTER subroutines have +~common blocks with the same name prefixed with the letter +"C" which contain the scaling information used to plot +the data line. This can be useful for plotting additional annotations, +etc. +.p +The following pages document the currently defined MASTER Subroutines. +Additional subroutines may be added as suggested by the users. + +.hl1 MASTER Routine Index +.p +The sections that follow detail each MASTER routine. A brief index +of the capabilities of each Master routine is given below. To select +a MASTER routine, determine the category of plotting needed and +look at the available MASTER routine capabilities. For general purpose +line plotting where flexibility in specifying the axes, +the routine GLPLOT is recommended. + +.tp4 +.hl 2 Pie Chart +.ls0 +.le; PICHRT +.els + +.tp4 +.hl 2 Bar Chart +.ls0 +.le; BARCHR (can fill area between lines) +.els + +.tp4 +.hl 2 Single linear/linear line +.ls0 +.le; PLOTSC (simple) +.le; GLPLOT (flexible axis specification) +.le; PLOTLGXL (allows log lines, software line types) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 Two linear/linear lines on the same plot +.ls0 +.le; PLOTSC2 (simple) +.le; GLPLOT (flexible axis specification) +.le; PLOTLG2 (allows log lines) +.le; PLOTLGX (allows log lines, flexible axis specification) +.le; PLOTLGXL (allows log lines, software line types) +.le; BARCHR (can fill area between lines) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 Multiple linear/linear lines on the same plot +.ls0 +.le; GLPLOT (more complex but flexible axis specification) +.le; PLOTLGX (allows log lines, flexible axis specification) +.le; PLOTLGXL (software line types) +.le; SEISPL (special options) +.le; SPLOTS (can show error bars) +.le; SPLOTSX (can show error bars with flexible axis) +.le; BARCHR (can fill area between lines) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 Multiple log/linear or log/log lines on the same plot +.ls0 +.le; PLOTLG (relatively simple) +.le; PLOTLGX (more complex, flexible axis specification) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 Scatter plot +.ls0 +.le; SCATPL +.le; SPLOTS (can show error bars) +.le; SPLOTSX (can show error bars with flexible axis) +.le; SEISPL (special options) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 1-d Histogram +.ls0 +.le; PHIST (can show mean/standard deviation) +.le; BARCHR (bar chart) +.els + +.tp4 +.hl2 Lines/points with error bars +.ls0 +.le; SPLOTS (simple) +.le; SPLOTSX (flexible axis specification) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 Special plot formats +.ls0 +.le; SEISPL (forms used in seismic data plots) +.le; BARCHR (bar chart) +.le; PICHRT (pie chart) +.le; LSPLOT (options via array) +.els + +.tp4 +.hl2 Contour Plot with equally spaced data +.ls0 +.le; CNTRLN (simple, robust) +.le; LCNTR (simple, less-robust, contour line types and labels) +.els + +.tp4 +.hl2 Contour Plot with unequally spaced data +.ls0 +.le;CNTLN (triangulates points then contours) +.els + +.tp4 +.hl2 3-d Surface slices +.ls0 +.le; VAX3D (simple) +.le; VAX3DX (more complex, with flexible axis specification) +.els + +.tp4 +.hl2 3-d Surface mesh (no hidden line removal): +.ls0 +.le; MESH3D (simple) +.le; MESH3DX (more complex, with flexible axis specification) +.els + +.tp4 +.hl2 3-d Surface mesh (hidden line removal) +.ls0 +.le; MVAX3D (simple) +.le; MVAX3DX (more complex, with flexible axis specification) +.els + +.tp4 +.hl2 3-d Surface mesh with contour plot (hidden line removal) +.ls0 +.le; CVAX3D (simple) +.le; CVAX3DX (more complex, with flexible axis specification) +.els + +.tp4 +.hl2 3-d Surface triangular mesh (hidden line removal) +.ls0 +.le; T3DH (uses INIT3DH) +.els + +.tp4 +.hl2 Unequally sampled 3-d Surface (hidden line removal): +.ls0 +.le; TRIG3DH (uses INIT3DH) +.els + +.tp4 +.hl2 3-d Histogram with hidden line removal +.ls0 +.le; HIST3D (uses INIT3DH) +.le; MVAX3D (simple) +.le; MVAX3DX (more complex, with flexible axis specification) +.le; CVAX3D (simple, can include contour plot) +.le; CVAX3DX (with flexible axis specification, with contour plot) +.els + +.tp4 +.hl2 3-d Contour Plot with equally spaced data (no hidden line removal) +.ls0 +.le; CNT3D (simple, robust) +.le; CNT3DX (more complex, with flexible axis specification) +.els + +.tp4 +.hl2 4/5-d Surface plots: +.ls0 +.le; VAX5D (slices) +.le; MVAX5D (mesh/histogram with hidden line removal) +.els + + +.pg +.hl1 SUBROUTINE BARCHR +.p +~BARCHR plots a bar chart with optionally shaded bar segments and +descriptive legends. In addition, multiple lines with shading between +lines can be plotted. Legend can be automatically placed +or the user can specify the location of the legend. In the bar chart +mode, bars can run vertically or horizontally. +b(i,j) specifies the ith bar and jth segment of bar (or horizontal line +depending on iflag option). Top of jth segment or height of jth line +is computed from: +.lit + + j + yplotted = ylen * (Sum b(i,k) - bm)/(bx-bm) + k=1 +.end lit +.lit + +CALL BARCHR(b,nb,ns,sh,iflag,xl,yl,bm,bx,f,nd,sp,sl,nsl,bl,nbl,cs + t,nt,bt,nbt,lt,nlt,tcs,a,d,>) + +b (R): bar data array dimensioned b(nb,ns) +nb (I): number of bars/number of points in each line +ns (I): number of segments in each bar/number of lines +sh (I): shade option for segment/area between lines + dimensioned sh(ns) + sh shade pattern + ____ _________________________ + 0 no shading + 1 -45 deg solid lines + 2 horizontal solid lines + 3 +45 deg solid lines + 4 vertical deg solid lines + 5 -45 deg dotted lines + 6 horizontal dotted lines + 7 +45 deg dotted lines + 8 vertical deg dotted lines + 9 +/- 45 deg dotted lines + 10 vertical/horizontal dotted lines + 11 +/- 45 deg solid lines + 12 vertical/horizontal solid lines +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : color array not used + = 2 : color array used + (10's) = 0 : bar chart with vertical bars + = 1 : bar chart with horzontal bars + = 2 : multiple line chart + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +xlen (R): length of horizontal axis + < 0 : chart is enclosed in a box + > 0 : only bottom and left axes plotted +ylen (R): length of vertical axis +bm,bx (R): minimum and maximum values to be shown on chart + note: if bx=bm, values computed from b array will be used +f (R): format for numeric labels on axis (see NUMBER) +nd (I): number of divsions of bar length axis + < 0 : division lines shown on chart + = 0 : no division lines or numeric labels + > 0 : division lines shown +sp (R): width of bar (ignored for line plot) + = 0 : auto scaling with evenly spaced bars + > 0 : bars grouped in groups of int(sp). Each + bar has width frac(sp). +sl (C): segment legend labels (CHARACTER data type) + dimensioned sl(ns) +nsl (I): number of characters to use in plotting sl's + = 0 : no label plotted +bl (C): bar labels (CHARACTER data type) dimensioned bl(nb) +nbl (I): number of characters to use in plotting bl's + = 0 : no label plotted +cs (R): legend/bar label character height +t (B): title string placed on top of chart +nt (I): number of characters in t + = 0 : no label plotted +bt (B): title string placed at base of bars +nbt (I): number of characters in bt + = 0 : bt not plotted +lt (B): title string placed on bar length axis +nlt (I): number of characters in lt + = 0 : lt not plotted +tcs (R): height of title strings +a (R): legend location/shading box size dimensioned a(3) + a(1) : legend box size + < 0 : legend placed to right of chart, a(2) + and a(3) are not used + = 0 : no legend + > 0 : a(2) and a(3) used to locate legend + a(2) : x position of lower left corner of legend + a(3) : y position of lower left corner of legend +d (R): distance between shading lines + < 0 : line width array used + > 0 : line width array not used +ip (I): line width array (used only if d<0) + p(1) : axis line width + p(2) : division line width + p(3) : bar outline/data line width + p(4) : labeling line width + p(5) : title line width (bt,lt) + p(6) : title line width (t) +ic (I): color array (used only if mod(|iflag|,10)=2) + c(1) : t title color (return) + c(2) : bt title color + c(3) : lt title color + c(4) : axis numberic label colors + c(5) : sl label color + c(6) : bl label color + c(7) : segment 1 color + c(8) : segment 2 color + ... ... +.end lit + +.pg +.hl 1 SUBROUTINE CNT3D +.p +CNT3D plots a simple 3-d contour of equally spaced points with no hidden +line removal. (see CNT3DX) +~CNT3D calls CNT3DX using default axis parameters to simplify calling +procedure. +.lit + +CALL CNT3D(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,nl,as,ae,ie,iflag,iax, + ,l>>>) + +See CNT3DX for parameter description. + (iax is limited to a single digit value) +.end lit +.hl 1 SUBROUTINE CNT3DX +.p +.x 3-d contour plot +~CNT3DX is a simple 3-d contour plotting routine. A 3-d surface is +contoured by plotting slices through the surface parallel to the x-z plane +of the surface which have the same y value. The input consists of a 2 +dimensional grid of y values. For each contour level the input array +is scanned cell-by-cell. A segment of the contour is determined by linearily +interpolating the edges of the square formed by 4 adjacent points (a cell). +For example, if the current contour value is 1, and y(1,1)=0, y(1,2)=2, +y(2,2)=3, and y(1,2)=4, a contour line is assumed to exist for this +cell as shown: +.lit + + y(1,2) y(2,2) + * * + + + + \ + * + * + y(1,1) y(1,2) + +.end lit +This line segment is plotted using the same approach as ~VAX3DX. +No hidden line removal is provided. The calling sequence is nearly +identical for both CNT3DX and VAX3DX. The height of plotted contours +relative to the y axis is calibrated to z axis so that scale can be +taken from the plot. No perspective is used. Options exist to vary +the plotting angle and to plot axes. Contour values can be +distinguished by color and/or line type. +.p +Origin of the plot is in the lower-left corner. The x axis runs +plotted left to right along the plot bottom. The y axis is plotted +as a vertical displacement offset by the z axis value. The z axis appears +to point into the screen. This gives the illusion of depth in the plot. +See AXIS2 for detailed discription of axis parameters. +.p +The pathological case of two contour lines within a cell may case the +routine to incorrectly trace the contour through that cell. +.lit + +CALL CNT3DX(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,nl,as,ae,ie,iflag,iax, + ,l>>>) + +d (R): array of y values dimensioned d(ndx,ndz) +ndx,ndz (I): x and z dimensions of d array +nx,nz (I): x and z sizes of surface to plot d array +a (R): angle of x axis from horizontal 0-85 degrees +b (R): angle of z axis from horizontal 0-90 degrees + note: origin d(1,1) is in lower-left corner + x axis runs left to right on screen + y axis runs up to down on screen + z axis appears to run into the screen but is angled + to the right +xh,yh,zh (R): length of each axis +nl (I): number of uniformly spaced contour levels, + < 0 : max and min of v are used for as, ae + (j)th contour is (j-1)*(ae-as)/(nl-1)+as + = 0 : int(ae) specifies the number of contour values + where as is an array of the contour values + > 0 : number of uniformly space contour levels, + (j)th contour is (j-1)*(ae-as)/(nl-1)+as +as (R): first contour level (nl > 0) + array of contour levels (nl=0) dimensioned as(int(ae)) +ae (R): last contour level (nl > 0) + number of contour levels in as (nl=0) ae>0 +ie (I): contour edge option flag + < 0 contour edge added when surface below contour + = 0 no contour edges added + > 0 contour edge added when surface above contour +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) >10000: do not initialize LONGLIB before plotting + (1's digit) = 1 : ignor color and line type arrays + 2 : use color array but not line type array + 3 : ignore color array, use line type array + 4 : use color and line type arrays + (10's digit)= 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axis, using input scale factors dm and dx + = 0 : do not plot axis, optional axis parameters not used + input scaling is computed from input array + > 0 : plot axis, using scaling computed from input array, + need optional axis parameters + (1's digit) = 1 : Plot actual max/min or input values for Y axis + = 2 : Plot smoothed values for Y axis + (10's digit) = 0 : Use default axis type + = 1 : Use input AXIS2-type axis parameters +(NOTE: the following optional parameters are used only if iax<0 or + mod(iflag,10)=1) +xt (B): title of x axis (width) +nxt (I): number of characters in xt + = 0 : no axis plotted + > 0 : normal +xs,xe (R): starting and ending values displayed on x axis +(see AXIS2 for detailed description of axis parameters) +nmx (I): number of minor ticks between major ticks on x axis +nnx (I): highlight length of nnx-th minor tick on x axis +mlx (I): number of major tick marks on x axis +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndx (I): number of digits to right of decimal point on x axis +smx (R): major tick length on x axis +yt (B): title of y axis (depth) +nyt (I): number of characters in yt + = 0 : no y axis plotted + > 0 : normal +nmy (I): number of minor ticks between major ticks on y axis +nny (I): highlight length of nny-th minor tick on y axis +mly (I): number of major tick marks on y axis +tsy (R): size of title and numbers on y axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndy (I): number of digits to right of decimal point on y axis +smy (R): major tick length on y axis +zt (B): title of z axis (height) +nzt (I): number of characters in zt + = 0 : no z axis plotted + > 0 : normal +ze,ze (R): starting and ending valued displayed on z axis +nmz (I): number of minor ticks between major ticks on z axis +nnz (I): highlight length of nnz-th minor tick on z axis +mlz (I): number of major tick marks on z axis +tsz (R): size of title and numbers on z axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndz (I): number of digits to right of decimal point on z axis +smz (R): major tick length on z axis +(NOTE: the following are required only if iax<0 or mod(iflag,10)<>0) +dm,dx (R): minimum and maximum values of d array +(NOTE: the following is required only if mod(iflag,10) <> 0) +ic (I): color array + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for contour line 1 + ic(6) : color for contour line 2, etc. + ... ... +l (I): contour linetype list +.end lit + +.pg +.hl1 SUBROUTINE CNTLN +.p +.x contour plot +~CNTLN plots a contour plot of a randomly scatted set of points in +three dimensions. It uses INIT3dH +The input consists of a list of triplets of a surface +value. The triplets are triangulated using ~TRIANGC and contours +determined by linearily interpolating the edges of the triangles. +The contour values may be uniformly spaced between the starting +and end values or from a list. Other than color, the +sequence of plotting (min to max), and line typing of various contour +lines, no contour line identification scheme is provided. Caution +should be excercised when interpreting plot since the distribution of +input points may affect the placement of the contour lines. +.lit + +CALL CNTLN(x,y,z,n,xl,yl,iflag,nc,c,ia,xt,nxt,tx,sx,fx, + yt,nyt,ty,sy,fy,t,nt,xm,xx,ym,yx<<,ic>,l>) + +x,y,z (R): array of point triplets (x,y,z) +n (I): number of points +xl (R): x axis length in inches +yl (R): y axis length in inches +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) >10000: do not initialize LONGLIB before plotting + (1's digit) = 1 : do not use color or line type arrays + = 2 : use color but not line type array + = 3 : do not use color but use line type array + = 4 : use both color and line type arrays + (10's digit) = 0 : just x,y labeled axes + = 1 : axes and axis line/ticks on top and sides + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +nc (I): number of contour levels + < 0 : c(1) is the minimum contour level and c(2) is + the contour step size, abs(nc) levels plotted + > 0 : c contains contours levels, c dimensioned c(nc) +c (R): list of contour levels +ia (I): axis option flag + < 0 : do not plot axes + > 0 : plot axes + (1's digit) = 1 : plot y axis using max/min of y array + = 2 : plot y axis using max/min of y array + smoothed by SCALE + = 3 : plot y axis using input max/min + = 4 : plot y axis using input max/min + smoothed by SCALE + (10's digit) = 1 : plot x axis using max/min of x array + = 2 : plot x axis using max/min of x array + smoothed by SCALE + = 3 : plot x axis using input max/min + = 4 : plot x axis using input max/min + smoothed by SCALE + (100's digit) = 0 : normal contouring + = 1 : show triangulation used without contours +xt (B): x axis title string +nxt (I): number of characters in title + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +tx (R): number and pattern of axis ticks (see AXIS3) +sx (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fx (R): format of axis number labeling (see AXIS3) +yt (B): y axis title string +nyt (I): number of characters in title + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +ty (R): number and pattern of axis ticks (see AXIS3) +sy (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fy (R): format of axis number labeling (see AXIS3) +t (B): plot title string +nt (I): number of characters in t (limited to 99 characters) + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x axis +xx (R): maximum value of x axis +ym (R): minimum value of y axis +yx (R): maximum value of y axis +ic (I): color list (optionally used) + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color contour (1) + ic(6) : color contour (2), etc. + ... ... +l (I): line type list for contours (optionally used) + +common /ccntrplt/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE CNTRPLT +.p +.x contour plot +~CNTRPLT plots a contour plot of a uniformly sampled 2-d input +array. The input consists of a 2 dimensional grid of y values. For each +contour level the array is scanned cell by cell. +A contour segment is determined by linearily interpolating the edges of the +square formed by 4 adjacent points (a cell). For example, if the current +contour value is 1, and y(1,1)=0, y(1,2)=2, y(2,2)=3, and y(1,2)=4, +a contour line is assumed to exist for this cell as shown: +.lit + + y(1,2) y(2,2) + * * + + + + \ + * + * + y(1,1) y(1,2) + +.end lit +The contour values are uniformly spaced between the input starting +and end values or automatically selected values. Other than color, the +sequence of plotting (min to max), and line typing of various contour +lines, no contour line identification scheme is +provided. Log axes are available but data points are plotted using +linear positioning. (Note: common block scale factors will be log values +if the log axes are selected.) +.p +The pathological case of two contour lines within a cell may case the +routine to incorrectly trace the contour through that cell. +.lit + +CALL CNTRPLT(v,ndx,ndy,nx,ny,nl,as,ae,iflag,xl,yl,xt,nxt,yt,nyt, + t,nt,xm,xx,ym,yx<<,ic>,l>) + +v (R): 2-d array dimensioned v(ndx,ndy) +ndx,ndy (I): dimensions of v data array +nx,ny (I): number of points in each array dimension +nl (I): number of uniformly spaced contour levels, + < 0 : max and min of v are used for as, ae + (j)th contour is (j-1)*(ae-as)/(nl-1)+as + = 0 : int(ae) specifies the number of contour values + where as is an array of the contour values + > 0 : number of uniformly space contour levels, + (j)th contour is (j-1)*(ae-as)/(nl-1)+as +as (R): first contour level (nl > 0) + array of contour levels (nl=0) dimensioned as(int(ae)) +ae (R): last contour level (nl > 0) + number of contour levels in as (nl=0) ae>0 +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) >10000: do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : plot box with axis tick marks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : plot ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +xl (R): x axis length in inches (integer-valued) + > 0 : use input scaling in xm,xx for axis + < 0 : use smoothed input scaling in xm,xx for axis +yl (R): y axis length in inches (integer valued) + > 0 : use input scaling in ym,yx for axis + < 0 : use smoothed input scaling in ym,yx for axis +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string +nt (I): number of characters in t (limited to 99 characters) + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x axis (will be smoothed for xl < 0) +xx (R): maximum value of x axis (will be smoothed for xl < 0) +ym (R): minimum value of y axis (will be smoothed for yl < 0) +yx (R): maximum value of y axis (will be smoothed for yl < 0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color array + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponent + ic(6) : color for title (return) + ic(7) : color for contour line 1 + ic(8) : color for contour line 2 + ic(9) : etc. ... +l (I): line type list for contours (required only if |nt|/100>0) + +common /ccntrplt/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl 1 SUBROUTINE CVAX3D +.p +CVAX3D plots a 3d surface with hidden line removal using either +a mesh or a histogram. Optionally, a contour plot can be included +beneath the surface. The vertical space may be specified. +See CVAX3DX. +~CVAX3D calls CVAX3DX using default axis parameters to simplify the calling +procedure. +.lit + +CALL CVAX3D(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag, + iax,ds,nc,cv,icl,nm,il,ip, + >>) +.end lit + +.hl 1 SUBROUTINE CVAX3DX +.p +.x 2-d surface plot +~CVAX3DX plots a 3-d surface with hidden lines removed using ~PLT3D to +produce a mesh surface or ~HLT3D to produce a 2-d histogram with an optional +contour plot made ~GCONTR and plotted on a plane paralell to the surface +plane. Axes and a back panel can be optionally plotted. Optionally, +a path surface may be plotted which connects the surface and contour plots +over a users specified path. The 3d surface is plotted in a manner similar +to MVAX3DX. The visible upper side of the surface and the visible lower +side of the surface can be optionally shown using different colors and +line types. +.x MVAX3DX +.p +Origin of the plot is in the upper-left corner. The x axis runs +left to right along the plot bottom. The y axis is plotted +as a vertical displacement offset by the z axis value. The z axis appears +to point out of the screen. The contour plot is plotted below the surface +with a user-specified vertical spacing. The contour plot plane is plotted +paralell to the z=0 plane of the surface with the (i,j) indicies of the +surface and contour plot aligned vertically. The user may specify a +"path" using "pen" motions. The path is plotted as a curve along the +surface and the contour plot plane with vertical lines at the corresponding +indicies. No hidden line removal is used for the path. The path permits +the user to specify a cut plane to enhance the interpretation of the +plot. The path is specified as a sequence of pen motion commands and +index points of the form, +.TP 8 +.lit + + ip(1) = 1st path command + ip(2) = 1st i index + ip(3) = 1st j index + ip(4) = 2n path command + ip(5) = 2nd i index + ip(6) = 2nd j index + ... etc. + +.end lit +Path commands are interpreted according to: +.TP 9 +.lit + + path command action + ______________ ___________________________ + + 0 end of path specification + (indicies ignored) + 3 start path at these indicies + 2 continue path though indicies + +.end lit +The path specificiation should start with a path command of 3 +and end with 0. Note that several paths can be specified by +using several path command 3's. +.P +CVAX3DX contains an internal working storage array for use by GCONTR and +PLT3D. The buffer length is sufficient for most surfaces. However, for +very complex surfaces the buffer length may be exceeded. When this occurs +an error message is written to the terminal and the routine terminates. +.lit + +CALL CVAX3DX(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag, + iax,ds,nc,cv,icl,nm,il,ip, + >>) + +d (R): array of y values dimensioned d(ndx,ndz) +ndx,ndz (I): x and z dimensions of d array +nx,nz (I): x and z sizes of surface to plot d array +a (R): angle of x axis from horizontal 0-85 degrees +b (R): angle of z axis from horizontal 0-90 degrees + note: origin (1,1) is in upper-left corner + x axis runs left-to-right + y axis runs down-to-up + z axis appears to run outof page screen but + is angled to the right +xh,yh,zh (R): length of each axis +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 2 : use color array (need all parameters) + = 1 : do not use color array + (10's digit) = 0 : plot surface as a mesh (PLT3D) + = 1 : plot surface as 2-d historgram (HLT3D) + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axis, using input scale factors dm and dx + = 0 : do not plot axis, axis parameters (xt...dx) not used + scaling derived from d array is used + > 0 : plot axis, using scaling derived from d array, only + axis parameters xt thru ze required. + (1's digit) = 1 : plot actual max/min or input values for Y axis + = 2 : plot smoothed values for Y axis + (10's digit) = 0 : plot contour, surface axes with back panel + = 1 : plot contour, surface axes w/o back panel + = 2 : plot contour axes w/o surface axes, back panel + = 3 : plot surface axes w/o back panel, contour axes + = 4 : plot surface axes, back panel w/o contour axes + (100's digit) = 0 : use default axis type + = 1 : use input AXIS3 parameters +ds (R): vertical spacing between contour plane and minimum + value of a plane +nc (I): number of contours + < 0 : iabs(nc) contours plotted, the (j)th contour + is (max(a)-min(a))/(iabs(nc)-1). values used + are returned in cv + > 0 : contours specified in cv used +cv (R): contour level array dimensioned dv(iabs(nc) +icl (I): contour labeling option + < 0 : label with contour value (number with n digits + to the right of the decimal point) + = 0 : no labels on contours + > 0 : label contours with ASCII characters (nl <= 26) +nm (I): minimum line segments before contour labeled + < 0 : line type array used + > 0 : line type array not used +il (I): array of line types dimensioned il(iabs(nc)+2) + il(1) = underside of surface + il(2) = path line + il(3) = contour line 1 + il(4) = contour line 2 + ... (solid line type on return) +ip (I): path specification array (see notes above) + if ip(1) = 0, remainder of array ignored +(NOTE: following optional axis paramters are used only if + iax<0 or mod(iflag,10)=1) +xt (B): title of x axis (width) +nxt (I): number of characters in xt + = 0 : no axis plotted + > 0 : normal +xs,xe (R): starting and ending values displayed on x axis +xap (R): axis tick pattern (see AXIS3) +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fdx (R): axis number label format (see AXIS3) +yt (B): title of y axis (height) +nyt (I): number of characters in yt + = 0 : no y axis plotted + > 0 : normal +yap (R): axis tick pattern (see AXIS3) +tsy (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fdy (R): axis number label format (see AXIS3) +zt (B): title of z axis (depth) +nzt (I): number of characters in zt + = 0 : no z axis plotted + > 0 : normal +ze,ze (R): starting and ending valued displayed on z axis +zap (R): axis tick pattern (see AXIS3) +tsz (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fdz (R): axis number label format (see AXIS3) +(NOTE: the following are required only if iax<0 or mod(iflag,10)=1) +dm,dx (R): minimum and maximum scale values for d array +ic (I): color list + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for upper surface + ic(6) : color for lower surface + ic(7) : color for contour 1 + ic(8) : color for contour 2 + ... ... + (color for last contour on return) +.end lit + +.pg +.hl1 SUBROUTINE GLPLOT +.p +~GLPLOT plots the curve defined in x,y with ~log and/or ~linear scaling +including appropriate axes and plot title. Various options select the +format of the axes plotting. This subroutine is designed to plot one +or more +y value curves simultaneously. This subroutine permits axis parameter +flexibility (AXIS3) and dimensioning for y array. GLPLOT is a good +general purpose plotting routine. +.lit + +CALL GLPLOT(x,y,nld,npd,nl,np,iflag,isym,xl,yl,xt,xc,xf,xtitle,nxt, + yt,yc,yf,ytitle,nyt,t,nt,,l>>) + +x (R): array of x values dimensioned at least x(np) +y (R): array of y values dimensioned y(npd,nld) +nld (I): dimension of y (number of lines dimensioned) +npd (I): dimension of y (number of points dimensioned) +nl (I): number of data lines to plot from y array +np (I): number of points per line +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) >10000: do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : plot ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +isym (I): plot a symbol every isym'th point + < 0 : symbols only plotted, no line + = 0 : no symbols, line only + > 0 : symbol plotted every isym'th point +xl (R): x axis length in inches + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (R): x axis tick mark pattern (see AXIS3) +xc (R): x axis character size + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +xf (R): x axis number label format (see AXIS3) +xtitle(B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (R): y axis tick mark pattern (see AXIS3) +yc (R): x axis character size + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +yf (R): y axis number label format (see AXIS3) +ytitle(B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color list + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponent + ic(6) : color for title (return) + ic(7) : color for plotted line 1 + ic(8) : color for plotted line 2 + ic(9) : etc. +l (I): line type of data lines list (required only if |nt|/100>0) + +common /cglplot/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE HIST3D +.p +.x surface plot +~HIST3D plots a 2-d histogram as square columns plotted as z values +from the x,y plane with hidden line removal. +The input consists of the values of the z axis for +each (x,y) point on the plane. Each square grid is plotted as two triangles +using either ~SKETCH or ~PLT3DH permitting hidden line removal if desired. +HIST3D calls ~INIT3DH to initialize the 3-d hidden line package. Default +space is provided in the INIT3DH common block. The ISIZE variable will +be reset to the internal size if its value is smaller than the internal +size. Sufficient space in the internal common block +is provided for reasonably complex surfaces. +.lit + +CALL HIST3D(z,ndx,ndy,nx,ny,s,p,t,dv,zref,xl,yl,zl,iflag,ia, + xt,nxt,tx,sx,gx,fx, + yt,nyt,ty,sy,gy,fy, + zt,nzt,tz,sz,gz,fz, + xm,xx,ym,yx,zm,zx<,ic>) + +z (R): array of z values +ndx,ndy(I): dimensions of z array +nx,ny (I): number of points in each dimension to use of z array +s,p,t (R): yaw,roll,pitch angles of axes (see INIT3DH) +dv (R): perspective scale factor for INIT3DH + < 0 : no hidden lines in SKETCH, INIT3DH called + = 0 : INIT3DH not called to initialize 3d package, + (INIT3DH previously called) + > 0 : hidden lines in SKETCH, INIT3DH called + = 9999 : no perspective in INIT3DH +zref (R): reference value from which columns are drawn from +xl (R): x axis length in inches +yl (R): y axis length in inches +zl (R): z axis length in inches +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : do not use color array + = 2 : use color array + (10's digit) = 0 : hidden line removal for surface only + = 1 : hidden line removal for axis and surface + = 2 : no hidden line removal (SKETCH not used) + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +ia (I): axis option flag + < 0 : plot axis use input z axis scale + = 0 : do not plot axes + > 0 : plot axis use computed z axis scale + (1's digit) = 1 : plot y axis using input scale + = 2 : plot y axis using input, smoothed scale + (10's digit) = 1 : plot x axis using input scale + = 2 : plot x axis using input, smoothed scale +xt (B): x axis title string +nxt (I): number of characters in x axis title + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +tx (R): number and pattern of axis ticks (see AXIS3) +sx (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gx (R): rotation angle for x axis (see AXIS3DH) +fx (R): format of axis number labeling (see AXIS3) +yt (B): y axis title string +nyt (I): number of characters in y axis title + < 0 : axis ticks on top of axis + = 0 : no axis + > 0 : axis ticks on bottom of axis (normal) +ty (R): number and pattern of axis ticks (see AXIS3) +sy (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gy (R): rotation angle for y axis (see AXIS3DH) +fy (R): format of axis number labeling (see AXIS3) +zt (B): z axis title string +nzt (I): number of characters in z axis title + < 0 : axis ticks on top of axis + = 0 : no axis + > 0 : axis ticks on bottom of axis (normal) +tz (R): number and pattern of axis ticks (see AXIS3) +sz (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gz (R): rotation angle for z axis (see AXIS3DH) +fz (R): format of axis number labeling (see AXIS3) +xm,xx (R): minimum, maximum value displayed on x axis +ym,yx (R): minimum, maximum value displayed on y axis +zm,zx (R): minimum, maximum value of z axis (required if ia < 0) +ic (I): color list (required if 1's digit of iflag=2) + ic(1) : color for axes + ic(2) : color for surface +.end lit + +.pg +.hl1 SUBROUTINE LCNTR +.p +.x contour plot +~LCNTR plots a contour plot of a uniformly sampled 2-d input array. +LCNTR is similar to CNTRPLT but permits hardware line types. +The input consists of a 2 dimensional grid of v values. A +contour is determined by linearily interpolating the edges of the square +formed by 4 adjacent points (see CNTRPLT). LCNTR connects the line segments +of constant contour before plotting and can optionally label the contour lines +with alphabetic codes or the numerical value of the contour. +Log axes are available but data points are plotted using +linear positioning. (Note: common block scale factors will be log values +if the log axes are selected.) +.p +When the contour levels are input (nl>0), contours can be suppressed +in a region by setting the value of the input array greater than 1.E20. +LCNTR uses the contouring routine GCONTR. +.x GCONTR +.lit + +CALL LCNTR(v,ndx,ndy,nx,ny,nl,cl,n,m,iflag,iw,xl,yl,xt,nxt,yt,nyt, + t,nt,xm,xx,ym,yx<<,ic>,l>) + +v (R): 2-d array of values dimensioned v(ndx,ndy) +ndx,ndy (I): dimensions of data array +nx,ny (I): number of points in each array dimension +nl (I): number of uniformly spaced contour levels, + < 0 : max and min of v are used to define contours. + the (j)th contour is computed from max,min of + input array according to, + (j-1)*(max(v)-min(v))/(nl-1)+min(v) + > 0 : number of contour levels specified in cl +cl (R): array of contour levels dimensioned cl(nl) + if nl < 0 contour levels used are (returned) in cl +n (I): contour labeling option + < 0 label with contour value (number with n digits + to the right of the decimal point) + = 0 no labels on contours + > 0 label contours with ASCII characters (nl <= 26) +m (I): minimum line segments before contour labeled (m > 1) +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) >10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : plot ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iw (I): working array dimensioned at least (2*nx*ny+1)/31 +xl (R): x axis length in inches (integer valued) + > 0 : use input scaling in xm,xx for axis + < 0 : use smoothed input scaling in xm,xx for axis +yl (R): y axis length in inches (integer valued) + > 0 : use input scaling in ym,yx for axis + < 0 : use smoothed input scaling in ym,yx for axis +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string +nt (I): number of characters in t (limited to 99 characters) + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): input minimum value of x axis +xx (R): input maximum value of x axis +ym (R): input minimum value of y axis +yx (R): input maximum value of y axis +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color array + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponent + ic(6) : color for title (return) + ic(7) : color for contour line 1 + ic(8) : color for contour line 2 + ic(9) : etc. +l (I): line type list for contours (required if |nt|/100>0) + +common /ccntrplt/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl 1 SUBROUTINE LSPLOT +.p +~LSPLOT is a general single/multiple data line routine for plotting +lines or scatterplots. Optionally, error bars and symbols can be +added. LSPLOT differs in philosophy from most other LONGLIB MASTER +routines in that plotting options are passed via an option array routine. +The routine is designed to produce a reasonable plot with the option +array set to all zeros. The output format is changed by initializing +selected array elements to the values described below. +This permits simple but flexible specification of the plot format. +.lit + +CALL LSPLOT(x,y,ndp,ndl,iflag,f,c,nc) + +x (R): x input array dimensioned x(ndp,ndl). Depending + on option selected, x need only be dimensioned + x(ndp) -- this is the default option. +y (R): y input array dimensioned y(ndp,ndl). If + ndl=1 then y may dimensioned y(ndp) +ndp (I): number of data points/line dimension +ndl (I): number of data lines dimension +iflag (I): LONGLIB option flag (one's digit arbitrary) + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) >10000 : do not initialize LONGLIB before plotting + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +f (R): option array dimensioned at least f(53) + (described below) +c (C): array of strings dimensioned C(3+ndl) + c(1) : x axis title + c(2) : y axis title + c(3) : top title + c(4) : line 1 legend (optionally used) + c(5) : line 2 legend (optionally used) + ... ... +nc (I): array of string lengths dimensioned nc(3+ndl) + nc(1) : number of characters to use in C(1) + nc(2) : number of characters to use in C(2) + ... ... +.end lit +.p +The array elements of the option array f are interpretted according +to the following table. Some parameters have default values (shown +in square brackets). These are used when the input value is zero. +A simple plot may be produced by setting all the elements of f to +zero. Note that user specified input scaling factors should be +powers of ten when the log axis specification is selected. An optional +legend may be plotted. The legend consists of a column +of line/simple examples (if selected) and input text. +.tp 8 +.lit + + array range of + index values action for each value + ------- -------- ------------------------ + + 1 0<=.<=ndp number of points/line to plot [ndp]: 0=ndp used + 2 0<=.<=ndl number of lines to plot [nl]: 0=ndl used + 3 -1/0/1 x scale: 0=auto,smoothed; 1=auto,nosmooth; -1=user + 4 xmin user supplied scale value (used if f(3)<0) + 5 xmax user supplied scale value (used if f(3)<0) + 6 -1/0/1 y scale: 0=auto,smoothed; 1=auto,nosmooth; -1=user + 7 ymin user supplied scale value (used if f(6)<0) + 8 ymax user supplied scale value (used if f(6)<0) + 9 0/1 x value usage: 0=first line of x data array + used for all y lines; 1=lines of x,y paired + 10 0/1 connect plotted points: 0=yes; 1=no + 11 >=0 symbol plotted every ()th point: 0=no symbols + 12 >=0 line symbol size [0.1]: 0=use default + 13 >=0 symbol number for first data line, each line + then uses next symbol in sequence + 14 8<.<8 error bar option (see below): 0=no error bars + 16 >=0 error bar size [0.1]: 0=default used + 17 0/1 vertical line from points to reference value: + 0=no; 1=yes + 18 rval reference value + 19 -1/0/1 x axis type: 0=linear; 1=log axis, -1=no axis + 20 -1/0/1 y axis type: 0=linear; 1=log axis, -1=no axis + 21 >=0 x axis length [7.0]: 0=default used + 22 >=0 y axis length [5.0]: 0=default used + 23 >=0 x axis tick pattern (see axis3) [7.00]: 0=default + 24 >=0 y axis tick pattern (see axis3) [5.00]: 0=default + 25 0/1 x axis title side of axis: 0=below; 1=above + 26 0/1 y axis title side of axis: 0=left; 1=right + 27 0/1 x axis auto exponent enable: 0=enable; 1=disable + 28 0/1 y axis auto exponent enable: 0=enable; 1=disable + 29 0/1 x axis tick side: 0=below; 1=above + 30 0/1 y axis tick side: 0=left; 1=right + 31 0/1 x axis number orientation: 0=horizontal; 1=vertical + 32 0/1 y axis number orientation: 0=vertical; 1=horizontal + 33 0/1 x axis numbers/title: 0=shown; 1=not shown + 34 0/1 y axis numbers/title: 0=shown; 1=not shown + 35 0/1 use x=log10(abs(x values)+1.e-34): 0=no; 1=yes + 36 0/1 use y=log10(abs(y values)+1.e-34): 0=no; 1=yes + 37 -1/0/1 add mirror x axis: 0=no; 1=w/labels; -1:w/o labels + 38 -1/0/1 add mirror y axis: 0=no; 1=w/labels; -1:w/o labels + (mirrored axes placed on opposite from normal axis) + 39 >=0 x axis label size [0.15]: 0=use default + 40 >=0 y axis label size [0.15]: 0=use default + 41 >=0 top title character size [0.18]: 0=use default + 42 0/1/2/3 grid: 0=no grid; 1=solid; 2=dotted; 3=ticked + 43 -1/0/1 legend: 0=no legend; 1=right side; -1=user locate + 44 xval user specified lower-left corner of legend + 45 yval user specified lower-left corner of legend + 46 0/1 show plot symbol on legend: 0=no; 1=yes + 47 0/1 show line segment on legend: 0=no; 1=yes + 48 >=0 legend character height [0.12]: 0=use default + 49 >=0 legend line segment length [0.5]: 0=use default + 50 -1/0/1 top title justify: 0=center; -1:left; 1:right + 51 0/1 plot horizontal reference line: 0=no; 1=yes + 52 0/1 use linetype array values: 0=no; 1=yes + 53 0/1 use color array values: 0=no; 1=yes + 54 >=0 color index #1: 0=color value 1 used + 55 >=0 linetype index #1 + 56 >=0 color index #2: 0=color value 1 used + 57 >=0 linetype index #2 + ... ... ... etc ... +.end lit +.p +The optional error bar specification, when non-zero, changes +interpretation of lines. The first line (and every third line) +conidered a "center" line. The second line specifies the relative +error (to be added to the first line) used for plotting the tops +of the error bars. The third line is used similarily to locate +the bottoms of the error bars. When the error bar specification +is negative the center line points are marked with a special "x" +(in addition to any other option). The absolution value of the +specifiation determines the type of error bar according to the +following table. +.tp10 +.lit + +value type of error bar +------ --------------------------------------------------- + 1 line connecting relative errors + 2 1 + horizontal bars at relative errs + 3 1 + vertical bars at relative errs + 4 double line connecting rel. errs+horizontal bars + 5 double line connecting rel. errs+vertical bars + 6 vertical rectangle w/top and bottom rel. errs + 7 rectangle with corners at relative errors +.end lit +.p +The color and line type index (when enabled) are used according to the +following table. +.tp12 +.lit + + index # color usage linetype usage +--------- ------------- ---------------- + 1 x axis x axis + 2 x axis numbers y axis + 3 x axis title title + 4 x axis exponent legend titles + 5 y axis reference line + 6 y axis numbers error bars + 7 y axis title line #1 linetype + 8 y axis exponent line #2 linetype + 9 title etc. + 10 legend titles ... + 11 reference line ... + 12 grid ... + 13 line #1 color ... + 14 line #2 color ... +... ... etc. ... ... +.end lit + +.pg +.hl 1 SUBROUTINE MESH3D +.p +MESH3D plots a 2-d surface as 3d mesh using the same techniques +as ~VAX3D but without hidden line removal. +~MESH3D calls MESH3DX using default axis parameters to simplify +the calling procedure. +.lit + +CALL MESH3D(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag,iax,>>) + +See MESH3DX for parameter description. + (iax is limited to a single digit value) +.end lit +.hl 1 SUBROUTINE MESH3DX +.p +.x VAX3DX +.x 2-d surface plot +~MESH3DX is a simple 3-d surface plotting routine. A 3-d surface is +plotted as a simple mesh grid. The plotting method is similar to +VAX3DX. No hidden line removal is done. +The height of plotted surface relative to its y axis value +is calibrated to z axis. No perspective is used. +Options exist to varying the plotting angle and to plot axes. +.p +Origin of the plot is in the lower-left corner. The x axis runs +plotted left to right along the plot bottom. The y axis is plotted +as a vertical displacement offset by the z axis value. The z axis +appears to point into the screen. This gives the illusion of depth. +.lit + +CALL MESH3DX(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag,iax, + >>) + +d (R): array of y values dimensioned d(ndx,ndz) +ndx,ndz (I): x and z dimensions of d array +nx,nz (I): x and z sizes of surface to plot d array +a (R): angle of x axis from horizontal 0-85 degrees +b (R): angle of z axis from horizontal 0-90 degrees + note: origin (1,1) is in lower-left corner + x axis runs left to right on screen + y axis runs up to down on screen + z axis appears to run into the screen but + is angled to the right +xh,yh,zh (R): length of each axis +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) >10000: do not initialize LONGLIB before plotting + (1's digit) = 2 : use color array (need all parameters) + = 1 : do not use color array + (10's digit) = 0 : Plot sides + = 1 : Do not plot sides + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axes, using input scale factors dm and dx + = 0 : axes not plotted, parameters (yt...dx) not used. + scaling derived from d array is used + > 0 : plot axes, use max and min of d array to compute + dm and dx, need axis parameters yt thru ze + (1's digit) = 1 : Plot actual max/min or input values for Y axis + = 2 : Plot smoothed values for Y axis + (10's digit) = 0 : Use default axis type + = 1 : Use input AXIS2-type axis parameters +(NOTE: the following optional paramters are used only if + iax < 0 or mod(iflag,10)=1) +xt (B): title of x axis (width) +nxt (I): number of characters in xt + = 0 : no axis plotted + > 0 : axis plotted +xs,xe (R): starting and ending values displayed on x axis +(see AXIS2 for detailed description of axis parameters) +nmx (I): number of minor ticks between major ticks on x axis +nnx (I): highlight length of nnx-th minor tick on x axis +mlx (I): number of major tick marks on x axis +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndx (I): number of digits to right of decimal point on x axis +smx (R): major tick length on x axis +yt (B): title of y axis (depth) +nyt (I): number of characters in yt + = 0 : no y axis plotted + > 0 : normal +nmy (I): number of minor ticks between major ticks on y axis +nny (I): highlight length of nny-th minor tick on y axis +mly (I): number of major tick marks on y axis +tsy (R): size of title and numbers on y axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndy (I): number of digits to right of decimal point on y axis +smy (R): major tick length on y axis +zt (B): title of z axis (height) +nzt (I): number of characters in zt + = 0 : no z axis plotted + > 0 : normal +ze,ze (R): starting and ending valued displayed on z axis +nmz (I): number of minor ticks between major ticks on z axis +nnz (I): highlight length of nnz-th minor tick on z axis +mlz (I): number of major tick marks on z axis +tsz (R): size of title and numbers on z axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndz (I): number of digits to right of decimal point on z axis +smz (R): major tick length on z axis +(NOTE: the following optional parameters are required if + iax < 0 or mod(iflag,10)=1) +dm,dx (R): minimum and maximum scale values for d array +ic (I): color list + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for plot surface (return) +.end lit + +.pg +.hl 1 SUBROUTINE MVAX3D +.p +MVAX3D plots a 3d mesh surface or 2-d histogram with hidden line removal. +See MVAX3DX. The calling format is similar to VAX3D. +~MVAX3D calls ~MVAX3DX using default axis parameters to simplify calling +procedure. +.lit + +CALL MVAX3D(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag,iax,>>) +.end lit + +.hl 1 SUBROUTINE MVAX3DX +.p +.x 2-d surface plot +~MVAX3DX is a 3-d surface plotting routine which plots a +3-d surface as mesh with hidden lines removed using the ~PLT3D routine +or a 2-d histogram with hidden lines removed using the ~HLT3D routin. +Axes and a axis back panel can be optionally plotted as well. +The upper side of the visible surface can be shown with optional side +plates on the mesh surface. +If the side plates are not used or for histogram plotting, the lower side of the +visible surface may be displayed in different colors or using a dotted line. +.p +Origin of the plot is in the upper-left corner. The x axis runs +left to right along the plot bottom. The y axis is plotted +as a vertical displacement offset by the z axis value. The z axis appears +to point out of the screen. +.P +MVAX3DX contains an internal working storage array for use by +PLT3D and HLT3D. The buffer length is sufficient for most surfaces. +However, for +very complex surfaces the buffer length may be exceeded. When this occurs +an error message is written to the terminal and the routine terminates. +.lit + +CALL MVAX3DX(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag,iax, + >>) + +d (R): array of y values dimensioned d(ndx,ndz) +ndx,ndz (I): x and z dimensions of d array +nx,nz (I): x and z sizes of surface to plot d array +a (R): angle of x axis from horizontal 0-85 degrees +b (R): angle of z axis from horizontal 0-90 degrees + note: origin (1,1) is in upper-left corner + x axis runs left-to-right + y axis runs down-to-up + z axis appears to run outof page screen but + is angled to the right +xh,yh,zh (R): length of each axis +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 2 : use color array (need all parameters) + = 1 : do not use color array + (10's digit) = 0 : mesh surface w/side panels, lower side of + surface not shown + = 1 : mesh surface w/no side panels, lower side of + surface shown using dotted lines + = 2 : mesh surface w/no side panels, lower side of + surface shown using solid lines + = 3 : mesh surface w/no side panels, lower side of + surface not shown + = 4 : histogram surface, lower side of surface + shown using dotted lines + = 5 : histogram surface, lower side of surface + shown using solid lines + = 6 : histogram surface, lower side of surface + shown using solid lines + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axes, using input scale factors dm and dx + = 0 : no axes plotted, parameters (xt...dx) not used. + scaling derived from d array is used + > 0 : plot axes, use scaling derived from d array, only + axis parameters xt thru ze required. + (1's digit) = 1 : Plot actual max/min or input values for Y axis + = 2 : Plot smoothed values for Y axis + (10's digit) = 0 : Use default axis type + = 1 : Use input AXIS3 parameters + (100's digit) = 0 : Do not plot backplane + = 1 : Plot backplane +(NOTE: following optional axis paramters are used only if + iax<0 or mod(iflag,10)=1) +xt (B): title of x axis (width) +nxt (I): number of characters in xt + = 0 : no axis plotted + > 0 : normal +xs,xe (R): starting and ending values displayed on x axis +xap (R): axis tick pattern (see AXIS3) +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fdx (R): axis number label format (see AXIS3) +yt (B): title of y axis (height) +nyt (I): number of characters in yt + = 0 : no y axis plotted + > 0 : normal +yap (R): axis tick pattern (see AXIS3) +tsy (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fdy (R): axis number label format (see AXIS3) +zt (B): title of z axis (depth) +nzt (I): number of characters in zt + = 0 : no z axis plotted + > 0 : normal +ze,ze (R): starting and ending valued displayed on z axis +zap (R): axis tick pattern (see AXIS3) +tsz (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +fdz (R): axis number label format (see AXIS3) +(NOTE: the following optional parameters are required if + iax<0 or mod(iflag,10)=1) +dm,dx (R): minimum and maximum scale values for d array +ic (I): color list + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for plot surface (return) +.end lit + +.pg +.hl 1 SUBROUTINE MVAX5D +.p +.x 5-d surface +.x 4-d surface plot +.x MVAX3D +~MVAX5D plots a 4 or 5-d surface by plotting slices through the 3rd and +4th dimensions in a 2-d array of of 3-d plots. Each 3-d surface +plots d(*) as a function of 2 of the dimensions using MVAX3D. +.p +Origin of the plot is in the lower-left corner. The X axis runs +left to right along the subplot bottom. The Y axis is plotted out +the page of the subplot (see MVAX3D). +The Z axis runs left to right in subplots +with the W axis vertical subplots. +.tp 8 +.lit + + ^ W d + | | + | |__X + | / + | Y + ----------> Z +.end lit +.p +Since the subplots may runoff the edge of the plotting page, the routine +includes a page size option to issue a NEWPAGE and plot the additional +subplots on separate pages. A shrinking factor is included to shrink the +subplots. +Labeling of the W and Z axis is due in the lower right hand corner. +Each subplot is further tagged with the corresponding W and Z axis +value. A multiple page plot can be pasted together to form a large +representation of a 5-d (or 4-d) surface. +.lit + +CALL MVAX5D(d,nd,n,a,b,iflag,iax,iform,w,xh,yh,zh,ph,pl,fac,iw,iz, + st,en,t1,nt1,t2,nt2,t3,nt3,t4,nt4,dt,ndt,>) + +d (R): array to plot dimensioned d(nd(1),nd(2),nd(3),nd(4)) +nd (I): array of containing dimensions of d array +n (I): array of number of points in each dimension to plot +a,b (R): angles a,b for MVAX3D subplot +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 2 : use color array (need all parameters) + = 1 : do not use color array + (10's digit) = 0 : mesh surface w/side panels, lower side of + surface not shown + = 1 : mesh surface w/no side panels, lower side of + surface shown using dotted lines + = 2 : mesh surface w/no side panels, lower side of + surface shown using solid lines + = 3 : mesh surface w/no side panels, lower side of + surface not shown + = 4 : histogram surface, lower side of surface + shown using dotted lines + = 5 : histogram surface, lower side of surface + shown using solid lines + = 6 : histogram surface, lower side of surface + shown using solid lines + (100's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axes, use input scale factors dm and dx + = 0 : no axes plotted, parameters (xt...dx) not used. + scaling derived from d array + > 0 : plot axes, scaling derived from d array, only + axis parameters xt thru ze required. + (1's digit) = 1 : Plot actual max/min or input values for Y axis + = 2 : Plot smoothed values for Y axis + (10's digit) = 0 : Axes plotted for all subplots + = 1 : Axes plotted only for first subplot +iform (I): plot format code + selects which dimension of d array is to become + which output axis + + plot axis plot axis +Code X Y Z W Code X Y Z W +_____ ____________ _____ ____________ + 1 input: 1 2 3 4 13 3 1 2 4 + 2 dimen- 1 2 4 3 14 3 1 4 2 + 3 sion 1 4 2 3 15 3 2 1 4 + 4 number 1 4 3 2 16 3 2 4 1 + 5 1 3 2 4 17 3 4 1 2 + 6 1 3 4 2 18 3 4 2 1 + 7 2 1 3 4 19 4 1 2 3 + 8 2 1 4 3 20 4 1 3 2 + 9 2 4 3 1 21 4 2 1 3 + 10 2 4 1 3 22 4 2 3 1 + 11 2 3 4 1 23 4 3 1 2 + 12 2 3 1 4 24 4 3 2 1 + +w (R): working array dimensioned at least n(x)*n(y) +xh,yh,zh (R): length of each axis of MVAX3D subplot +ph,pl (R): page height, length when multiple pages required +fac (R): shrink factor for subplots (2 == FACTOR(1/2)) +iw,iz (I): plot every iw'th and iz'th subplots +(NOTE: the axis titles, number of characters, start/stop + values are permuted along with d array dimensions) +st,en (R): arrays containing axes start and end values +t1 (B): title corresponding to 1st dimension of d +nt1 (I): number of characters in title t1 + = 0 : no axis plotted + > 0 : axis plotted +t2 (B): title corresponding to 2st dimension of d +nt2 (I): number of characters in title t2 + = 0 : no axis plotted + > 0 : axis plotted +t3 (B): title corresponding to 3rd dimension of d +nt3 (I): number of characters in title t3 + = 0 : no axis plotted + > 0 : axis plotted +t4 (B): title corresponding to 4th dimension of d +nt4 (I): number of characters in title t4 + = 0 : no axis plotted + > 0 : axis plotted +t5 (B): title corresponding to 5th dimension of d +nt5 (I): number of characters in title t5 + = 0 : no axis plotted + > 0 : axis plotted +(NOTE: the following optional parameters are required if + iax<0 or mod(iflag,10)=1) +dm,dx (R): minimum and maximum scale values of plot +ic (I): color array + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for plot surface (return) +.end lit + +.pg +.hl1 SUBROUTINE PHIST +.p +~PHIST is a generalized ~histogram plotting program with various +plot format controls. Shading may done under the histogram columns. +The histogram height may be plotted on top of each histogram column +vertically. The mean and +/- sigma variations may be indicated on the +plot output. Note: PHIST does not do the histogramming. This is left +to the user. +.lit + +CALL PHIST(a,n,t,nt,xl,yl,s,ns,xt,nxt,xm,xx,ax, + iflag,ishad,am,as<,ic>) + +a (R): array of heights of histogram columns +n (I): number of points in a array to plot +t (B): title string +nt (I): number of characters in t + = 0 : no title + < 0 : use color array +xl (R): length of x axis in inches (integer-valued real number) +yl (R): length of y axis in inches (integer-valued real number) +s (B): subtitle string +ns (I): number of characters in s +xt (B): x axis title +nxt (I): number of characters in xt +xm (R): minimum value displayed on x axis +xx (R): maximum value displayed on x axis +ax (R): maximum value of a +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting +(1's digit) = 2 : plot number value of column on top of column + = 1 : no numeric values on top of histogram columns + = 0 : no axis or title (histogram columns only) +(10's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +ishad (I): shade option flag + < 0 : shade with solid line + = 0 : no shading + > 0 : shade with line of type ishad +am (R): mean value of histogram to plot (in relation to xm,xx) +as (R): standard deviation of histogram to plot + < 0 : neither mean nor sigma values indicated on plot + = 0 : only mean value indicated on plot + > 0 : mean and +/- sigma values indicated on plot +ic (I): color list + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for mean label + ic(6) : color for sigma label + ic(7) : color for title + ic(8) : color for subtitle + ic(9) : color for histogram columns (return) + +common /cphist/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE PICHRT +.p +~PICHRT plots a circular pie chart with optionally shaded wedges, and +descriptive legends. One or more of the slices may be "exploded" outward +from the pie chart center for emphasis. The chart legend can be character +labels only or can include shade legends. Labels can be automatically placed +around the pie chart or located at the bottom of the page. Optionally, the +user can specify the locations of the legends. +.lit + +CALL PICHRT(x,y,r,d,iflag,as,ae,n,a,sh,iw,l,nl,cs,sl, + t,nt,tcs,d,>) + +x,y (R): location of pie chart center +r (R): radius of pie chart segments (r>0) +d (R): distance from chart center for "exploded" segments +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : color array not used + = 2 : color array used + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +as (R): starting angle of first segment +n (I): number of segments (n>0) +a (R): array of segment sizes (angular width of jth segment + is a(j)*360/(Sum a(i),i=1,N)) +sh (R): shade option for each pie segment + sh shade pattern + ____ _________________________ + 0 no shading + 1 -45 deg solid lines + 2 horizontal solid lines + 3 +45 deg solid lines + 4 vertical deg solid lines + 5 -45 deg dotted lines + 6 horizontal dotted lines + 7 +45 deg dotted lines + 8 vertical deg dotted lines + 9 +/- 45 deg dotted lines + 10 vertical/horizontal dotted lines + 11 +/- 45 deg solid lines + 12 vertical/horizontal solid lines +iw (I): array of segment outline linewidths (1-9) +l (C): array of segment labels for legend (CHARACTER) +nc (I): maximum number of characters in legend string +cs (R): legend character height +sl (R): legend shaded box size + < 98: legend located below chart w/o box + < 0 : legend located below chart with shaded box + = 0 : no legend + > 0 : legend located around chart with shaded box + > 98: legend located around chart w/o box +t (B): chart title string +nt (I): number of characters in t + < 1 : no title plotted +tcs (R): chart title string height +d (R): distance between shading lines +p (R): array containing locations of lower-left corner + of legend box/string (used only if tc < 0) +ic (I): color array (used only if mod(|iflag|,10)=2) + ic(1) : title color (return) + ic(2) : legend string color + ic(3) : segment 1 color + ic(4) : segment 2 color + ... ... +.end lit + +.pg +.hl1 SUBROUTINE PLOTLG +.p +~PLOTLG is a very simple routine which +plots a single curve defined in x,y with ~log and/or ~linear +scaling including appropriate axes and plot title. Various options +select the format of plotting and type of grid. +.lit + +CALL PLOTLG(x,y,n,iflag,xl,yl,xt,nxt,yt,nyt,t,nt, + ,l>>) + +x (R): array of x values +y (R): array of y values +n (I): number of points in x array +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : ticked cartesian grid, box w/axis ticks + = 6 : plot without box or grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +xl (R): x axis length in inches (integer-valued) + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches (integer-valued) + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: optional color array required if nt<0 or |nt|/100>0) +ic (I): color array + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for plotted line + ic(7) : color for title (return) +(NOTE: optional line type array only required if |nt|/100>0) +l (I): line type of data line + if |nt|/100 > 0 : use line type list + +common /cplotlg/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE PLOTLG2 +.p +~PLOTLG2 is a simple routine to +plot multiple curves defined in x,y in ~log and/or ~linear +scaling including appropriate axes and plot title. Various options +select the format of plotting. This subroutine is designed to plot +many y value curves which may be distinguished by color and/or line +type. This routine is similar to ~PLOTLGX but uses a simpler +axis specification. +.lit + +CALL PLOTLG2(x,y,nl,np,iflag,isym,xl,yl,xt,nxt,yt,nyt,t,nt,,l>>) + +x (R): array of x values +y (R): array of y values dimensioned y(np,nl) +nl (I): number of data lines to plot from y array +np (I): number of points in x array +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +isym (I): plot a symbol every isym'th point + < 0 : symbols only plotted, no line + = 0 : no symbols, line only + > 0 : symbol plotted every isym'th point +xl (R): x axis length in inches (integer-valued) + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches (integer-valued) + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color list + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for title (return) + ic(7) : color for plotted line 1 + ic(8) : color for plotted line 2 + ic(9) : etc. +(NOTE: line type list required only if |nt|/100>0) +l (I): line type for data lines list + +common /cplotlg2/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit +.pg +.hl1 SUBROUTINE PLOTLGL +.x PLOTLGX +.x linseq +.p +~PLOTLGL plots multiple curves defined in x,y with ~log and/or ~linear +scaling including appropriate axes and plot title using software line +types (LINSEQ). It is similar in character to PLOTLGX. Various options +may be used select the format of plotting. This routine may be used +to plot many y value curves simultaneously with the curves distinguished +by symbols, color, and/or line type. This subroutine permits axis +parameter flexibility and dimensioning for the y array values. +.p +NOTE: the values in the x and y arrays are modified. Upon return they +contain their original contents scaled by xm,dx,ym,dy (see LINE). +.lit + +CALL PLOTLGL(x,y,w,nld,npd,nl,np,iflag,isym,xl,yl,ns,s,l, + nmx,nnx,mlx,tsx,ndx,smx, + nmy,nny,mly,tsy,ndy,smy, + xt,nxt,yt,nyt,t,nt,>) + +x (R): array of x values dimensioned at least x(np) +y (R): array of y values dimensioned y(npd,nld) +w (R): working array dimensioned at least d(3*np+3) +nld (I): dimension of y array (lines) +npd (I): dimension of y array (points) +nl (I): number of data lines to plot from y array +np (I): number of points per data line +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +isym (I): plot a symbol every isym'th point + < 0 : symbols only plotted, no line + = 0 : no symbols, line only + > 0 : symbol plotted every isym'th point +xl (R): x axis length in inches + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +ns (I): smoothing passes (normally zero--see LINSEQ) +s (R): nominal interval length (see LINSEQ) +l (I): linetype array dimensioned l(5*np) (see LINSEQ) + l(1): l1 for line 1 + l(2): l2 for line 1 + ... + l(5): l5 for line 1 + l(6): l1 for line 2 + l(7): l2 for line 2 + ... +(see AXIS2 for detailed description of axis parameters) +nmx (I): number of minor ticks between major ticks on x axis +nnx (I): highlight length of nnx-th minor tick on x axis +mlx (I): number of major tick marks on x axis +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndx (I): number of digits to right of decimal point on x axis +smx (R): major tick length on x axis +nmy (I): number of minor ticks between major ticks on y axis +nny (I): highlight length of nny-th minor tick on y axis +mly (I): number of major tick marks on y axis +tsy (R): size of title and numbers on y axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndy (I): number of digits to right of decimal point on y axis +smy (R): major tick length on y axis +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: color array required if nt < 0) +ic (I): color array + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for title (return) + ic(7) : color for plotted line 1 + ic(8) : color for plotted line 2 + ic(9) : etc. + +common /cplotlgl/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE PLOTLGX +.p +~PLOTLGX is a routine for +ploting multiple curves defined in x,y with ~log and/or ~linear +scaling including appropriate axes and plot title. Various options +may be used select the format of plotting. This routine may be used +to plot many y value curves simultaneously with the curves distinguished +by symbols, color, and/or line type. This subroutine permits axis +parameter flexibility and dimensioning for the y array values. +.lit + +CALL PLOTLGX(x,y,nld,npd,nl,np,iflag,isym,xl,yl, + nmx,nnx,mlx,tsx,ndx,smx, + nmy,nny,mly,tsy,ndy,smy, + xt,nxt,yt,nyt,t,nt,,l>>) + +x (R): array of x values dimensioned at least x(np) +y (R): array of y values dimensioned y(npd,nld) +nld (I): dimension of y array (lines) +npd (I): dimension of y array (points) +nl (I): number of data lines to plot from y array +np (I): number of points per line +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : plot ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +isym (I): plot a symbol every isym'th point + < 0 : symbols only plotted, no line + = 0 : no symbols, line only + > 0 : symbol plotted every isym'th point +xl (R): x axis length in inches + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +(see AXIS2 for detailed description of axis parameters) +nmx (I): number of minor ticks between major ticks on x axis +nnx (I): highlight length of nnx-th minor tick on x axis +mlx (I): number of major tick marks on x axis +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndx (I): number of digits to right of decimal point on x axis +smx (R): major tick length on x axis +nmy (I): number of minor ticks between major ticks on y axis +nny (I): highlight length of nny-th minor tick on y axis +mly (I): number of major tick marks on y axis +tsy (R): size of title and numbers on y axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndy (I): number of digits to right of decimal point on y axis +smy (R): major tick length on y axis +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color list + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for title (return) + ic(7) : color for plotted line 1 + ic(8) : color for plotted line 2 + ic(9) : etc. +l (I): data line type list (required only if |nt|/100 > 0) + +common /cplotlgx/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + + +.pg +.hl1 SUBROUTINE PLOTSC +.p +~PLOTSC is a very basic routine which plots the curve defined +in x,y with axes and a plot title. Various options select the format +of the plot. +.lit + +CALL PLOTSC(x,y,n,iflag,xl,yl,xt,nxt,yt,nyt,t,nt, + ,l>>) + +x (R): array of x values +y (R): array of y values +n (I): number of points in x array +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting +(magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 0 : no axis or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked grid without box + = 4 : plot ticked grid with box + = 5 : ticked grid and box with axis tick marks + = 6 : plot without box or grid + (10's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +xl (R): x axis length in inches (integer valued) + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches (integer valued) + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color array + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for plotted line + ic(7) : color for title (return) +l (I): data line type (required if nt < 0 or |nt|/100 > 0) + +common /cplotsc/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl 1 SUBROUTINE PLOTSC2 +.x LINE +.x DASHL +.p +~PLOTSC2 plots two curves defined by the x,y and x,y2 arrays with +axes and a plot title. An auto-scaling option scales the axes to +place both curves within the axes. Curves are distinguished by line +type. The y curve uses a solid line (LINE) while the y2 curve uses a dashed +line (DASHL). Various options select the format of plotting. +.lit + +CALL PLOTSC2(x,y,y2,n,iflag,xl,yl,xt,nxt,yt,nyt,t,nt, + ,l>>) + +x (R): array of x values +y (R): array of y values (plotted solid) +y2 (R): second array of y values (plotted dashed) +n (I): number of points in x array +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) >10000 : do not initialize LONGLIB before plotting + (1's digit) = 0 : no axis or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked grid without box + = 4 : plot ticked grid with box + = 5 : plot ticked grid and box with axis tick marks + = 6 : plot without grid or box + (1's digit) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +xl (R): x axis length in inches (integer valued) + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches (integer valued) + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string (limited to 99 characters) +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array + if |nt|/100 > 0 : use line type list +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl, yl or nt<0) +yx (R): maximum value of y array (required if xl, yl or nt<0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color list + ic(1) : color for grid + ic(2) : color for axis line + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color for plotted line 1 + ic(6) : color for plotted line 2 + ic(7) : color for title (return) +l (I): data line type list (required only if |nt|/100 > 0) + +common /cplotsc2/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl 1 SUBROUTINE SCATPL +.p +.x scatter plot +~SCATPL plots data point pairs (x,y) in a scatter plot format using +~log and/or ~linear scaling including appropriate axes and plot title. +Several different sets of data may be plotted on the same plot by +specifying different plotting symbols for each set of data points. +Various options select the format of plotting. If nl=1 then the x +and y arrays may be 1d arrays. +.lit + +CALL SCATPL(x,y,nl,np,iflag,nsym,s,xl,yl,xt,nxt,yt,nyt, + t,nt,>) + +x (R): array of x values dimensioned x(np,nl) +y (R): array of y values dimensioned y(np,nl) +nl (I): number of symbol types (if nl=1, x,y may be 1d arrays) +np (I): number of data point pairs (x,y) of same symbol type +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : plot ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +nsym (I): array of symbols numbers dimensioned nsym(nl) + nsym(n) < 0 : dots only plotted, no symbols line n + nsym(n) >= 0 : plot symbol number for line n +s (R): size of symbols (if s <= 0, 0.1 is used) +xl (R): x axis length in inches (integer-valued) + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches (integer-valued) + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl,yl or nt<0) +yx (R): maximum value of y array (required if xl,yl or nt<0) +(NOTE: color array required if nt < 0 or |nt|/100 >0) +ic (I): color list + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for title (return) + ic(7) : color for plotted line 1 + ic(8) : color for plotted line 2 + ic(9) : etc. + +common /cscatpl/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl 1 SUBROUTINE SEISPL +.x seismic plotting +~SEISPL allows for plotting data in the special formats often used in seismic +data processing using ~log and/or ~linear axis scaling. Appropriate +axes and plot titles may be included. The plotting format may be +selected by the value of ntype. Possible plotting formats include: +multiple "shaded" waveforms, connected lines, vertical line plots, etc. +Each line may be offset from the previous line by a specified value for +presentation on the plot (z array). A line may be added to indicate +the zero value, etc. If nl=1 then the x and y arrays +may be 1d arrays. +.lit + +CALL SEISPL(x,y,z,nld,npd,nl,np,iflag,ntype,size,zref,xl,yl, + xt,nxt,yt,nyt,t,nt,>) + +x (R): array of x values dimensioned x(npd) +y (R): array of y values dimensioned y(npd,nld) +z (R): array of y-offset values dimensioned z(nl). Y value is + offset by the z value before plotting. When using log + plotting note that offset occurs after taking logs. +nld (I): dimension of y array +npd (I): dimension of x,y arrays +nl (I): number of lines plotted (if nl=1, x,y may be 1d arrays) +np (I): number of data points to plot per line +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : plot ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +ntype (I): plot format control + < 0 : line with zref plotted + = 0 : symbols only + > 0 : line without zref plotted + (magnitude) = 1 : symbols only plotted + = 2 : points only plotted + = 3 : connected points plotted + = 4 : vertical lines from points to zref line plotted + = 5 : vertical lines plus symbol at point plotted + = 6 : vertical lines and connected points plotted + = 7 : connected points and lines on + side of zref + = 8 : connected points and lines on - side of zref + = 9 : area between connected points and zref filled + = 10 : positive area filled + = 11 : negative area filled +size (R): size of symbols (ntype : 0,1,4) + spacing between area fill lines (ntype : 9,10,11) + < 0 : indicates center line to be dotted + > 0 : indicates center line solid (if plotted) +zref (R): offset added to all z values +xl (R): x axis length in inches + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl,yl or nt<0) +yx (R): maximum value of y array (required if xl,yl or nt<0) +(NOTE: color array required if nt < 0) +ic (I): color array + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for title (return) + ic(7) : color for plotted line 1 + ic(8) : color for plotted line 2 + ic(9) : etc. + +common /cseispl/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE SPLOTS +.p +SPLOTS plots points and/or curves defined by x,y pairs in log and/or +linear scaling with option error bars. +~SPLOTS calls SPLOTSX and is provided to simplify axis specification. +.lit + +CALL SPLOTS(x,y,nld,npd,nl,np,iflag,nopt,as,xl,yl, + xt,nxt,yt,nyt,t,nt,>) + +see SPLOTSX for variable description + +common /csplots/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.hl1 SUBROUTINE SPLOTSX +.x error bars +.p +Appropriate axes and plot title may be included. +Various options select the plotting format of plotting. Possible plot +formats include scatter plots, connected line points with error bars +shown, points with error bars, a displacement line from x axis, etc. +.p +This subroutine may be used to plot several sets of curves. For a given +set (or line) of points, the upper error bar value may be given in the +next set (or line) of points. The lower error bar value may be given in +the following set (or line). When the error bar option is used, the value +of nl should be the number of points sets (or lines) to be plotted not +including the error bar sets. This subroutine permits axis parameter +flexibility and dimensioning for y array. +.lit + +CALL SPLOTSX(x,y,nld,npd,nl,np,iflag,nopt,as,xl,yl, + nmx,nnx,mlx,tsx,ndx,smx,nmy,nny,mly,tsy,ndy,smy, + xt,nxt,yt,nyt,t,nt,>) + +x (R): array of x values dimensioned at least x(np) +y (R): array of y values dimensioned y(npd,nld) +npd (I): dimension of y +nld (I): dimension of y +nl (I): number of y lines to plot (see note below) +np (I): number of points per line +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : plot x linear, y logarithmic (base 10) + = 2 : plot x logarithmic, y linear + = 3 : plot x logarithmic, y logarithmic + = 4 : plot x linear, y linear + (10's digit) = 0 : no axes or title plotted + = 1 : axes with axis line/ticks on top and sides + = 2 : plot solid cartesian grid + = 3 : plot ticked cartesian grid without box + = 4 : plot ticked cartesian grid with box + = 5 : ticked cartesian grid, box w/axis ticks + = 6 : plot without box or cartesian grid + = 7 : plot solid logarithmic grid + = 8 : plot dotted logarithmic grid + = 9 : plot ticked logarithmic grid + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +nopt (I): option flag + (1's digit) = 0 : disconnected points + = 1 : connected points + = 2 : disconnected symbols + = 3 : connected symbols + = 4 : vertical line from point to x axis + = 5 : connect points, add vertical line from each + data point to x axis + = 6 : symbol plus vertical line from point to x axis + (10's digit) = 0 : no error bars + = 1 : error bars (see above) + = 2 : error bars witout end bars (see above) + (100's) > 0 : every (*) point shown with a symbol + (0 equivalent to 1) +as (R): size of plotted symbol and/or error bar +xl (R): x axis length in inches + < 0 : use input scaling in xm,xx + > 0 : use auto scaling computed from input array +yl (R): y axis length in inches + < 0 : use input scaling in ym,yx + > 0 : use auto scaling computed from input array +(see AXIS2 for detailed description of axis parameters) +nmx (I): number of minor ticks between major ticks on x axis +nnx (I): highlight length of nnx-th minor tick on x axis +mlx (I): number of major tick marks on x axis +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndx (I): number of digits to right of decimal point on x axis +smx (R): major tick length on x axis +nmy (I): number of minor ticks between major ticks on y axis +nny (I): highlight length of nny-th minor tick on y axis +mly (I): number of major tick marks on y axis +tsy (R): size of title and numbers on y axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndy (I): number of digits to right of decimal point on y axis +smy (R): major tick length on y axis +xt (B): x axis title string +nxt (I): number of characters in xt + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +yt (B): y axis title string +nyt (I): number of characters in yt + < 0 : axis ticks on right of y axis + = 0 : no axis + > 0 : axis ticks on left of y axis (normal) +t (B): plot title string +nt (I): number of characters in t + < 0 : use color array + = 0 : no title + > 0 : do not use color array +xm (R): minimum value of x array (required if xl or nt < 0) +xx (R): maximum value of x array (required if xl or nt < 0) +ym (R): minimum value of y array (required if xl,yl or nt<0) +yx (R): maximum value of y array (required if xl,yl or nt<0) +(NOTE: color array required if nt < 0) +ic (I): color list + ic(1) : color for grid + ic(2) : color for axis lines + ic(3) : color for axis numbers + ic(4) : color for axis titles + ic(5) : color for axis exponents + ic(6) : color for title (return) + ic(7) : color for points in line 1 + ic(8) : color for symbols/error bars line 1 + ic(9) : color for points in line 2 + ic(10): color for symbols/error bars line 2 + ic(11): etc. + +common /csplotsx/xmr,dxr,ymr,dyr + +xmr (R): returned value of xmin +dxr (R): returned value of scale factor (xmax-xmin)/xlen +ymr (R): returned value of ymin +dyr (R): returned value of scale factor (ymax-ymin)/ylen +.end lit + +.pg +.hl1 SUBROUTINE T3DH +.p +.x surface plot +~T3DH plots a 3-d surface defined on a uniformly spaced 2-d grid in +the x,y plane using a triangular mesh with hidden line removal. The +surface can be viewed from any angle. +The input consists of the values of the z axis for each +(x,y) point on the plane. Each square grid is plotted as two triangles +using either ~SKETCH or ~PLT3DH permitting hidden line removal if desired. +T3DH calls ~INIT3DH to initialize the 3-d hidden line package. Default +space is provided in the INIT3DH common block. The ISIZE variable will +be reset to the internal size if its value is smaller than the internal +size. Sufficient space is provided for very complex surfaces. +.lit + +CALL T3DH(z,ndx,ndy,nx,ny,s,p,t,dv,xl,yl,zl,iflag,ia, + xt,nxt,xm,xx,tx,sx,gx,fx, + yt,nyt,ym,yy,ty,sy,gy,fy, + zt,nzt,tz,sz,gz,fz,zm,zx<,ic>) + +z (R): array of z values +ndx,ndy(I): dimensions of z array +nx,ny (I): number of points in each dimension to use of z array +s,p,t (R): yaw,roll,pitch angles of axes (see INIT3DH) +dv (R): perspective scale factor for INIT3DH + < 0 : no hidden lines in SKETCH, INIT3DH called + = 0 : INIT3DH not called to initialize 3d package, + (INIT3DH previously called) + > 0 : hidden lines in SKETCH, INIT3DH called + = 9999 : no perspective in INIT3DH +xl (R): x axis length in inches +yl (R): y axis length in inches +zl (R): z axis length in inches +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : do not use color array + = 2 : use color array + (10's digit) = 0 : hidden line removal for surface only + = 1 : hidden line removal for axis and surface + = 2 : no hidden line removal (SKETCH not used) + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +ia (I): axis option flag + < 0 : plot axis use input z axis scale + = 0 : do not plot axes + > 0 : plot axis use computed z axis scale + (1's digit) = 1 : plot y axis using input scale + = 2 : plot y axis using input, smoothed scale + (10's digit) = 1 : plot x axis using input scale + = 2 : plot x axis using input, smoothed scale +xt (B): x axis title string +nxt (I): number of characters in x axis title + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +tx (R): number and pattern of axis ticks (see AXIS3) +sx (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gx (R): rotation angle for x axis (see AXIS3DH) +fx (R): format of axis number labeling (see AXIS3) +yt (B): y axis title string +nyt (I): number of characters in y axis title + < 0 : axis ticks on top of axis + = 0 : no axis + > 0 : axis ticks on bottom of axis (normal) +ty (R): number and pattern of axis ticks (see AXIS3) +sy (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gy (R): rotation angle for y axis (see AXIS3DH) +fy (R): format of axis number labeling (see AXIS3) +zt (B): z axis title string +nzt (I): number of characters in z axis title + < 0 : axis ticks on top of axis + = 0 : no axis + > 0 : axis ticks on bottom of axis (normal) +tz (R): number and pattern of axis ticks (see AXIS3) +sz (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gz (R): rotation angle for z axis (see AXIS3DH) +fz (R): format of axis number labeling (see AXIS3) +xm,ym (R): minimum value displayed on each axis +xx,yx (R): maximum value displayed on each axis +zm (R): minimum value of z axis (required if ia < 0) +zx (R): maximum value of z axis (required if ia < 0) +ic (I): color array (required if 1's digit of iflag=2) + ic(1) : color of axis + ic(2) : surface color +.end lit + +.pg +.hl1 SUBROUTINE TRIG3DH +.p +.x surface plot +.x triangc +~TRIG3DH plots a 3-d surface specified by randomly scatted set of points +as a triangular mesh with hidden line removal. The surface may be +viewed from any angle. +The input consists of a list of triplets defining the surface. +The triplets are triangulated using TRIANGC. Each triangle is +plotted using either ~SKETCH or ~PLT3DH permitting hidden line +removal if desired. TRIG3DH calls ~INIT3DH to initialize the +3-d hidden line package. Default space is provided in the INIT3DH +common block. The ISIZE variable will be reset to the internal +size if its value is smaller than the internal size. Sufficient +space is provided for very complex surfaces. +.lit + +CALL TRIG3DH(x,y,z,n,s,p,t,dv,xl,yl,zl,iflag,ia, + xt,nxt,tx,sx,gx,fx, + yt,nyt,ty,sy,gy,fy, + zt,nzt,tz,sz,gz,fz, + xm,xx,ym,yx,zm,zx<,ic>) + +x,y,z (R): array of point triplets (x,y,z) +n (I): number of points +s,p,t (R): yaw,roll,pitch angles of axes (see INIT3DH) +dv (R): perspective scale factor for INIT3DH + < 0 : no hidden lines in SKETCH, INIT3DH called + = 0 : INIT3DH not called to initialize 3d package, + (INIT3DH previously called) + > 0 : hidden lines in SKETCH, INIT3DH called + = 9999 : no perspective in INIT3DH +xl (R): x axis length in inches +yl (R): y axis length in inches +zl (R): z axis length in inches +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 1 : do not use color array + = 2 : use color array + (10's digit) = 0 : hidden line removal for surface only + = 1 : hidden line removal for axis and surface + = 2 : no hidden line removal (SKETCH not used) + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +ia (I): axis option flag + < 0 : do not plot axes + > 0 : plot axes according to the code, + (1's digit) = 1 : plot z axis using computed scale + = 2 : plot z axis using computed, smoothed scale + = 3 : plot z axis using input scale + input scale variables required + = 4 : plot z axis using input, smoothed scale + (100's digit) = 1 : plot y axis using computed scale + = 2 : plot y axis using computed, smoothed scale + = 3 : plot y axis using input scale + input scale variables required + = 4 : plot y axis using input, smoothed scale + (100's digit) = 1 : plot x axis using computed scale + = 2 : plot x axis using computed, smoothed scale + = 3 : plot x axis using input scale + input scale variables required + = 4 : plot x axis using input, smoothed scale +xt (B): x axis title string +nxt (I): number of characters in x axis title + < 0 : axis ticks on top of x axis + = 0 : no axis + > 0 : axis ticks on bottom of x axis (normal) +tx (R): number and pattern of axis ticks (see AXIS3) +sx (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gx (R): rotation angle for x axis (see AXIS3DH) +fx (R): format of axis number labeling (see AXIS3) +yt (B): y axis title string +nyt (I): number of characters in y axis title + < 0 : axis ticks on top of axis + = 0 : no axis + > 0 : axis ticks on bottom of axis (normal) +ty (R): number and pattern of axis ticks (see AXIS3) +sy (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gy (R): rotation angle for y axis (see AXIS3DH) +fy (R): format of axis number labeling (see AXIS3) +zt (B): z axis title string +nzt (I): number of characters in z axis title + < 0 : axis ticks on top of axis + = 0 : no axis + > 0 : axis ticks on bottom of axis (normal) +tz (R): number and pattern of axis ticks (see AXIS3) +sz (R): size of axis labeling (see AXIS3) + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +gz (R): rotation angle for z axis (see AXIS3DH) +fz (R): format of axis number labeling (see AXIS3) +xm,xx (R): minimum, maximum value of x axis +ym,yx (R): minimum, maximum value of y axis +zm,zx (R): minimum, maximum value of z axis +ic (I): color array (required if 1's digit of iflag=2) + ic(1) : color of axis + ic(2) : surface color +.end lit + +.pg +.hl 1 SUBROUTINE VAX3D +.p +VAX3D plots a 3-d surface by plotting 2-d slices of the surface paralel +to the x-z plane with hidden line removal. See VAX3DX. +~VAX3D calls VAX3DX using default axis parameters to simplify calling +procedure. +.lit + +CALL VAX3D(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag,iax,>>) + +See VAX3DX for parameter description. + (iax is limited to a single digit) +.end lit + +.hl 1 SUBROUTINE VAX3DX +.p +.x 2-d surface plot +~VAX3DX is a simple 3-d surface plotting routine. A 3-d surface is +plotted by plotting slices through the surface which are parallel to +the x-y plane. The y value of the surface at the intersection +of the slice plane and the y value plotted. Hidden lines are supressed, +giving the illusion of a 3 dimensional surface. The height of plotted +surface relative to its y axis value is calibrated to x and z axis. No +perspective is used. Options exist to varying the plotting angle and +to plot axes. +.p +Origin of the plot is in the lower-left corner. The x axis runs +left to right along the plot bottom. The y axis is plotted +as a vertical displacement offset by the z axis value. The z axis appears +to point into the screen. This, with the hidden line removal, gives the +illusion of depth. +.P +VAX3DX contains an internal working storage arrays dimensioned sufficiently +large for most sufaces. However, for very complex surfaces, the working +storage buffer length may be exceeded. In this case +an error message is written to the terminal and the routine terminated. +.lit + +CALL VAX3DX(d,ndx,ndz,nx,nz,a,b,xh,yh,zh,iflag,iax, + >>) + +d (R): array of y values dimensioned d(ndx,ndz) +ndx,ndz (I): x and z dimensions of d array +nx,nz (I): x and z sizes of surface to plot d array +a (R): angle of x axis from horizontal 0-85 degrees +b (R): angle of z axis from horizontal 0-90 degrees + note: origin (1,1) is in lower-left corner + x axis runs left to right on screen + y axis runs up to down on screen + z axis appears to run into the screen but + is angled to the right +xh,yh,zh (R): length of each axis +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) >10000 : do not initialize LONGLIB before plotting + (1's digit) = 2 : use color array (need all parameters) + = 1 : do not use color array + (10's digit) = 0 : Plot sides + = 1 : Do not plot sides + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axes, use input scale factors dm and dx + = 0 : no axes plotted, optional parameters (xt...dx) + not used, scaling computed from input array + > 0 : plot axes, use scaling computed from input array + only axis parameters xt through smz required. + (1's digit) = 1 : Plot actual max/min or input values for Y axis + = 2 : Plot smoothed values for Y axis + (10's digit) = 0 : Use default axis type + = 1 : Use input AXIS2-type axis parameters + (nmx, nnx, mlx, tsx, ndx, etc.) +(NOTE: the following optional paramters are used if iax < 0 + or mod(iflag,10)=1) +xt (B): title of x axis (width) +nxt (I): number of characters in xt + = 0 : no axis plotted + > 0 : normal +xs,xe (R): starting and ending values displayed on x axis +(see AXIS2 for detailed description of axis parameters) +nmx (I): number of minor ticks between major ticks on x axis +nnx (I): highlight length of nnx-th minor tick on x axis +mlx (I): number of major tick marks on x axis +tsx (R): size of title and numbers on x axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndx (I): number of digits to right of decimal point on x axis +smx (R): major tick length on x axis +yt (B): title of y axis (depth) +nyt (I): number of characters in yt + = 0 : no y axis plotted + > 0 : normal +nmy (I): number of minor ticks between major ticks on y axis +nny (I): highlight length of nny-th minor tick on y axis +mly (I): number of major tick marks on y axis +tsy (R): size of title and numbers on y axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndy (I): number of digits to right of decimal point on y axis +smy (R): major tick length on y axis +zt (B): title of z axis (height) +nzt (I): number of characters in zt + = 0 : no z axis plotted + > 0 : normal +ze,ze (R): starting and ending valued displayed on z axis +nmz (I): number of minor ticks between major ticks on z axis +nnz (I): highlight length of nnz-th minor tick on z axis +mlz (I): number of major tick marks on z axis +tsz (R): size of title and numbers on z axis + < 0 auto exponent scaling (x10 to power) disabled + > 0 auto exponent scaling (x10 to power) enabled +ndz (I): number of digits to right of decimal point on z axis +smz (R): major tick length on z axis +(NOTE: the following optional parameters are required only if + iax < 0 or mod(iflag,10)=1) +dm,dx (R): minimum and maximum values of d array +(NOTE: color array required only if mod(iflag,10)=1) +ic (I): color list + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color index for lower plot surface (return) + ic(6) : color index for upper plot surface (return) +.end lit + +.pg +.hl 1 SUBROUTINE VAX5D +.p +.x 5-d surface +.x 4-d surface plot +.x VAX3D +~VAX5D plots a 4 or 5-d surface by plotting slices through the 3rd and +4th dimensions in a 2-d array of of 3-d plots. Each 3-d surface +plots d(*) as a function of 2 of the dimensions using VAX3D. +.p +Origin of the plot is in the lower-left corner. The X axis runs +left to right along the subplot bottom. The Y axis is plotted into +the page of the subplot (see VAX3D). +The Z axis runs left to right in subplots +with the W axis vertical subplots. +.tp 8 +.lit + + ^ W + | + | d Y + | |/_ X + | + ----------> Z +.end lit +.p +Since the subplots may runoff the edge of the plotting page, the routine +includes a page size option to issue a NEWPAGE and plot the additional +subplots on separate pages. A shrinking factor is included to shrink the +subplots. +Labeling of the W and Z axis is due in the lower right hand corner. +Each subplot is further tagged with the corresponding W and Z axis +value. A multiple page plot can be pasted together to form a large +representation of a 5-d (or 4-d) surface. +.lit + +CALL VAX5D(d,nd,n,a,b,iflag,iax,iform,w,xh,yh,zh,ph,pl,fac,iw,iz, + st,en,t1,nt1,t2,nt2,t3,nt3,t4,nt4,dt,ndt,>) + +d (R): array to plot dimensioned d(nd(1),nd(2),nd(3),nd(4)) +nd (I): array of dimensions of d array +n (I): array of the number of points from in dimension to plot +a,b (R): angles a,b for VAX3D subplot +iflag (I): option flag + < 0 : do not close LONGLIB after plotting + = 0 : close LONGLIB--no plot produced + > 0 : close LONGLIB after plotting + (magnitude) > 10000 : do not initialize LONGLIB before plotting + (1's digit) = 2 : use color array (need all parameters) + = 1 : do not use color array + (10's digit) = 0 : Plot sides of subplots + = 1 : Do not plot sides + (100's) = 0 : Ask which screen device to use + <> 0 : Screen Device Number (see FRAME) +iax (I): axis format control + < 0 : plot axes, use input scale factors dm and dx + = 0 : no axes plotted, optional parameters (t1...dx) + not used, scaling computed from input array + > 0 : plot axes, axis parameters t1 through nt4 used, + scaling computed from input array + (1's digit) = 1 : Plot actual max/min or input values for Y axis + = 2 : Plot SCALE smoothed values for Y axis + (10's digit) = 0 : Axes plotted for all subplots + = 1 : Axes plotted only for first subplot +iform (I): plot format code + selects which dimension of d array is to become + which output axis + + plot axis plot axis +Code X Y Z W Code X Y Z W +_____ ____________ _____ ____________ + 1 input: 1 2 3 4 13 3 1 2 4 + 2 dimen- 1 2 4 3 14 3 1 4 2 + 3 sion 1 4 2 3 15 3 2 1 4 + 4 number 1 4 3 2 16 3 2 4 1 + 4 1 4 3 2 16 3 2 4 1 + 5 1 3 2 4 17 3 4 1 2 + 6 1 3 4 2 18 3 4 2 1 + 7 2 1 3 4 19 4 1 2 3 + 8 2 1 4 3 20 4 1 3 2 + 9 2 4 3 1 21 4 2 1 3 + 10 2 4 1 3 22 4 2 3 1 + 11 2 3 4 1 23 4 3 1 2 + 12 2 3 1 4 24 4 3 2 1 + +w (R): working array dimensioned at least n(x)*n(y) +xh,yh,zh (R): length of each axis of subplot +ph,pl (R): page height, length when multiple pages required +fac (R): shrink factor for subplots (2 == FACTOR(1/2)) +iw,iz (I): plot every iw'th and iz'th subplots +st,en (R): arrays containing axes start and end values (permuted + along with d array dimensions) +(NOTE: titles/number of characters permuted with d array dimensions) +t1 (B): title corresponding to 1st dimension of d +nt1 (I): number of characters in title t1 + = 0 : no axis plotted + > 0 : axis plotted +t2 (B): title corresponding to 2st dimension of d +nt2 (I): number of characters in title t2 + = 0 : no axis plotted + > 0 : axis plotted +t3 (B): title corresponding to 3rd dimension of d +nt3 (I): number of characters in title t3 + = 0 : no axis plotted + > 0 : axis plotted +t4 (B): title corresponding to 4th dimension of d +nt4 (I): number of characters in title t4 + = 0 : no axis plotted + > 0 : axis plotted +t5 (B): title corresponding to 5th dimension of d +nt5 (I): number of characters in title t5 + = 0 : no axis plotted + > 0 : axis plotted +(NOTE: the following optional parameters are required only if + iax < 0 or mod(iflag,10) = 1) +dm,dx (R): minimum and maximum scale values for array +ic (I): color array + ic(1) : color for axis lines + ic(2) : color for axis numbers + ic(3) : color for axis titles + ic(4) : color for axis exponents + ic(5) : color index for lower plot surface (return) + ic(6) : color index for upper plot surface (return) +.end lit + +.Chapter Miscellaneous Routines +.P +The subroutines listed below are ~miscellaneous functions and +routines used by the previously described routines. These are low-level +routines documented for the use of advanced LONGLIB programers. + +.hl1 INTEGER FUNCTION IPCLIP +.p +~IPCLIP tests a point to determine if it lies in a rectangle defined by +xm,ym,xx,yx and returns an integer value indicating where point is in relation +to rectangle. The value can be easily be decoded by "anding" return +value with the binary values of 1, 2, 4, 8. +.lit + + 9 | 8 | 10 + -------------- + 1 | 0 | 2 + -------------- + 5 | 4 | 6 +.end lit +.lit + +iflag = IPCLIP(x,y,xm,ym,xx,yx) + +x,y (R): point to test +xm,ym (R): lower left corner of rectangle +xx,yx (R): upper right corner of rectangle +iflag (I): clip flag (0-10) (see above) +.end lit + +.hl1 SUBROUTINE GCONTR +.p +~GCONTR draws contour lines of a 2-d array using a technique which +produces long, connected contour lines. It assumes that the points +of the input array are equally spaced in each dimension. Several +options for contouring are provided. When cs, the label character size +is positive, the origin point (1,1) is in the +lower-left corner and the point (i,j) in the array is plotted at, +.lit + + xplot = (i-1)*xl + yplot = (j-1)*yl + +.end lit +If cs is negative, the x and y values plotted (xp,yp) for the point +(i,j) in the array are computed using +the ~PLT3D ~transformation common block ~PLT3B (see PLT3D), +.lit + + xp = a1 * (yl * j) + a2 * (xl * i) + a3 + yp = b1 * (yl * j) + b2 * (xl * i) + b4 +.end lit +where the vertical height (z) is zero. In this case, xl and yl +should be set to 1.0 and PLT3D should be called before GCONTR. +GCONTR is used in the MASTER routine ~LCNTR and CVAX3DX. +.x CVAX3DX +.lit + +CALL GCONTR(z,ndx,ndy,nx,ny,xl,yl,cv,nv,zm,iw,n,cs,m,i,ic,il) + +z (R): 2-d array of values dimensioned z(nx,ny) +ndx,ndy (I): dimensions of data array +nx,ny (I): number of points to use in array +xl,yl (R): axis length scale factors (inches/array index) +cv (R): array of contour levels dimensioned cl(nv) +nv (I): number of contour levels (note: if nv < 0 then only + one contour level is used. It will be labeled with + the abs(nv)'th symbol) +zm (R): maximum value of z for consideration. A z value which + exceeds this value will be ignored. The cell edges + which include this point will not be included in + contouring. +iw (I): workspace dimensioned at least (2*nx*ny*nv+1)/31 +n (I): contour labeling option + < 0 label with contour value (number with n digits + to the right of the decimal point) + = 0 no labelling of contours + > 0 label with alphabet (nl should be less than 26) +cs (R): size of labels + < 0 : plot contours using PLT3B transformation + xl and yl should then be set to 1.0 (see notes) + > 0 : normal location specification +m (I): minimum number of cells crossed by contour in order + for contour to be labeled +i (I): color and line type flag + = 0 color and line type arrays not used + = 1 color array used + = 2 line type array used + = 3 color and line type array used +ic (I): color list for each contour (only requied for i>0) +l (I): line type list for contours (required only for i>1) +.end lit + +.hl1 INTEGER FUNCTION INXTCHR +.x vt100 +.p +~INXTCHR returns a single key pressed on the terminal. In the VAX/VMS +environment, it will intercept all control +keys (including ) except ^Y,^T,^R,^Q,^Z,^S without echoing to the +screen. Opens a direct IO ~channel to the terminal driver using SYSQIO. +This routine is used by the ~PAUSE and ~CURMOTION routines. +.lit + +key = INXTCHR() + +key (I): (returned) terminal character (ASCII value) + if key < 0, an error reading terminal input has occured. +.end lit + +.hl1 INTEGER FUNCTION IRMCHAN +.p +.x ramopen +~IRMCHAN returns the ~channel number and the Ramtek device number +used by the plot package (as assigned +by RAMOPEN) for communicating with the Ramtek. +Returns a negative value when the Ramtek package is not initialized +or when the Ramtek channel is not yet assigned. +.lit + +ich = IRMCHAN(id) + +id (I): (returned) Ramtek device number +ich (I): (returned) Ramtek channel number + if ich <=0 the Ramtek is not is use. +.end lit + +.hl1 SUBROUTINE MATMUL4 +.p +~MATMUL4 multiplies two 4x4 matrixes A and B and sets C=AB. Does not +change the contents of A and B. +.lit + +CALL MATMUL4 (c,a,b) + +c,a,b (R): 4 x 4 matrixes +.end lit + +.hl1 SUBROUTINE MTV4 +.p +~MTV4 multiplies a 4 element row vector by a 4x4 matrix and sets V2=A V1. +.lit + +CALL MTV4 (v2,a,v1) + + +v2 (R): 4 element row vector +a (R): 4 x 4 matrix +v1 (R): 4 element row vector +.end lit + +.hl1 SUBROUTINE NXTVU +.p +.x plt3d +~NXTVU is used internally by PLT3D. NXTVU computes the maximum (or minimum) +of two piecewise linear functions: the curve specified in the input d array +and the curve stored in the working array w. +On return the new maximum (minimum) curve replaces the old in w. Any line +segments or fractions thereof above (below) the maximum (minimum) are plotted. +If iabs(i)=1 the input is copied into the working array and plotted. +Subsequent calls should use iabs(i)=2. +Using i positive computes the maximum while using i negative plots the +minimum. +.p +A grid of lines in only one dimension may be made by calling NXTVU once +for each row, adjusting the d curve to offset each row by a small +amount to give the impression of a surface. +.p +The dimension of the working arrays is dependent of the surface +complexity -- the greater the complexity the larger n2 must be. ier is +used to indicate when n2 is not large enough. As a minimum n2>2*n. +Note: w should not be modified between calls. +.lit + +CALL NXTVU (i,d,n,w,n2,ier) + +i (I): initialize code + < 0 : plot lower side of surface + => 0 : plot upper side of surface + = -1 : first call for lower surface plot + = -2 : subsequent calls for lower surface plot + = 1 : first call for upper surface plot + = 2 : subsequent calls for upper surface plot +d (R): array of (x,y) coordinate pairs dimensioned d(2*n) + d(1) = x(1) + d(2) = y(1) + d(3) = x(2) + ... +n (I): number of coordinate pairs in d array +w (R): working storage array of dimensioned d(n2) + (should not be modified between calls) +n2 (I): dimension of working array +ier (I): (returned) error code + = 0 : no error + = 1 : out of space in w +.end lit + +.hl1 SUBROUTINE PAUSE +.x INXTCHR +.p +~PAUSE prompts terminal without a CTERM(1) for a keystroke to continue. +Uses INXTCHR. +.lit + +CALL PAUSE + (no arguments) +.end lit + +.hl1 SUBROUTINE PAUSEP +.x INXTCHR +.p +~PAUSEP prompts terminal for a keystroke to continue. Includes appriate +~CTERM calls to prompt in text mode then returns terminal to plot mode. +Uses INXTCHR. +.lit + +CALL PAUSEP + (no arguments) +.end lit + + +.hl1 SUBROUTINE RAMCLOSE +.p +~RAMCLOSE closes and deassigns the ~Ramtek channel and deallocates the device. +When the ~REF routines are used, it interatively prompts for the output +device and option. ~REFDIS called prior to RAMCLOSE disables the prompting +in the REF package. Note that RAMCLOSE is call by ~PLOTRM when a +PLOTND or PLOTRM(0.,0.,11) is called. +.lit + +CALL RAMCLOSE (ic) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +.end lit + + +.hl 1 SUBROUTINE REFDIS +.p +~REFDIS is used only in the ~LONGLIBR version of the longlib graphics +library. It is a dummy call for other versions. REFDIS is a non-interactive +method of specifying the output device (REF file, terminal screen, or +LONGLIB metafile) to be used for outputing the REF bit-map Ramtek image array. +When called prior to PLOTND, it outputs the array to the device +specified in the call without user intervention. +When REFDIS is not called prior to PLOTND, PLOTND will call REFDIS and +the user will be prompted for the output device and option. +Note: REFDIS may be called multiple times to output to several devices. +.p +When the internal REF data array is output to the terminal or metafile +output each line of the internal array is scanned left to right. Connected +pixels having the same color are collected and plotted (using PLOT) to the +output device. Pixels with 0 value are not output. The pixel-to-inch +output scaling can be user selected to correspond to the actual hardware +resolution of the output device. Normal resolution for the terminal output +is 9.5/1024 inch/pixel (most terminals do not actually have this resolution). +Normal resolution for the meta file output is 1/300 inch/pixel. +Hence, at normal resolution, the 1280x1024 pixel REF array more than +fills the terminal screen. The pixel image is output with the lower-left +corner at (0,0). By changing the origin prior to call the user can +display any desired portion of the image. +.lit + +CALL REFDIS(id,ot,n,rx,ry) + +id (I): Output device + =-1 : graphics terminal number code (see FRAME) + user-specified (rx,ry) used + = 1 : graphics terminal number code (see FRAME) + default resolution used + = 2 : Ramtek emulation file (REF) + (ot = 1 : absolute file write) + (ot = 2 : write out only non-zero pixels) + (ot = 3 : write out only zero pixels) + =-3 : LONGLIB metafile output + user-specified (rx,ry) used + = 3 : LONGLIB metafile output + default resolution used +ot (I): Output option code (see above) +n (C): REF file name +rx,ry (R): user-specified output resolution (inch/pixel) +.end lit + +.hl 1 SUBROUTINE RMCLEAR +.p +~RMCLEAR clears ~Ramtek screen. +.lit + +CALL RMCLEAR (ic,ie) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMDIR +.x Ramtek image data +.p +~RMDIR sets the write direction for ~image array data on the +~Ramtek display. This routine is supported in the REF package. +.lit + +CALL RMDIR (ic,is,ie) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +is (I): scan sequence code + code pix-to-pix line-to-line + 0 L-R T-B + 1 R-L T-B + 2 L-R B-T + 3 R-L B-T + 4 T-B L-R + 5 B-T L-R + 6 T-B R-L + 7 B-T R-L +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMFNTSIZE +.p +~RMFNTSIZE changes the size of Ramtek ~text displayed on the ~Ramtek display. +Not supported in REF package. +.lit + +CALL RMFNTSIZE (ic,ih,iv,ihs,ivs,ie) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +ih,iv (I): horizontal,vertical dimension +ihs,ivs (I): horizontal,vertical spacing +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RAMOPEN +.p +~RAMOPEN (1) translates the local name "RM" to determine the ramtek device +number, (2) allocates the ramtek device, (3) assigns a channel to the Ramtek +device, and (4) opens the channel I/O. Returns the channel number or +-1 if device is not available. This is routine is called by RPLOTS which +is called by FRAME. RAMOPEN initializes the REF array. +.lit + +CALL RAMOPEN(ic,it,id,ie) + +ic (I): returned channel number +it (I): Ramtek device code input + = 1 1280x1024 Ramtek + = 2 512x512 Ramtek +id (I): returned Ramtek device number +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RAMOUT +.p +~RAMOUT outputs a command and data array to the ~Ramtek display. +(see Ramtek manual for command formats). The REF package uses RAMOUT +for a different purpose. +.lit + +CALL RAMOUT (ic,m,n,ie) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +m (B): array of bytes to output +n (I): number of bytes +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMPAN +.p +~RMPAN pans Ramtek display. Not supported in REF package. +.lit + +CALL RMPAN (ic,il,ir,ie) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +il (I): left x pixels +ir (I): right y pixels +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMPLOT +.p +~RMPLOT plots an array of connected vectors using pixel locations on Ramtek +or REF package. This routine is called by PLOTRM which is called by PLOT. +RMPLOT simulates line widths using the width information stored in an +internal common block by RMTEXTURE by replicating the line several times +with pixel offsets to produce a "thick" line. +Note: x is in pixels from right to left. y is in pixels from top of display. +.x color table +.x RMTEXTURE +.lit + +CALL RMPLOT (ic,n,ia,k,ie) + +ic (I): channel number (from RAMOPEN or IRMCHAN) +n (I): number of point pairs (<129) +ia (I): array of point pairs (in pixels) + a(1)=x1,a(2)=y1,a(3)=x2,... +k (I): color table index to use +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMREADBYTE +.x Ramtek image data +.p +~RMREADBYTE reads the ~Ramtek ~image array. Supported by REF. +.lit + +CALL RMREADBYTE (ic,a,n,ie) + +ic (I): channel number (from RAMOPEN) +a (B): (returned) image data +n (I): number of words of a to read +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMREADCOL +.x color table +.p +~RMREADCOL reads the ~Ramtek color table from the Ramtek display. +The color table is ~INTEGER*4 words. +Not supported by REF. +.lit + +CALL RMREADCOL (ic,ia,n,ie) + +ic (I): channel number (from RAMOPEN) +ia (I): (returned) color table array +n (I): number of words of a to read +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMREADCURSOR +.x curmotion +.x RMSETCURSOR +.p +~RMREADCURSOR reads the current ~Ramtek ~cursor device position. +Called by CURMOTION, etc. See RMSETCURSOR. Not supported on REF package. +.lit + +CALL RMREADCURSOR (ic,id,ix,iy,it,iv,ien,ie) + +ic (I): channel number (from RAMOPEN) +id (I): cursor device number +ix,iy (I): (returned) pixel location of cursor (pixels) +it,iv,ien (I): (returned) codes for track, visible, enter + switches, see RMSETCURSOR +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMREADWORD +.x Ramtek image data +.p +~RMREADWORD reads ~INTEGER*2 words from the ~Ramtek ~image array. +Supported by REF. +.lit + +CALL RMREADWORD (ic,id,n,ie) + +ic (I) : channel number (from RAMOPEN) +id (I*2): (returned) image data +n (I) : number of words to read +ie (I) : (returned) error code +.end lit + +.hl1 SUBROUTINE RMSETCUR +.p +.x CURLOCATE +~RMSETCUR moves specified ramtek ~cursor device to a specified position and +sets it as visible and/or blinking. Called by CURLOCATE. Not supported +by REF +.lit + +CALL RMSETCUR (ic,i,ix,iy,ib,iv,ie) + +ic (I): channel number (from RAMOPEN) +i (I): cursor device number (0-3) +ix,iy (I): pixel position of cursor (see RMPLOT) +ib (I): blink flag (1=no blink,2=blink) +iv (I): visible flag (2=visible, 0=invisible) +ie (I): returned error code +.end lit + +.hl1 SUBROUTINE RMSTART +.x Ramtek image data +.p +~RMSTART sets the start pixel of ~image mode write on the ~Ramtek display. +Supported by REF. +.lit + +CALL RMSTART (ic,ix,iy,ie) + +ic (I): channel number (from RAMOPEN) +ix,iy (I): pixel position to start next image write +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMTEXT +.p +~RMTEXT places text on ~Ramtek display using Ramtek hardware text support. +Not supported on REF. +.lit + +CALL RMTEXT (ic,icol,ix,iy,is,t,nt,ie) + +ic (I): channel number (from RAMOPEN) +icol (I): color +ix (I): x pixel location +iy (I): y pixel location +is (I): size in pixels +t (B): byte array of text +nt (I): number of bytes in the array t +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMTEXTURE +.p +~RMTEXTURE changes the bit texturing pattern for vector line drawing +on the Ramtek. Called by ~RMPEN which is called by ~NEWPEN and +also by ~CURMOTION et. al. Supported by REF. +.LIT + +CALL RMTEXTURE (ic,it,iw,is,ie) + +ic (I): opened channel number (from RAMOPEN) +it (I): line type number (0-15) +iw (I): line width used in RMPLOT (1-7) +is (I): bit width scale factor (0-15) + (0= [1 bit=1 pixel], 1=[1 bit=2 pixels], etc.) +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMWIND +.p +~RMWIND sets the ~image area of the ~Ramtek display. Supported by REF. +.lit + +CALL RMWIND (ic,ix,iy,mx,my,ie) + +ic (I): channel number (from RAMOPEN) +ix,iy (I): starting corner of image pixels (u-r corner) +mx,my (I): ending corner of image pixels (l-l corner) +ie (I): (returned) error code +.end lit +.x Ramtek image data + +.hl1 SUBROUTINE RMWRITEBYTE +.x Ramtek image data +.p +~RMWRITEBYTE write byte ~image data to the ~Ramtek image array. Supported +by REF. +.lit + +CALL RMWRITEBYTE (ic,a,n,ie) + +ic (I): channel number (from RAMOPEN) +a (B): image data +n (I): number of words of a to read +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMWRITECOL +.x color table +.p +~RMWRITECOL writes ~Ramtek color display data to the Ramtek display +color table. The color table is ~INTEGER*4 words. +Not supported by REF. +.lit + +CALL RMWRITECOL (ic,a,n,ie) + +ic (I): channel number (from RAMOPEN) +a (I): new color table array +n (I): number of words of array a +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE RMWRITEWORD +.x Ramtek image data +.p +~RMWRITEWORD writes ~INTEGER*2 ~image data to the ~Ramtek image display. +Supported by REF. +.lit + +CALL RMWRITEWORD (ic,id,n,ie) + +ic (I) : channel number (from RAMOPEN) +id (I*2): image data +n (I) : number of words to read +ie (I) : (returned) error code +.end lit + +.hl1 SUBROUTINE RMZOOM +.p +~RMZOOM zooms ~Ramtek display. Not supported by REF. +.lit + +CALL RMZOOM (ic,iz,ie) + +ic (I): channel number (from RAMOPEN) +iz (I): zoom factor in powers of 2 +ie (I): (returned) error code +.end lit + +.hl1 SUBROUTINE VTPLOT +.p +~VTPLOT plots an array of connected vectors to terminal. ~Terminal +must be in graphics mode prior to call. VTPLOT is called by ~PLOTVT +and by ~CURLOCATE and CURMOTION., et. al. An erase flag is used +to indicate whether vector string should be visible, erased, or +XOR'ed. Since not all terminal support XOR, two flags for XOR are +provided--one which if XOR is not supported writes visible vectors +with the other which erases (if supported). Line width is simulated +by replotting adjacent lines. +.lit + +CALL VTPLOT (n,m,ie,iw) + +n (I): number of point pairs in m +m (I): array of points to be connected with line + m(1)=x1,m(2)=y1,m(3)=x2,... +ie (I): erase flag (0=normal, 1=XOR (on), 2=erase, 3=XOR (off)) +iw (I): width +.end lit + + +.hl1 SUBROUTINE TRIANGC +.p +~TRIANGC triangulates a set of (x,y) points such that the boundry is a +convex polygon. This routine is an adaption of ~COSMIC routine ARC-11441. +Used by some MASTER routines. +.lit + +CALL TRIANGC(x,y,n,nt,nzz,m,i,j,ni,l,nz,ie,ibe,ite) + +x,y (R): arrays of x,y points +n (I): number of points + < 0 : ie,ibe,ite arrays not used + > 0 : ie,ibe,ite arrays used (normal) +nt (I): array of indicies of triangulated points t(nzz,3) + corner 1 of triangle K = (x,y) = (x(t(K,1),y(t(K,1))) + corner 2 of triangle K = (x,y) = (x(t(K,2),y(t(K,2))) + corner 3 of triangle K = (x,y) = (x(t(K,3),y(t(K,3))) +nzz (I): dimension of t array (>3*n) +m (I): number of triangles stored in t +i,j (I): working arrays (dimensioned i(ni),j(ni)) +ni (I): dimension of i,j arrays (ni>=n) +l (I): number of edges in ie,ibe,ite +nz (I): dimension of ie,ibe,ite array (>3*n) +note: these arrays only needed if n>0 +ie (I): array of indicies of each triangle edge ie(nz,2) +ibe (I): edge flag array dimensioned ibe(nz) + = 0 for interior edge + = 1 if ie is a boundry edge +ite (I): array of indicies of the neighbor edges of + each triangle, dimensioned ite(nz,4) +.end lit + +.hl1 REAL FUNCTION XVMUL3D +.p +~XVMUL3D returns one element of an input vector (x,y,z) multiplied by an input +rotation matrix r(4,4). +.lit + +value = XVMUL3D (n,x,y,z,v,r) + +n (I) : which coordinate value to return (1=x,2=y,3=z) +x,y,z (R) : input x,y,z +v (R) : working vector (4 elements) +r (R) : rotation matrix (4,4) +value (R) : desired element value (see n) +.end lit + +.chapter LONGLIB Library Names +.p +This chapter lists the LONGLIB graphics library subroutine names as well +as the subroutines (outside of the standard FORTRAN routines) called by +each subroutine. The calling routines (excluding MASTER routines) are +indicated as well. An asterick +indicates that the routine is documented in the documentation and may +called by the user. + +.hl 1 Subroutine Calls +.ls1 +.dle ,,'.' +.le;~ABSPLT +.br;Calls: WHEREVT, FIXVT0, WHEREPR, FIXPR0, WHERERM, FIXRM0 +.br;Called by: * +.le;~ANXTVU +.br;Calls: (none) +.br;Called by: NXTVU +.le;~ARCALC +.br;Calls: (none) +.br;Called by: LINSEQ +.le;~ARCPLT +.br;Calls: SPIFUN, PLOT, SPIDER +.br;Called by: LINSEQ +.le;~ARCSET (Entry of ARCPLT) +.br;Calls: PLOT +.br;Called by: LINSEQ +.le;~ARROW +.br;Calls: PLOT +.br;Called by: * +.le;~ASTEXIT +.br;Calls: +.br;Called by: (qio -- system routine) +.le;~ASTINTER +.br;Calls: (none) +.br;Called by: *, PLOT +.le;~AXIS +.br;Calls: PLOT, SYMBOL, NUMBER +.br;Called by: * +.le;~AXIS2 +.br;Calls: PLOT, SYMBOL, NUMBER +.br;Called by: * +.le;~AXIS3 +.br;Calls: PLOT, SYMBOL, NUMBER +.br;Called by: * +.le;~AXIS3D +.br;Calls: ROTEM, MATMUL4, PLOT3D, NUM3D, SYM3D, XVMUL3D +.br;Called by: * +.le;~AXIS3DH +.br;Calls: ROTEM, MATMUL4, PLT3D, SKETCH, NUM3DH, SYM3DH, XVMUL3D +.br;Called by: * +.le;~BARCHR +.br;Calls: FRAME, CTERM, PLOT, SYMBOL, NUMBER, PLOTND, NEWPEN, SHADE +.br;Called by: * +.le;~BITCURSOR +.br;Calls: (none) +.br;Called by: * +.le;~BITMAP +.br;Calls: PLOT, LNDSEA +.br;Called by: * +.le;~CHECK3D +.br;Calls: (none) +.br;Called by: LINHID +.le;~CHLSKYS +.br;Calls: (none) +.br;Called by: SMOOTHC +.le;~CIRCLE +.br;Calls: PLOT +.br;Called by: *, PLRAX +.le;~CLIP3D +.br;Calls: (none) +.br;Called by: IPCLP3 +.le;~CLPIT +.br;Calls: IPCLIP +.br;Called by: PLOTVT, PLOTRM, PPLOT +.le;~IPCLIP +.br;Calls: (none) +.br;Called by: CLPIT, PLOTVT, PLOTRM, PPLOT +.le;~CNCELPLT +.br;Calls: SEGCODE, POLY1INT, PLOT +.br;Called by: CNTRPLT +.le;~CNCELPLT3D +.br;Calls: SEGCODE, RVXPT3D, PLOT, POLY1INT +.br;Called by: CNT3DX +.le;~CNDRAW +.br;Calls: PLOT, NEWPEN, SYMBOL, NUMBER +.br;Called by: GCONTR +.le;~CNT3D +.br;Calls: CNT3DX +.br;Called by: * +.le;~CNT3DX +.br;Calls: SCALE, FRAME, CTERM, AXIS2, AXIS, VXPT3D, CNCELPLT3D, +TRCELPLT3D, PLOTND, NEWPEN +.br;Called by: *, CNT3D +.le;~CNTLN +.br;Calls: FRAME, CTERM, SCALE, AXIS3, PLOT, SYMBOL, CNCELPLT, +TRIANGC, INTERPC, CNTOUR, PLOTND, NEWPEN +.br;Called by: * +.le;~CNTOUR +.br;Calls: PLOT +.br;Called by: CNTLN +.le;~CNTRPLT +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, +LGAXS, AXIS, CNCELPLT, PLOTND, NEWPEN +.br;Called by: * +.le;~CSHADE +.br;Calls: PLOT, NEWPEN, PICHRT +.br;Called by: * +.le;~CTERM +.br;Calls: (none) +.br;Called by: *, PLOTVT +.le;~CUBE +.br;Calls: PLT3DH, SKETCH +.br;Called by: *, HIST3D +.le;~CURBAND +.br;Calls: RMTEXTURE, RMSETCUR, RMPLOT, INXTCHR, VTPLOT +.br;Called by: * +.le;~CURLOCATE +.br;Calls: RMSETCUR, VTPLOT +.br;Called by: * +.le;~CURMOTION +.br;Calls: INXTCHR, RMSETCUR, VTPLOT +.br;Called by: * +.le;~CURRECT +.br;Calls: RMTEXTURE, RMSETCUR, RMPLOT, INXTCHR, VTPLOT +.br;Called by: * +.le;~CVAX3D +.br;Calls: CVAX3DX +.br;Called by: * +.le;~CVAX3DX +.br;Calls: NXTVU, PLOT, FRAME, GCONTR, PLT3D, HLT3D, CTERM, AXIS3 +.br;Called by: *, CVAX3D +.le;~DASHL +.br;Calls: PLOT, SYMBOL +.br;Called by: * +.le;~DRAW3D +.br;Calls: PLOT +.br;Called by: PLOT3D +.le;~EARTH3D +.br;Calls: SPRECT1, PLOT3D +.br;Called by: * +.le;~ELLIPSE +.br;Calls: PLOT +.br;Called by: * +.le;~ENABLEAST +.br;Calls: ENAST +.br;Called by: *, FRAME +.le;~ENAST +.br;Calls: (qio system routine if control-c interrupt code is used in package) +.br;Called by: ENABLEAST +.le;~FACTOR +.br;Calls: VFACTOR, RFACTOR, PFACTOR +.br;Called by: * +.le;~FIXPR0 +.br;Calls: PPLOTP +.br;Called by: *, ABSPLT +.le;~FIXRM0 +.br;Calls: RMTEXTURE +.br;Called by: *, ABSPLT +.le;~FIXVT0 +.br;Calls: NEWVPEN +.br;Called by: *, ABSPLT +.le;~FRAME +.br;Calls: VPLOTS, RPLOTS, PPLOTS, ENABLEAST, EXIT (system routine) +.br;Called by: *, PLOTS +.le;~GCONTR +.br;Calls: CNDRAW +.br;Called by: *, LCNTR +.le;~GETCURSOR +.br;Calls: (none) +.br;Called by: * +.le;~GLPLOT +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, +LGAXS, AXIS3, LINE, LGLIN, PLOTND +.br;Called by: * +.le;~GRID +.br;Calls: PLOT +.br;Called by: * +.le;~HELPME +.br;Calls: LIB$DISPLAY_OUTPUT, LIB$STATUS +.br;Called by: * +.le;~HIST3D +.br;Calls: SCALE, FRAME, CTERM, AXIS3DH, PLT3DH, SKETCH, PLOT, +PLOTND, INIT3DH +.br;Called by: * +.le;~HLT3D +.br;Calls: NXTVU, PLOT +.br;Called by: *, CVAX3DX, MVAX3DX +.le;~HPLT +.br;Calls: PLOT +.br;Called by: LINHID +.le;~INIT3D +.br;Calls: MATMUL4, ROTEM +.br;Called by: * +.le;~INIT3DH +.br;Calls: (none) +.br;Called by: * +.le;~INTERPC +.br;Calls: (none) +.br;Called by: CNTLN +.le;~INTERSECT +.br;Calls: (none) +.br;Called by: VAX3DX +.le;~INXTCHR +.br;Calls: SYS$QIO +.br;Called by: *, PAUSE, PAUSEP, CURMOTION, CURRECT, CURBAND +.le;~IPCLP3 +.br;Calls: CLIP3D +.br;Called by: PLOT3D +.le;~IRMCHAN +.br;Calls: (none) +.br;Called by: * +.le;~ISEGCODE +.br;Calls: (none) +.br;Called by: TRCELPLT3D +.le;~ISOL3D +.br;Calls: (none) +.br;Called by: LINHID +.le;~JPLTAG +.br;Calls: SHADE, PLOT +.br;Called by: * +.le;~LANDMAP +.br;Calls: PLOT +.br;Called by: * +.le;~LCNTR +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, +LGAXS, AXIS, GCONTR, PLOTND, NEWPEN +.br;Called by: * +.le;~LCOEF +.br;Calls: (none) +.br;Called by: LINHID +.le;~LGAXS +.br;Calls: PLOT, SYMBOL, NUMBER +.br;Called by: * +.le;~LGLIN +.br;Calls: PLOT, SYMBOL +.br;Called by: * +.le;~LGRID +.br;Calls: PLOT +.br;Called by: * +.le;~LINE +.br;Calls: PLOT, SYMBOL +.br;Called by: * +.le;~LINHID +.br;Calls: LCOEF, VSRT1, VSRTR, HPLT, CHECK3D, ISOL3D, STAT3D +.br;Called by: LINHID +.le;~LINSEQ +.br;Calls: PRETRP, ARCALC, SMOOTHC, SPISET, ARCSET, ARCPLT +.br;Called by: *, SYMSS +.le;~LNDSEA +.br;Calls: (none) +.br;Called by: BITMAP +.le;~LSPLOT +.br;Calls: FRAME, CTERM, PLOTND, SYMBOL, SCALE, NEWPEN, PLOT +.br;Called by: * +.le;~MATMUL4 +.br;Calls: (none) +.br;Called by: PLOT3D, SYM3D, SYM3DH +.le;~MESH3D +.br;Calls: MESH3DX +.br;Called by: * +.le;~MESH3DX +.br;Calls: SCALE, FRAME, CTERM, VXPT3D, AXIS2, AXIS, PLOT, PLOTND +.br;Called by: *, MESH3D +.le;~MIDC +.br;Calls: (none) +.br;Called by: TRIANGC +.le;~MTV4 +.br;Calls: (none) +.br;Called by: PLOT3D, SYM3D, SYM3DH, XVMUL3D +.le;~MVAX3D +.br;Calls: MVAX3DX +.br;Called by: *, MVAX5D +.le;~MVAX3DX +.br;Calls: SCALE, FRAME, CTERM, PLT3D, HLT3D, AXIS3, PLOT, PLOTND +.br;Called by: *, MVAX3D +.le;~MVAX5D +.br;Calls: SCALE, FRAME, CTERM, RTERM, SYMBOL, NUMBER, MVAX3D, PLOT, +FACTOR, PLOTND +.br;Called by: * +.le;~NEWPAGE +.br;Calls: PPLOT +.br;Called by: * +.le;~NEWPEN +.br;Calls: RMPEN, PPEN +.br;Called by: *, CNDRAW, SHADE, CSHADE, GCONTR +.le;~NEWVCOL +.br;Calls: (none) +.br;Called by: VPLOTS, PLOTVT +.le;~NEWVPEN +.br;Calls: (none) +.br;Called by: VPEN +.le;~NUM3D +.br;Calls: SYM3D +.br;Called by: *, AXIS3D +.le;~NUM3DH +.br;Calls: SYM3DH +.br;Called by: *, AXIS3DH +.le;~NUMBER +.br;Calls: SYMBOL +.br;Called by: *, AXIS, AXIS2, AXIS3, CNDRAW +.le;~NXTVU +.br;Calls: PLOT, NXT0VU, ANXTVU +.br;Called by: *, PLT3D, HLT3D, MVAX3DX, CVAX3DX +.le;~OLDNUMB +.br;Calls: SYMBOL +.br;Called by: * +.le;~NXT0VU +.br;Calls: (none) +.br;Called by: NXTVU +.le;~PAUSE +.br;Calls: INXTCHR +.br;Called by: * +.le;~PAUSEP +.br;Calls: INXTCHR, CTERM +.br;Called by: * +.le;~PFACTOR +.br;Calls: (none) +.br;Called by: *, FACTOR +.le;~PHIST +.br;Calls: FRAME, AXIS, PLOT, SYMBOL, SHADE, RECT, PLOTND, +CTERM +.br;Called by: * +.le;~PICHRT +.br;Calls: FRAME, SYMBOL, PLOT, NEWPEN, CSHADE, SHADE, PLOTND, CTERM +.br;Called by: * +.le;~PLOT +.br;Calls: PLOTVT, PLOTRM, PPLOT, ASTINTER +.br;Called by: *, AXIS, AXIS2, AXIS3, ARROW, BITMAP, CIRCLE, CNDRAW, DASHL, +DARW3D, ELLIPSE, FRACT, GRID, HPLT, JPLTAG, LANDMAP, LGAXS, LGLIN, LGRID, +LINE, NXTVU, PLOTND, PLRAX, PLRLN, PLT3DH, POLARMAP, RECT, SHADE, SYMBOL, +SYMS, SYMSS, TRCELPLT3D, CSHADE +.le;~PLOT3D +.br;Calls: MTV4, ROTEM, MATMUL4, VCPY, DRAW3D, IPCLP3 +.br;Called by: *, AXIS3D, EARTH3D, SYM3D +.le;~PLOTLG +.br;Calls: FRAME, CTERM, NEWPAGE, SCALE, SCALG, LGRID, GRID, PLOT, +LGAXS, AXIS, LINE, LGLIN, PLOTND, SYMBOL, NEWPEN +.br;Called by: * +.le;~PLOTLG2 +.br;Calls: FRAME, CTERM, NEWPAGE, SCALE, SCALG, LGRID, GRID, PLOT, +LGAXS, AXIS, LINE, LGLIN, PLOTND, SYMBOL, NEWPEN +.br;Called by: * +.le;~PLOTLGL +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, +LGAXS, AXIS2, LINSEQ, PLOTND, SYMBOL, NEWPEN +.br;Called by: * +.le;~PLOTLGX +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, +LGAXS, AXIS2, LGLIN, LINE, PLOTND, SYMBOL, NEWPEN +.br;Called by: * +.le;~PLOTND +.br;Calls: PLOT +.br;Called by: * +.le;~PLOTRM +.br;Calls: RMCLEAR, RMPLOT, IPCLIP, RAMCLOSE, CLPIT +.br;Called by: *, PLOT +.le;~PLOTS +.br;Calls: FRAME +.br;Called by: * +.le;~PLOTSC +.br;Calls: FRAME, CTERM, NEWPAGE, SCALE, GRID, LINE, AXIS, PLOT, +LINE, SYMBOL, PLOTND, NEWPEN +.br;Called by: * +.le;~PLOTSC2 +.br;Calls: FRAME, CTERM, NEWPAGE, SCALE, GRID, LINE, AXIS, PLOT, +LINE, SYMBOL, PLOTND, NEWPEN +.br;Called by: * +.le;~PLOTVT +.br;Calls: CTERM, VTPLOT, IPCLIP, NEWVCOL, CLPIT +.br;Called by: *, PLOT +.le;~PLRAX +.br;Calls: PLOT, SYMBOL, CIRCLE +.br;Called by: * +.le;~PLRLN +.br;Calls: PLOT, SYMBOL +.br;Called by: * +.le;~PLT3D +.br;Calls: NXTVU +.br;Called by: *, MVAX3DX, CVAX3DX +.le;~PLT3DH +.br;Calls: PLOT +.br;Called by: *, SYM3DH, AXIS3DH, CUBE, T3DH, TRIG3DH, CNTOUR, HIST3D +.le;~POLARMAP +.br;Calls: PLOT +.br;Called by: * +.le;~POLY1INT +.br;Calls: (none) +.br;Called by: CENCELPLT, CNCELPLT3D +.le;~PPEN +.br;Calls: PPLOTP +.br;Called by: *, NEWPEN +.le;~PPLOT +.br;Calls: PPLOTP, IPCLIP, CLPIT +.br;Called by: *, PLOT +.le;~PPLOTP +.br;Calls: (none) +.br;Called by: NEWMSK, PPEN, PPLOT, PPLOTS +.le;~PPLOTS +.br;Calls: PPLOTP +.br;Called by: FRAME +.le;~PRESPL +.br;Calls: PPLOTP +.br;Called by: *, RESPL +.le;~PRETRP +.br;Calls: SPISET, SPIFUN +.br;Called by: LINSEQ +.le;~PSAVPL +.br;Calls: (none) +.br;Called by: *, SAVPL +.le;~PSUBPRO +.br;Calls: SUBPROC +.br;Called by: * +.le;~PXPCGT +.br;Calls: (none) +.br;Called by: SYMBOL, SYM3D, SYM3DH +.le;~RECT +.br;Calls: PLOT +.br;Called by: * +.le;~RESPL +.br;Calls: PRESPL, RRESPL, VRESPL, WHERE, PLOT +.br;Called by: * +.le;~RFACTOR +.br;Calls: (none) +.br;Called by: *, FACTOR +.le;~RAMOPEN +.br;Calls: SYS$TRANSLOG, SYS$ALLOC, SYS$DALLOC, SYS$DASSGN, SYS$ASSIGN, SYS$QIOW +.br;Called by: RPLOTS +.le;~RAMCLOSE +.br;Calls: SYS$DALLOC, SYS$DASSGN +.br;Called by: PLOTRM +.le;~RAMOUT +.br;Calls: SYS$QIOW +.br;Called by: RMSTART, RMWIND, RMPLOT, RMCLEAR, RMTEXTURE, RMZOOM, +RMPAN, RMSETCUR, RMTEXT, RMFNTSIZE +.le;~RAMOUTIN +.br;Calls: SYS$QIOW +.br;Called by: RMREADCURSOR, RMREADCOL, RMREADBYTE, RMREADWORD +.le;~REFDIS (entry of RAMCLOSE) +.br;Calls: (none) +.br;Called by: * +.le;~RMCLEAR +.br;Calls: RAMOUT +.br;Called by: PLOTRM +.le;~RMDIR +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMFNTSIZE +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMPAN +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMPLOT +.br;Calls: RAMOUT +.br;Called by: PLOTRM +.le;~RAMOUTIN +.br;Calls: SYS$QIOW +.br;Called by: RMREADBYTE, RMREADCOL, RMREADWORD +.le;~RMREADBYTE +.br;Calls: RAMOUTIN +.br;Called by: * +.le;~RMREADCOL +.br;Calls: RAMOUTIN +.br;Called by: * +.le;~RMREADCURSOR +.br;Calls: RAMOUTIN +.br;Called by: * +.le;~RMREADWORD +.br;Calls: RAMOUTIN +.br;Called by: * +.le;~RMSETCUR +.br;Calls: RAMOUT +.br;Called by: CURBAND, CURRECT, CURMOTION, CURLOCATE +.le;~RMRESET +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMSTART +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMTEXT +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMTEXTURE +.br;Calls: RAMOUT +.br;Called by: RMPEN, RPLOTS, FIXRM0, RRESPL +.le;~RMWIND +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMWRITEBYTE +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMWRITECOL +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMWRITEWORD +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMZOOM +.br;Calls: RAMOUT +.br;Called by: * +.le;~RMPEN +.br;Calls: RMTEXTURE +.br;Called by: NEWPEN +.le;~ROTEM +.br;Calls: (none) +.br;Called by: AXIS3D, INIT3D, PLOT3D, SYM3D, SYM3DH +.le;~RPLOTS +.br;Calls: PLOTRM, RMTEXTURE +.br;Called by: FRAME +.le;~RRESPL +.br;Calls: RMTEXTURE +.br;Called by: *, RESPL +.le;~RSAVPL +.br;Calls: (none) +.br;Called by: *, SAVPL +.le;~RTERM +.br;Calls: RMCLEAR, RAMCLOSE, RAMOPEN +.br;Called by: * +.le;~RVXPT3D +.br;Calls: (none) +.br;Called by: CNCELPLT3D +.le;~SAVPL +.br;Calls: PSAVPL, RSAVPL, VSAVPL, WHERE, PLOT +.br;Called by: * +.le;~SCALE +.br;Calls: (none) +.br;Called by: * +.le;~SCALG +.br;Calls: (none) +.br;Called by: * +.le;~SCATPL +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, LGAXS, +AXIS, PLOT, SYMBOL, PLOTND +.br;Called by: * +.le;~SEGCODE +.br;Calls: (none) +.br;Called by: CNCELPLT, CNCELPLT3D +.le;~SEISPL +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, LGAXS, +AXIS, PLOT, NEWPEN, SYMBOL, PLOTND +.br;Called by: * +.le;~SFPLOT +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, LGAXS, +AXIS, PLOT, NEWPEN, SYMBOL, PLOTND +.br;Called by: * +.le;~SHADE +.br;Calls: PLOT, NEWPEN +.br;Called by: *, JPLTAG +.le;~SKETCH +.br;Calls: LINHID +.br;Called by: * +.le;~SMOOTHC +.br;Calls: CHLSKYS +.br;Called by: LINSEQ +.le;~SPIDER +.br;Calls: (none) +.br;Called by: ARCPLT +.le;~SPIFUN +.br;Calls: (none) +.br;Called by: ARCPLT, PRETRP +.le;~SPISET +.br;Calls: (none) +.br;Called by: LINSEQ, PRETRP +.le;~SPLOTS +.br;Calls: SPLOTSX +.br;Called by: * +.le;~SPLOTSX +.br;Calls: FRAME, CTERM, NEWPAGE, SCALG, SCALE, LGRID, GRID, +LGAXS, AXIS2, PLOT, SYMBOL, PLOTND +.br;Called by: *, SPLOTS +.le;~SPRECT1 +.br;Calls: (none) +.br;Called by: EARTH3D +.le;~STAT3D +.br;Calls: (none) +.br;Called by: LINHID +.le;~STAT3D2 +.br;Calls: (none) +.br;Called by: LINHID +.le;~SUBPROC +.br;Calls: LIB$SPAWN, LIB$SIGNAL +.br;Called by: PSUBPRO +.le;~SYM3D +.br;Calls: PLOT3D, ROTEM, MATMUL4, MTV4, PXPCGT +.br;Called by: *, AXIS3D, NUM3D +.le;~SYM3DH +.br;Calls: MTV4, PLT3DH, PXPCGT, ROTEM, MATMUL4 +.br;Called by: *, NUM3DH, AXIS3DH +.le;~SYMBOL +.br;Calls: PLOT, PXPCGT +.br;Called by: *, AXIS, AXIS2, AXIS3, CNDRAW, DASHL, LGAXS, LGLIN, LINE, +NUMBER, OLDNUM, PLRAX +.le;~SYMS +.br;Calls: PLOT +.br;Called by: * +.le;~SYMSS +.br;Calls: PLOT, LINSEQ +.br;Called by: * +.le;~TR3DH +.br;Calls: SCALE, FRAME, CTERM, AXIS3DH, PLT3DH, SKETCH, PLOT, +PLOTND, INIT3DH +.br;Called by: * +.le;~TRCELPLT3D +.br;Calls: RVXPT3D, PLOT, ISEGCODE +.br;Called by: CNT3DX +.le;~TRIANGC +.br;Calls: MIDC +.br;Called by: *, CNTLN, TRIG3DH +.le;~TRIG3DH +.br;Calls: SCALE, FRAME, CTERM, AXIS3DH, PLT3DH, SKETCH, PLOT, +PLOTND, INIT3DH +.br;Called by: * +.le;~VAX3D +.br;Calls: VAX3DX +.br;Called by: *, VAX5D +.le;~VAX3DX +.br;Calls: SCALE, FRAME, CTERM, VXPT3D, AXIS2, AXIS, PLOT, INTERSECT, +PLOTND +.br;Called by: *, VAX3D +.le;~VAX5D +.br;Calls: SCALE, FRAME, CTERM, RTERM, SYMBOL, NUMBER, VAX3D, PLOT, +FACTOR, PLOTND +.br;Called by: * +.le;~VCPY +.br;Calls: (none) +.br;Called by: PLOT3D +.le;~VFACTOR +.br;Calls: (none) +.br;Called by: *, FACTOR +.le;~VPEN +.br;Calls: NEWVPEM +.br;Called by: NEWPEN +.le;~VPLOTS +.br;Calls: PLOTVT, NEWVPEN, NEWVCOL +.br;Called by: FRAME +.le;~VRESPL (entry of VSAVPL) +.br;Calls: NEWVPEN, PLOTVT +.br;Called by: *, SAVPL +.le;~VSAVPL +.br;Calls: (none) +.br;Called by: *, SAVPL +.le;~VSRT1 +.br;Calls: (none) +.br;Called by: LINHID +.le;~VSRTR +.br;Calls: (none) +.br;Called by: LINHID +.le;~VTPLOT +.br;Calls: (none) +.br;Called by: CURRECT, PLOTVT +.le;~VXPT3D +.br;Calls: (none) +.br;Called by: CNT3DX, VAX3DX, MESH3DX +.le;~WHERE +.br;Calls: WHEREVT, WHERERM, WHEREPR +.br;Called by: *, SAVEPL, RESPL +.le;~WHERE3D +.br;Calls: (none) +.br;Called by: * +.le;~WHERE3H +.br;Calls: (none) +.br;Called by: * +.le;~WHEREPR +.br;Calls: (none) +.br;Called by: *, WHERE +.le;~WHERERM +.br;Calls: (none) +.br;Called by: *, WHERE +.le;~WHEREVT +.br;Calls: (none) +.br;Called by: *, WHERE +.le;~XFRM3D +.br;Calls: (none) +.br;Called by: * +.le;~XVMUL3D +.br;Calls: MTV4 +.br;Called by: AXIS3D +.els + +.pg +.hl 1 Common Block Names +.p +The following is a list of all the named common block used internally +by the LONGLIB graphics library. Those marked with an asterick are documented +under the first listed routine. +and are designed to be accessable to the user. Those +unmarked are for internal use only and may change at later revisions. + +.ls1 +.dle,,'.' +.le;~VT100 -- Accessed by: BITCURSOR, CURMOTION, CURLOCATE, CURBAND, CURRECT, +GETCURSOR, FRAME, VTPLOTS, VTPLOT, CTERM, PLOTVT, WHEREVT, +VFACTOR, FACTOR, FIXVT0, WHERE, VSAVPL, VRESPL, NEWVPEN, NEWVCOL +.le;~RMTEK -- Accessed by: CURMOTION, CURLOCATE, CURBAND, CURRECT, FRAME, +PLOTRM, RPLOTS, IRMCHAN, WHERERM, RFACTOR, RMPEN, FACTOR, +FIXRM0, WHERE, RSAVPL, RRESPL +.le;~PXPCOM -- Accessed by: FRAME, PPLOT, WHEREPR, PFACTOR, +PPLOTS, PPEN, FACTOR, FIXPR0, WHERE, PSAVPL, PRESPL +.le;~RAMTEKIO -- Accessed by: RAMOPEN, RAMOUT, RAMOUTIN, RMCLEAR +.le;~CHIDE -- Accessed by: INIT3DH, PLT3DH, WHERE3H, SKETCH, LINHID +.le;~HEDG -- Accessed by: LINHID, CHECK3D +.le;~GO3 -- Accessed by: LCOEF, LINHID, STAT3D, STAT3D2, CHECK3D, ISOL3D +.le;~GO * -- Accessed by: LINHID +.le;~DAVE -- Accessed by: CHECK3D, ISOL3D, STAT3D2 +.le;~LSTPLT -- Accessed by: PLOT, WHERE +.le;~PLT3B * -- Accessed by: PLT3D, HLT3D, CNDRAW, MVAX3DX, CVAX3DX +.le;~LAST3D -- Accessed by: DRAW3D, WHERE3D +.le;~CPLOT3D -- Accessed by: INIT3D, PLOT3D +.le;~CGLPLOT * -- Accessed by: GLPLOT +.le;~CPLOTLG * -- Accessed by: PLOTLG +.le;~CPHIST * -- Accessed by: PHIST +.le;~CPLOTSC * -- Accessed by: PLOTSC +.le;~CPLOTSC2 * -- Accessed by: PLOTSC2 +.le;~LOCATE -- Accessed by: VXPT3D, VAX3DX, CNT3DX, RVXPT3D, MESH3DX +.le;~CPLOTLG * -- Accessed by: PLOTLG +.le;~CPLOTLG2 * -- Accessed by: PLOTLG2 +.le;~CPLOTLGL * -- Accessed by: PLOTLGL +.le;~CPLOTLGX * -- Accessed by: PLOTLGX +.le;~CCNTRPLT * -- Accessed by: CNTRPLT, CNTLN, LCNTR +.le;~CSPLOTS * -- Accessed by: SPLOTS +.le;~CSPLOTSX * -- Accessed by: SPLOTSX, SPLOTS +.le;~CSEISPL * -- Accessed by: SEISPL +.le;~CSCATPL * -- Accessed by: SCATPL +.le;~TT_IO -- Accessed by: INXTCHR, ICHRCHK +.le;~ASTC -- Accessed by: ASTINTER, ENAST, ASTEXIT, ENABLEAST, PLOT +.els + + + +.chapter Plot Examples and Plotting Symbols +.p +Shown in the sections that follow are outputs (and listings) of various +programs included with LONGLIB. This include programs which produce +plotting symbols and line types/widths. + +.hl1 Plotting Symbols and Character Fonts Examples +.x SYMBOLS +.x SYMS +.x SYMSS +.p +The program ~SYMBOLS was used to create a table of the +available plotting symbols and character fonts available using the +subroutines SYMBOLS, SYMS and SYMSS. These tables are shown on the +succeeding pages. A listing of SYMBOLS follows the tables. + +.pg +.hl1 Line Type/Width Examples +.x line type +.x line width +.x color +.p +The program ~LINETYPE was to create a table of the available line types, +widths, and colors for each plotting device. These are shown on the +succeding pages. A listing of LINETYPE follows the tables. + +.pg +.hl1 MASTER Routine Output Examples +.p +The program ~PLOTTESTS was used to obtain examples of some of the MASTER +routine outputs. A listing follows the output pages. + +.pg +.hl1 3-d Routine Output Examples +.p +EXAMP3D and EXAMP3DH demonstrate the 3d routines while WORLD demonstrates +the some of the 3d map capabilities. Output and listings follow. + +.pg +.hl1 Cursor Routine Test Program +.p +A listing of the program ~CURTEST follows. The program can be used +to test the operation of the graphics input cursor routines. Only a listing +is given. + +.pg +.hl1 REF Output Example +.p +This section describes an example of how the Ramtek REF subpackage can +be used to produce a grey scale "image". An example of the output image +produced by first running the example program REFTEST, outputing the result to +a REF file, then using the program ~REFLAS to produce a grey scale +image on the ~QMS laser printer. A listing of the ~REFTEST program +is also provided. Note that REFTEST must be linked to the REF version +of the library (LONGLIBR) rather than the "normal" version. Also +note that REFTEST, when linked to the "normal" LONGLIB, will produce +a color image on the Ramtek display. + +.! FOR VAX VMS 3.x REMOVE THE "!" FROM THE NEXT LINE +.!do index +.chapter INDEX +.pg diff --git a/samples/RUNOFF/mcp_help.rnh b/samples/RUNOFF/mcp_help.rnh new file mode 100644 index 00000000..3e74f780 --- /dev/null +++ b/samples/RUNOFF/mcp_help.rnh @@ -0,0 +1,1773 @@ +.!++ +.! +.! Copyright (c) 2008, Matthew Madison. +.! Copyright (c) 2012, Endless Software Solutions. +.! +.! All rights reserved. +.! +.! Redistribution and use in source and binary forms, with or without +.! modification, are permitted provided that the following conditions +.! are met: +.! +.! * Redistributions of source code must retain the above +.! copyright notice, this list of conditions and the following +.! disclaimer. +.! * Redistributions in binary form must reproduce the above +.! copyright notice, this list of conditions and the following +.! disclaimer in the documentation and/or other materials provided +.! with the distribution. +.! * Neither the name of the copyright owner nor the names of any +.! other contributors may be used to endorse or promote products +.! derived from this software without specific prior written +.! permission. +.! +.! THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +.! "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +.! LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +.! A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +.! OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +.! SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +.! LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.! DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.! THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.! (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +.! OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.! +.! NAME: MCP_HELP.RNH +.! +.! ABSTRACT: MCP help file. +.! +.! FACILITY: MX Control Program +.! +.! DESCRIPTION: +.! +.! This is the RUNOFF source for the help library for MCP. +.! To create the help library, use the following commands: +.! +.! $ RUNOFF MCP_HELP.RNH +.! $ LIB/CREATE/HELP MCP_HELPLIB MCP_HELP +.! +.! MODIFICATION HISTORY: +.! +.! 30-SEP-1990 V1.3 Madison Update for MX V1.3. +.! 04-OCT-1990 V1.3-1 Madison Further file server-related changes. +.! 05-DEC-1990 V2.1 Madison Add SET JNET. +.! 10-DEC-1990 V2.1-1 Madison New qualifiers for DEFINE LIST. +.! 12-DEC-1990 V2.1-2 Madison One more DEFINE LIST qualifier. +.! 11-FEB-1991 V2.2 Madison Various new command options. +.! 27-MAR-1991 V2.2-1 Madison Mention SHUT SMTP. +.! 07-NOV-1991 T2.4 Madison New commands. +.! 11-NOV-1991 T2.4-1 Madison Forgot QUEUE SHOW. SET JNET/LENIENT. REVIEW. +.! 05-DEC-1991 V3.0 Madison SHOW VERSION. +.! 03-JAN-1992 V3.0-1 Madison DEFINE LIST/REPLY_TO wasn't correct. +.! 14-FEB-1992 V3.1 Madison SET JNET/USERNAME. +.! 05-MAR-1992 V3.1-1 Madison SHUTDOWN, RESET changes. STATUS. +.! 13-MAR-1992 V3.1-2 Madison Forgot SET X25_SMTP. +.! 15-FEB-1993 V3.2 Goatley DEFINE LIST/FILE changes, fix typos. +.! 19-MAR-1993 V3.3 Goatley DEFINE LIST/PRIVATE, QUEUE SHOW/BRIEF. +.! 16-APR-1993 V3.3-1 Goatley SET LOCAL/MULTIPLE_FROM. +.! 7-AUG-1993 V3.4 Goatley Fix missing double "_" in qualifiers. +.! 29-AUG-1993 V3.4-1 Goatley SET LOCAL/MM_DELIVER. +.! 17-DEC-1993 V3.4-2 Goatley DEFINE LIST/STRIP=OTHER, SET LOCAL/CC. +.! 10-JAN-1994 V3.4-3 Goatley DEF LIST/CASE, - Q RECLAIM, + Q SYNCH. +.! 16-FEB-1994 V4.0 Goatley QUEUE CREATE, QUEUE EXTEND. +.! 10-DEC-1995 V4.2 Goatley /NODE, /DIGEST. +.! 7-OCT-1996 V4.3 Goatley SPAWN. +.! 14-JAN-1997 V4.4 Madison SET MLF. +.! 17-FEB-1997 V4.5 Madison DEFINE/MODIFY/REMOVE/SHOW REJECTION. +.! 02-APR-1997 V4.6 Madison LOCAL_DOMAIN, SMTP/RELAY, LIST/RECIP/HIDE. +.! 13-APR-1997 V4.6-1 Madison SET MLF/DELAY_DAYS. +.! 2-MAY-1997 V4.7 Goatley Added DEF LIST/XHEADERS, /LIST_HEADERS, /HOSTNAME +.! 5-MAY-1997 V4.7-1 Goatley Added DEF LIST/SETTINGS. +.! 4-AUG-1997 V4.7-2 Goatley Add REJECTION to SHOW. +.! 8-SEP-1997 V4.7-2 Goatley Add multiple addrs to DEFINE ALIAS. +.! 3-OCT-1997 V4.7-3 Goatley Add /CC_POST_ERRORS, /SUBJECT_PREFIX. +.! 05-OCT-1997 V4.7-4 Madison Removed REJECTION due to inclusion of REJMAN utility; +.! added SET SMTP/VALIDATE_SENDER_DOMAIN. +.! 29-OCT-1997 V4.7-5 Goatley Fix /LIST_HEADERS description. +.! 21-NOV-1997 V4.7-6 Goatley Add /QP_DECODE to SET LOCAL. +.! 19-APR-1998 V4.7-7 Madison Add SET LOCAL/DISABLE_EXQUOTA; remove /MM_DELIVER. +.! 24-APR-1998 V4.8 Madison Add SET SMTP/RBL, SET ROUTER/ACC. +.! 15-JUN-1998 V4.9 Madison Add INSIDE_NETWORK_ADDRESS settings. +.! 26-JUN-1998 V4.9-1 Madison Add /RELAY_ALLOWED to DEFINE INSIDE. +.! 03-AUG-1998 V4.9-2 Madison REMOVE INSIDE_NETWORK_ADDRESS was missing. +.! 15-AUG-1998 V4.9-3 Madison Document /RBL_CHECK=domain-name; add MODIFY INSIDE. +.! 27-AUG-1998 V4.9-4 Madison New HOLDING_QUEUE paths. +.! 30-JAN-2000 V4.9-5 Madison More holding queues. +.! 25-NOV-2000 V4.9-6 Madison list ignore flags; remove Jnet support; set local/long. +.! 22-DEC-2000 V4.10 Madison SHOW LIST/BRIEF. +.! 13-JAN-2001 V4.11 Madison QUEUE SELECT. +.! 14-FEB-2002 V4.12 Madison SET SMTP/[NO]PERCENT, regex, QUEUE DUMP. +.! 03-Feb-2008 V5.0 Madison Cleanup of obsolete keywords. +.! 12-Mar-2012 V5.1 Sneddon SET SMTP/[NO]TLS. +.!-- +.P0 +.AP +.LM1 +.RM70 +.I-1 +1 @ + @ + You can create MCP command files and execute them with the "@" +(input-indirection) function. +.NJ + Format: + @ file-spec +.J + You can use the command SHOW/OUTPUT=file/COMMAND ALL to create a command +file out of the current MX configuration, edit it outside of MCP, and then +load in the commands with @file to create a new MX configuration. +.I-1 +1 ADD + See the help text for ADD USER. +.I-1 +2 USER + ADD USER adds a username and password to the authentication database +used by the SMTP server. +.NJ + Format: + ADD USER username +.J + A username may be up to 16 characters in length, and are case-sensitive. +Use quotation marks to specify a username that contains lower-case letters. +.I-1 +3 Qualifiers +.I-1 +/PASSWORD + /PASSWORD=password-text + Specifies a password for this username. The password may be up to 64 +characters in length, and may contain any characters. To specify lower case +letters or blanks in the password, surround it with quotation marks. + If this qualifier is omitted, a default password, "PASSWORD", is assigned +to the username. +.I-1 +1 CREATE + See the help text for CREATE USER__DATABASE__FILE. +.I-1 +2 USER__DATABASE__FILE + The CREATE USER__DATABASE_FILE command creates an empty file for the SMTP +authentication database. This database is used in conjunction with the +CRAM-MD5 authentication extension (see SET SMTP/AUTHENTICATION). +.NJ + Format: + CREATE USER__DATABASE__FILE [file-spec] +.J + If a file-spec is omitted, a new (empty) version of MX__DIR:MX__USERAUTH__DB.DAT, the +standard location for the SMTP authentication database, is created. In general, +this command is used only once, to create the initial database for population using +the ADD USER command. +.I-1 +1 DEFINE + The DEFINE command is used to add new alias and path entries, +new rewrite-rules, mailing lists, and file servers, as well as identify +privileged users. +.I-1 +2 ALIAS + DEFINE ALIAS adds a new alias definition to the alias list. The +new alias always goes at the end of the list. +.NJ + Format: + DEFINE ALIAS alias real-address[,...] +.J + Real-address must be a full address, not just a username. Alias +matching is case-insensitive. If case is important in the substitution, +place quotation marks around real-address. + The maximum size of the real-address (including all addresses, if multiple +real-addresses are specified) is 255 characters. +.I-1 +2 FILE__SERVER + DEFINE FILE__SERVER is used to create a file server. +.NJ + Format: + DEFINE FILE__SERVER name +.J + The name given must be 32 characters or less in length, and should not +be the same as an existing username or mailing list. +.I-1 +3 Qualifiers +.I-1 +/BEGIN__SEND__PERIOD + /BEGIN__SEND__PERIOD=hh:mm + This qualifier identifies the hour of the day when the off-peak sending +period begins. It is only meaningful when a delay threshold is specified. +The default send period begins at 17:00. +.I-1 +/DELAY__THRESHOLD + /DELAY__THRESHOLD=size + /NODELAY__THRESHOLD + This qualifier identifies the largest size, in bytes, that a file service +response can be to be sent during prime time. Responses exceeding that size +are delayed until the off-peak sending period. /NODELAY__THRESHOLD lets +responses of any size be sent at any time. Omitting "size" sets a default +size of 16,384 bytes. +.I-1 +/DESCRIPTION + /DESCRIPTION=text + /NODESCRIPTION (default) + The /DESCRIPTION qualifier defines a brief description for the file server. +This description is added to the file server address in the +X-FileServer header on outgoing file server messages. +.I-1 +/END__SEND__PERIOD + /END__SEND__PERIOD=hh:mm + This qualifier identifies the hour of the day when the off-peak sending +period ends. It is only meaningful when a delay threshold is specified. +The default send period ends at 09:00. +.I-1 +/HOST__LIMIT + /[NO]HOST__LIMIT=n + This qualifier specifies a daily per-host byte count limit on requests +to the file server. If a requested file's size plus the current byte +count exceeds the daily limit, the file is not sent. This limit is +kept on a per-host basis. +.I-1 +/MAILING__LIST + /[NO]MAILING__LIST=list-name + This qualifier specifies that only those users who subscribe to the +specified mailing list (which must be a list on the local system) may +have access to the file server. +.I-1 +/MANAGER + /MANAGER=address + The /MANAGER qualifier identifies the address to which file service management +requests are forwarded (when sent to user {file-server-username}-Mgr). +If omitted, Postmaster on the local system is used. +.I-1 +/ROOT + /ROOT=root-spec + The /ROOT qualifier identifies the root for the file server. Root-spec +must be a rooted logical name or a device and root directory specification. +.I-1 +/SERVER__LIMIT + /[NO]SERVER__LIMIT=n + This qualifier specifies a daily server byte count limit on requests +to the file server. If a requested file's size plus the current byte +count exceeds the daily limit, the file is not sent. This limit applies +to all requests to the server. +.I-1 +/USER__LIMIT + /[NO]USER__LIMIT=n + This qualifier specifies a daily per-user byte count limit on requests +to the file server. If a requested file's size plus the current byte +count exceeds the daily limit, the file is not sent. This limit is +kept on a per-destination-user basis. +.I-1 +2 INSIDE__NETWORK__ADDRESS + The DEFINE INSIDE__NETWORK__ADDRESS command establishes an IP address or +network that is in one of the local domains, is permitted to use your SMTP +server as a relay, or to reject a particular host or network from being +considered as part of your local domain. +.NJ + Format: + DEFINE INSIDE__NETWORK__ADDRESS ip-address +.J + Inside network address definitions are only used with the SMTP server +is set to disallow relays with SET SMTP/NORELAY__ALLOWED. When at least +one inside address is defined, messages coming in via SMTP are allowed +to have recipients outside of the local domain(s) only if the sending +system's IP address is on the inside network address list. + By default, the SMTP server will still reject a message that contains +non-local addresses for both the sender and the receiver, even from +hosts on the inside network address list. You can ease that restriction +with the /RELAY__ALLOWED qualifier. +.I-1 +3 ip-address + IP address, in dotted-decimal form, of the host or network. If this is +a network address, you must also specify the /NETMASK qualifier. +.I-1 +3 Qualifiers +.I-1 +/NETMASK + /NETMASK=ip-netmask + Specifies the network mask to be applied to the address, in dotted-decimal +form. The default is 255.255.255.255, which indicates that the IP address +is for a host, not a network. +.I-1 +/REJECT + /REJECT + /NOREJECT (default) + Indicates whether relay is to be rejected from the specified +host or network. This qualifier can be used to reject SMTP relay +from particular hosts or subnetworks that are below a parent network +that is already on the inside network address list. +.I-1 +/RELAY__ALLOWED + /RELAY__ALLOWED + /NORELAY__ALLOWED (default) + Indicates that the host(s) should be allowed full relay permission; that +is, messages sent from the host(s) are allowed to contain non-local addresses +for both sender and receiver. + This qualifier is useful when your system is acting as a central mail hub, +and there are hosts on your local network that automatically forward messages +for their local users to hosts outside your domain via an alias. When such +messages are sent back to your system (as the mail hub), they will contain +non-local addresses for both the sender and the recipient. +.I-1 +2 LIST + The DEFINE LIST command is used to create a mailing list. +.NJ + Format: + DEFINE LIST listname +.J + DEFINE LIST creates three addresses on the local system: the mailing list +itself, a control address (listname-REQUEST), and a sender address +(listname-SENDER). +.I-1 +3 Qualifiers +.I-1 +/ADD__MESSAGE + /ADD__MESSAGE=fspec + /NOADD__MESSAGE (default) + The /ADD__MESSAGE qualifier is used to specify a file whose contents +are to be sent when a user subscribes to the list. If you omit +the device and directory parts of the file specification, they default +to MX__MLIST__DIR. If you omit the file type, it defaults to TXT. + If no add message is specified, the system default add message, contained +in file MX__MLIST__DIR:MLIST__ADD__MESSAGE.TXT, is used. +.I-1 +/ARCHIVE + /ARCHIVE=fspec + /NOARCHIVE (default) + The /ARCHIVE qualifier is used to establish a file into which mailing list +messages are archived. You may specify just parts of a file specification, +to allow the following defaults to take effect: +.NJ + Device, directory: MX__MLIST__DIR: + File name: same as mailing list name + File type: yyyy-mm (four-digit year, a hyphen, two-digit month) +.J + This setup allows for easy monthly disposal of the mailing list archives. +.I-1 +/CASE__SENSITIVE + /CASE__SENSITIVE (default) + /NOCASE__SENSITIVE + Enables or disables case-sensitivity with regard to mailing list +subscribers. By default, MX treats the left-hand side of subscriber +addresses in a case-sensitive manner with regard to SIGNOFF and SET +commands. If a list is defined /NOCASE__SENSITIVE, then the case of +subscriber addresses will be ignored. +.I-1 +/CC__POST__ERRORS + /CC__POST__ERRORS + /NOCC__POST__ERRORS (default) + Enables or disables copying mailing post failure messages to the /ERRORS__TO +address. By default, if a message cannot be forwarded to a list, an error +message is sent back to the sender of the message. If /CC__POST__ERRORS +is set, those error messages are also sent to the /ERRORS__TO address. +This lets the list owner see attempted posts from non-subscribers and other +posting failures. +.I-1 +/CONFIRMATION__MESSAGE + /CONFIRMATION__MESSAGE=fspec + /NOCONFIRMATION__MESSAGE (default) + The /CONFIRMATION__MESSAGE qualifier is used to specify a file whose contents +are to be sent when the mailing list processor requests confirmation of +a subscription request (see DEFINE LIST /REQUEST__CONFIRMATION). If you omit +the device and directory parts of the file specification, they default +to MX__MLIST__DIR. If you omit the file type, it defaults to TXT. + If the NO form is specified, the system default confirmation message, contained +in file MX__MLIST__DIR:MLIST__CONFIRM__MESSAGE.TXT, is used. +.I-1 +/DESCRIPTION + /DESCRIPTION=text + /NODESCRIPTION (default) + The /DESCRIPTION qualifier defines a brief description for the +mailing list. This description is added to the mailing list address in the +X-Listname header on outgoing mailing list messages. +.I-1 +/DIGEST + /DIGEST + /NODIGEST (default) + The /DIGEST qualifier enables or disables the support for digest subscribers +for the given mailing list. +.I-1 +/ERRORS__TO + /ERRORS__TO=address + This qualifier identifies the address that messages sent to the +listname-SENDER sending address (which are usually delivery error messages) +are sent. If omitted, the first owner specified with /OWNER will be +used. +.I-1 +/FORWARD__MESSAGE + /FORWARD__MESSAGE=fspec + /NOFORWARD__MESSAGE (default) + The /FORWARD__MESSAGE qualifier is used to specify a file whose contents +are to be sent when the list is set to no E (enroll) access for WORLD and +a user attempts to subscribe to the list. The message should inform the +user that the subscription request was forwarded to the mailing list's +owner. If you omit the device and +directory parts of the file specification, they default to MX__MLIST__DIR. +If you omit the file type, it defaults to TXT. + If no forward-to-owner message is specified, the system default message, +contained in file MX__MLIST__DIR:MLIST__FORWARD__MESSAGE.TXT, is used. +.I-1 +/HIDE__ERRORS__TO + /HIDE__ERRORS__TO (default) + /NOHIDE__ERRORS__TO + The /HIDE__ERRORS__TO qualifier instructs MLF to hide the error-returns +address in outbound messages to the mailing list, even when the return +address is specified with /ERRORS__TO. When /HIDE__ERRORS__TO is set on +a list, MLF uses the automatically-created owner-{listname} alias as +the envelope FROM and Errors-To address in outbound list messages. +This is the default setting. + If you have set up a special address or alias for receiving mailing +list-related error messages, and the address can be externally visible, +you should specify that address with the /ERRORS__TO qualifier and +specify /NOHIDE__ERRORS__TO to have the address you specify +appear in the envelope FROM and Errors-To headers. +.I-1 +/HOSTNAME + /HOSTNAME=hostname + /NOHOSTNAME (default) + The /HOSTNAME qualifier instructs MLF to use the supplied hostname +for all addresses generated by MLF for the mailing list. The supplied +hostname is used instead of the actual running host's name. + For example, specifying /HOSTNAME="YYZ.COM" will cause all MLF-generated +mailing list addresses to include "@YYZ.COM" instead of the actual host name. +It is assumed that MX has been properly configured to handle mail addressed +using the supplied hostname (i.e., that MX records for YYZ.COM point to +the node running MX, and that it recognizes that YYZ.COM is a LOCAL path, +etc.). +.I-1 +/IGNORE + /IGNORE=(keyword[=value],...) + The /IGNORE qualifier instructs MLF to ignore postings to the mailing list +if they match the specified criteria. The criteria keywords are +MISSING__LIST__ADDRESS and JUNK__MAIL. These keywords are negatable. By default, +no postings are ignored. + Specifying the MISSING__LIST__ADDRESS criterion causes MLF to ignore +postings to the list that do not explicitly include the list's address in either +the To: or CC: header of the message. This keyword does not take a value. + Specifying the JUNK__MAIL criterion causes MLF to ignore postings that +contain the X-Junk-Mail-Rating: header that is inserted by the heuristic +junk-mail filter in the SMTP server. This keyword takes a value: LOW, +MEDIUM, or HIGH, corresponding to the confidence level of the likelihood +that the message is junk mail, as entered in the +X-Junk-Mail-Rating: header by the SMTP server. Only those messages with +the specified or higher rating are ignored; i.e., if MEDIUM is specified +as the keyword value, only those messages with MEDIUM or HIGH ratings are +ignored. + +.I-1 +/LIST__HEADERS + /LIST__HEADERS=(keyword=value[,...]) + /NOLIST__HEADERS (default) + The /LIST__HEADERS qualifier instructs MLF to include or omit special +List-* headers that provide URLs for subscribing to a list, +unsubscribing from a list, and getting help for that list. + There are three valid keywords: SUBSCRIBE, UNSUBSCRIBE, and HELP. +All three accept values that are used in the creation of the actual headers, +which will be added to each message posted to the mailing list. However, +only HELP requires a value. If the value is omitted for SUBSCRIBE and +UNSUBSCRIBE, the proper URLs for those actions will be automatically generated +by MLF. + Clients that support these headers (both X-List-* and List-*) will provide +click buttons to perform the specified actions (usually "mailto" URLs). +.I-1 +/MAXIMUM__MESSAGE__SIZE + /MAXIMUM__MESSAGE__SIZE=size-in-Kbytes + /NOMAXIMUM__MESSAGE__SIZE (default) + Specifies a limit on the size of a message posted to the list, expressed +in kilobytes. Messages with contents (excluding headers) that exceed the +specified limit are rejected and returned to sender. + Specifying zero as the value is identical to specifying /NOMAXIMUM__MESSAGE__SIZE. +.I-1 +/NOTIFY + /NOTIFY=(type,...) + /NONOTIFY (default) + Specifies that the owner(s) of the mailing list should be sent a +notification message for control transactions. Valid type keywords are +ALL (for all transaction types), ADD, REMOVE, REQUEST, and SET. + By default, no owner notifications are sent. +.I-1 +/OWNER + /OWNER=(address[,...]) + The /OWNER qualifier identifies the address(es) of the owner(s) of the +mailing list. Messages coming to the mailing list or the listname-REQUEST +control address will be granted OWNER access to the mailing list. +.I-1 +/PRIVATE + /PRIVATE + /NOPRIVATE (default) + The /PRIVATE qualifier is used prevent a list from being displayed in +response to a LIST command sent to ListServ. The list protection mask +is not affected by this qualifier. +.I-1 +/PROTECTION + /PROTECTION=(class:code[,...]) + This qualifier allows you to grant or deny certain types of access to +various users. The protection code is of the same form as a normal VMS +file protection specification. + "Class" can be one of SYSTEM, OWNER, GROUP, or WORLD. The SYSTEM class +includes only those addresses identified as system users with DEFINE +SYSTEM__USERS. The OWNER class includes only the owners of the mailing list. +The GROUP class consists of the subscribers of the mailing list. The WORLD +class consists of those addresses that are not subscribers of the mailing +list. + "Code" can consist of the letters R,W,E, and D. R (Read or Review) access +allows the user to request a listing of the addresses on the mailing list +with the REVIEW command. W (Write) access allows the user to send a message +to the mailing list. E (Execute) access allows the user to use the automatic +subscription facility to subscribe to the mailing list (meaningful only for +the WORLD class, of course). D (Delete) access allows the user to use the +automatic subscription facility to sign off the mailing list (meaningful only +for the GROUP class). + If E access is denied to WORLD, subscription requests are forwarded to the +mailing list owner(s). If D access is denied to GROUP, signoff requests +are forwarded to the mailing list owner(s). + Note that protection codes are checked just like VMS protection codes, +so that you cannot grant some kind of access to WORLD and exclude that +access from GROUP, SYSTEM, or OWNER. Also, SYSTEM and OWNER classes are +granted CONTROL access implicitly (just as with VMS file protection), which +allows them to add and remove other users from the mailing list. +.I-1 +/RECIPIENT__MAXIMUM + /RECIPIENT__MAXIMUM=DEFAULT (default) + /RECIPEIENT__MAXIMUM=count + /NORECIPIENT__MAXIMUM + The /RECIPIENT__MAXIMUM qualifier controls how the mailing list +processor sets the maximum number of recipients per outbound message +for the list. The default setting is DEFAULT, which causes the +mailing list processor to set the maximum number based on the +SET MLF/RECIPIENT__MAXIMUM setting. You may override the SET MLF +default by specifying a number, or by specifying /NORECIPIENT__MAXIMUM, +which prevents MLF from breaking up long lists of recipients into +smaller chunks for this list. +.I-1 +/REMOVE__MESSAGE + /REMOVE__MESSAGE=fspec + /NOREMOVE__MESSAGE (default) + The /REMOVE__MESSAGE qualifier is used to specify a file whose contents +are to be sent when a user signs off of the list. If you omit +the device and directory parts of the file specification, they default +to MX__MLIST__DIR. If you omit the file type, it defaults to TXT. + If no removal message is specified, the system default removal message, +contained in file MX__MLIST__DIR:MLIST__REMOVE__MESSAGE.TXT, is used. +.I-1 +/REPLY__TO + /REPLY__TO=(kwd[,...]) + Specifies how the mailing list processor should handle Reply-To headers. +Available reply-to types are SENDER and LIST, which may be combined. +The default is +SENDER, which prevents the mailing list processor from modifying the headers. +If LIST is specified, a Reply-To header is added to list messages to re-direct +replies to the mailing list, eliminating any existing Reply-To header in the +original message. If LIST and SENDER are both specified, a Reply-To header +containing both the mailing list address and the original Reply-To address +is added to list messages (using the From address if no Reply-To header +existed in the original message). +.I-1 +/REQUEST__CONFIRMATION + /REQUEST__CONFIRMATION[=INTERVAL=delta-time] + /NOREQUEST__CONFIRMATION (default) + The /REQUEST__CONFIRMATION qualifier is used to specify whether or not +the mailing list processor should request confirmation of a subscription +request from a user being added to a list via the SUBSCRIBE or ADD list +processor command. By default, confirmations are not requested. + You can control the length of time that the mailing list processor will +wait for a subscription request to be confirmed by specifying the INTERVAL +keyword and a VMS delta-time string for its value. If not specified, +the default confirmation interval is 3 days. +.I-1 +/RETURN__ADDRESS + /RETURN__ADDRESS=address + /NORETURN__ADDRESS (default) + The /RETURN__ADDRESS qualifier is used to specify an alternate address +that is to be used as +the Reply-To address when /REPLY__TO=LIST is specified. +This qualifier is most useful when multiple lists should have a common +return address. For example, it can be used to redirect replies to a +"-Digest" list back to the non-digest address. +.I-1 +/SETTINGS + /SETTINGS=(keyword[,...]) + /SETTINGS=DEFAULT (default) + The /SETTINGS qualifier is used to override the default subscriber settings +for a list. The valid keywords are MAIL, REPRO, CONCEAL, DIGEST, POST, and +their "NO" forms. + A special keyword, DEFAULT, can be used to reset the settings +to the MLF default for a mailing list. The default settings for a list +are MAIL, REPRO, NOCONCEAL, NODIGEST, and POST. +.I-1 +/STRIP__HEADERS + /STRIP__HEADERS=(RECEIVED[,OTHER]) + /STRIP__HEADERS=(NORECEIVED,NOOTHER) (default) + The /STRIP__HEADERS qualifier is used to strip certain RFC822 headers from +messages posted to a mailing list. Currently, only the keywords RECEIVED and +OTHER (and NORECEIVED and NOOTHER) are supported. + When /STRIP__HEADERS=RECEIVED is set, the "Received:" headers are stripped from +the incoming message before it is mailed out to the list subscribers, thereby +reducing the total number of "Received:" headers in the final message. This is +especially beneficial to BITNET hosts because there can be a substantial number +of "Received:" headers added to a message that must pass through one or more +Internet/BITNET gateways. + When /STRIP__HEADERS=OTHER is set, all "other" headers are stripped from +the incoming message before it is mailed out. "Other" headers are any headers +not listed under HELP SET LOCAL/HEADERS. This includes return-receipt +headers, X-400 headers, etc. +.I-1 +/SUBJECT__PREFIX + /SUBJECT__PREFIX="string" + /NOSUBJECT__PREFIX (default) + Enables or disables the addition of a prefix to the Subject line of +messages posted to the list. By default, no prefix is added. When +the list is set to /REPLY__TO=(SENDER), a short prefix string may be +supplied to help subscribers recognize mailing list messages. The +given string is bracketed by square brackets ([]) when it is prefixed +to the subject lines. The maximum length for the prefix string is 32 +characters. Prefix strings should be kept short to avoid generating +extremely long subject lines. +.I-1 +/TEXT__ONLY + /TEXT__ONLY + /NOTEXT__ONLY (default) + The /TEXT__ONLY qualifier is used to specify whether or not the +mailing list processor should accept only those messages with plain +text content. By default, any content type is accepted for list postings. +.I-1 +/XHEADERS + /XHEADERS=("string"[,...]) + /NOXHEADERS (default) + The /XHEADERS qualifier can be used to add additional site-specific headers +to mailing list posts. For example, you can use /XHEADERS to add additional +non-standard "X-List-" headers such as "X-List-Archives". The format of the +header string is: "Keyword: text". For example, "Precedence: Bulk", which +is a non-standard header used by some mailers. + Extreme care should be taken when adding additional headers to mailing lists +to ensure that duplicate headers or improperly formatted headers +(those that don't comply with RFC 822) aren't added to mailing list posts. +.I-1 +2 LOCAL__DOMAIN + The DEFINE LOCAL__DOMAIN command adds a domain name or pattern +to the list of recognized "local" domains considered by the SMTP +server when determining relay rejection. +.NJ + Format: + DEFINE LOCAL__DOMAIN domain-name-or-pattern +.J + The LOCAL__DOMAIN list is only used when the SMTP server is set +to reject "relayed" SMTP messages with SET SMTP/NORELAY__ALLOWED. + A "relayed" message is one that originates on a remote system and +is sent to another remote recipient, using your system as an +intermediate relay. + When the SMTP server is set /NORELAY__ALLOWED, it checks the +envelope FROM and TO addresses, and if neither is local, refuses +to deliver the message. By default, any host in your local domain +(based on your TCP/IP host name and your MX host name) is considered +"local". You may use this command to add other hosts or domains +to this list. +.I-1 +3 Parameter + domain-name-or-pattern + Either a fully-qualified domain name of a single host, or a VMS-style +wildcard pattern. Host names in envelope addresses that match the +specified name or pattern will be considered local by the relay +checker. +.I-1 +2 PATH + The DEFINE PATH command is used to map a domain to a delivery path. +.NJ + Format: + DEFINE PATH domain-pat path-name +.J +.I-1 +3 Qualifiers +.I-1 +/ROUTE + /ROUTE=host-name + + Specifies the name of a host through which messages matching the domain +pattern should be routed. +.I-1 +3 domain-pat + This can be a specific domain name or a pattern containing wildcards to +match a domain name. For example: "specific.host.EDU", "*.BITNET". +.I-1 +3 path-name + This is one of DECNET__SMTP, HOLDING__QUEUE=n, LOCAL, SITE, SMTP. +You MUST have at least one LOCAL path defined; other paths will depend on the +network transports you have installed. For the HOLDING__QUEUE path, you must +specify an integer from 1 to 32 for "n". +.I-1 +2 REWRITE__RULE + The DEFINE REWRITE__RULE command establishes an address rewriting rule to +be used by the Router. +.NJ + Format: + DEFINE REWRITE__RULE old-addr new-addr +.J + When the router rewrites an address, it tries each rewrite rule, in the +order you define them, until one matches. It then applies the one rule +to that address. +.I-1 +3 Qualifiers +.I-1 +/REGEX + /REGEX + Specifies use of regular-expression matching and substitution instead +of substitution variables. +.I-1 +3 old-addr + The address-specification to be rewritten. All addresses must conform +to RFC821 and therefore will always contain a leading and closing angle +bracket. To create a substitution variable, surround the variable with +curly braces. Matching is done from right to left. Substitution variables +match all characters. + Example: <{user}@{host}.CSNET> + Substitution variables are not used with regular-expression matching +(when /REGEX is specified); instead, use subexpressions enclosed in +parentheses. +.I-1 +3 new-addr + The resulting address pattern. Substitution variables created in the +old-addr specification can be used here. + Example: <@relay.cs.net:{user}@{host}.CSNET> + When using regular-expression matching, replacements are specified +with a backslash followed by a single digit (1 through 9), representing +the 1st through the 9th matching subexpression. +.I-1 +2 SYSTEM__USERS + The DEFINE SYSTEM__USERS command identifies addresses that the mailing list +processor should treat as SYSTEM-class users for protection purposes. +.NJ + Format: + DEFINE SYSTEM__USERS address[,...] +.I-1 +1 EXIT + The EXIT command leaves MCP. If you were using MCP to edit an existing +MX configuration, a new version of the configuration file is saved before +MCP exits. If the configuration file name is unknown, you are prompted +for a file name before exiting. +.I-1 +1 HELP + The HELP command displays information on MCP commands. +.I-1 +1 MODIFY + The MODIFY command is used to change definitions of mailing lists, aliases, +paths, etc. The following MODIFY commands are supported, and take the same +qualifiers as their DEFINE counterparts (see the help information on DEFINE +for more information): +.NJ + MODIFY ALIAS alias + MODIFY FILE__SERVER fsrv-name + MODIFY INSIDE__NETWORK__ADDRESS ip-address + MODIFY LIST list-name + MODIFY PATH domain-pattern + MODIFY REWRITE__RULE lhs +.J + The MODIFY USER command is documented here. +.I-1 +2 USER + The MODIFY USER command is used to set a new password for a username in the +SMTP authentication database. +.NJ + Format: + MODIFY USER username +.J + Usernames may be up to 16 characters in length, and are case-sensitive. +.I-1 +3 Qualifiers +.I-1 +/PASSWORD + /PASSWORD=password-text + Specifies a password for this username. The password may be up to 64 +characters in length, and may contain any characters. To specify lower case +letters or blanks in the password, surround it with quotation marks. + If this qualifier is omitted, a default password, "PASSWORD", is assigned +to the username. + +.I-1 +1 QUIT + Quits out of MCP without saving the configuration. If you have changed +the configuration, QUIT will ask for confirmation before exiting. +.I-1 +1 REMOVE + The REMOVE command is used to remove an alias, mailing list, path, or +rewrite rule from the configuration. The following REMOVE commands +are supported: +.NJ + REMOVE ALIAS alias + REMOVE FILE__SERVER fsrv-name + REMOVE INSIDE__NETWORK__ADDRESS ip-address + REMOVE LIST listname + REMOVE LOCAL__DOMAIN domain-name-or-pattern + REMOVE PATH domain-spec + REMOVE REWRITE__RULE old-addr +.J + The REMOVE INSIDE__NETWORK__ADDRESS command also takes a qualifier, +/NETMASK. The combination of the IP address and the netmask must +match the combination in the inside address list. + The REMOVE USER command is documented here. +.J + The MODIFY USER command is documented here. +.I-1 +2 USER + The REMOVE USER command removes a username from the +SMTP authentication database. +.NJ + Format: + REMOVE USER username +.J + Usernames may be up to 16 characters in length, and are case-sensitive. +.I-1 +1 QUEUE + The QUEUE suite of commands is used to control the system message queue. +.I-1 +2 CANCEL + Cancels one or more messages. +.NJ + Format: + QUEUE CANCEL [entry-number,...] +.J + If you cancel the main entry for a message, all entries related to that +message will also be cancelled. If no entry numbers are specified, the +entries selected by the last QUEUE SELECT command are cancelled. +.I-1 +3 Qualifiers +.I-1 +/LOG + /LOG + /NOLOG (default) + Displays a log message for each successful operation. +.I-1 +2 COMPRESS + Shrinks the message queue file by creating a new file and renumbering +all the existing entries in the file. +.NJ + Format: + QUEUE COMPRESS/LOG +.J +.I-1 +3 Qualifiers +.I-1 +/MAXIMUM__ENTRIES + /MAXIMUM__ENTRIES=number-of-entries + Specifies the maximum number of queue entries to be allowed. MX will not +allow more entries to be added to the queue than the specified value. +MCP QUEUE EXTEND can be used to increase the number of allowed entries. + The size of the queue file in blocks is equal to the maximum number of +entries, plus 10 blocks plus whatever is added for the disk cluster. +.I-1 +/LOG + /LOG + /NOLOG (default) + Displays a log message for each successful operation. +.I-1 +2 CREATE + Creates a new, empty, MX message queue control file. +.NJ + Format: + QUEUE CREATE [filespec] +.J +.I-1 +3 Parameters + filespec + Name of the queue control file to be created. If omitted, the +default name, MX_FLQ_DIR:MX_SYSTEM_QUEUE.FLQ_CTL, is used. +.I-1 +3 Qualifiers +.I-1 +/MAXIMUM__ENTRIES + /MAXIMUM__ENTRIES=number-of-entries + Specifies the maximum number of queue entries to be allowed for the queue. +The message queue will be extended to allow the specified number of entries. + The size of the queue file in blocks is equal to the maximum number of +entries, plus 10 blocks plus whatever is added for the disk cluster. +.I-1 +2 DUMP + Dumps an enqueued message to a set of files suitable for modifying +recipient addresses and requeuing with MX_SITE_IN. +.NJ + Format: + QUEUE DUMP entry-number +.J +.I-1 +3 Qualifiers +.I-1 +/CANCEL + /CANCEL (default) + /NOCANCEL + By default, MCP cancels the queue entry for the dumped message. +Specify /NOCANCEL to keep the dumped entry in the queue. +.I-1 +/OUTPUT + /OUTPUT=file-spec + Specifies the location for the three output files generated by +this command. By default, the files are written to the current +default directory with the filename for the message text and recipient +files as ENTRY_n and the filename for the command procedure as +REQUEUE_n (where "n" is the entry number). + Do not specify a file type or version in the file specification; +QUEUE DUMP always uses the file types .MSG__TEXT, .RECIPIENTS, and .COM for +the message text, recipient, and command procedure files, respectively. +.I-1 +3 Parameter + entry-number + Queue entry number for the message to be dumped. The queue entry +must be in READY or IN-PROGRESS state. + QUEUE DUMP creates three output files for the message: one +containing the message text, one containing the list of recipients, +and a command procedure for invoking MX_SITE_IN to requeue the +message. +.I-1 +2 EXTEND + Extends the existing message queue file to allow more entries to be in +the queue at any given time. +.NJ + Format: + QUEUE EXTEND +.J +.I-1 +3 Qualifiers +.I-1 +/MAXIMUM__ENTRIES + /MAXIMUM__ENTRIES=number-of-entries + Specifies the maximum number of queue entries to be allowed. MX will not +allow more entries to be added to the queue than the specified value. +MCP QUEUE EXTEND can be used to increase the number of allowed entries. + The size of the queue file in blocks is equal to the maximum number of +entries, plus 10 blocks plus whatever is added for the disk cluster. +.I-1 +2 HOLD + Places one or more queue entries on hold. +.NJ + Format: + QUEUE HOLD [entry-number,...] +.J + This command places the specified queue entry or entries on hold, +so they will not be processed. Use the QUEUE READY command to release +the entries for processing. If no entry numbers are specified, the +entries selected by the last QUEUE SELECT command are held. +.I-1 +2 PURGE + Purges the message queue of all finished and cancelled entries. +.NJ + Format: + QUEUE PURGE +.J + The Router process automatically purges the queue of finished and cancelled +entries, periodically. This command can be used to force an immediate +purge of the queue. +.I-1 +3 Qualifiers +.I-1 +/LOG + /LOG + /NOLOG (default) + Displays a log message for each entry purged from the queue. +.I-1 +2 READY + Readies one or more queue entries for processing. +.NJ + Format: + QUEUE READY [entry-number,...] +.J + This command can be used to ready a destination-specific entry or the main +entry for a message (in which case all previous destination-specific entries +are automatically cancelled). If no entry numbers are specified, the queue +entries selected by the last QUEUE SELECT command are readied. +.I-1 +3 Qualifiers +.I-1 +/AFTER + /AFTER=date-time + Specifies a date and time after which the entry should be processed. If +not specified, the entry is readied for immediate processing. +.I-1 +/FINAL + /FINAL + /NOFINAL (default) + Sets the error count for all recipients associated with this entry +to 32767. This causes the delivery agent to process the entry +only once for each recipient. +.I-1 +/LOG + /LOG + /NOLOG (default) + Displays a log message for each successful operation. +.I-1 +2 SELECT + Selects queue entries. +.NJ + Format: + QUEUE SELECT +.J + This command builds a list of queue entries based on selection +criteria that you specify with qualifiers on the command. Subsequent +QUEUE CANCEL, HOLD, and READY commands will use this selection list +by default if you do not specify entry numbers on those commands. + You can display the selected entries with the QUEUE SHOW/SELECTED +command. +.I-1 +3 Qualifiers +.I-1 +/BEFORE + /BEFORE[=time] + Selects only those entries dated before the specified time. You can +specify time as an absolute time, a combination of absolute and delta +times, or as one of the following keywords: TODAY (default), TOMORROW, +or YESTERDAY. Specify one of the following qualifiers with the /BEFORE +qualifier to indicate the time attribute to be used as the basis for +selection: /CREATED (default), /DELAY, /EXPIRE, or /MODIFIED. +.I-1 +/CREATED + /CREATED + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /CREATED qualifier selects entries based on their +dates of creation. +.I-1 +/DELAY + /DELAY + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /DELAY qualifier selects entries based on their +delay dates. +.I-1 +/DESTINATION__AGENT + /DESTINATION__AGENT=agent + Selects only those entries that are to be or have been processed by the +specified MX agent. Valid keywords are: ROUTER, MLF, LOCAL, SMTP, SITE, +DNSMTP, and HOLDING__QUEUE=n (where n ranges from 1 to 32, +the maximum number of holding queues). HOLD1 through HOLD8 are obsolte, +but still supported for backward compatibility with prior versions of MX. +This qualifier is most useful when used with /BRIEF. +.I-1 +/EXPIRE + /EXPIRE + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /EXPIRE qualifier selects entries based on their +dates of expiration. +.I-1 +/HELD + /HELD + Selects only those entries that are in USER-HOLD or OPER-HOLD state. +.I-1 +/IN__PROGRESS + /IN__PROGRESS + Selects only entries marked as being in-progress (INPROG). +.I-1 +/MODIFIED + /MODIFIED + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /MODIFIED qualifier selects entries based on their +dates of modification. +.I-1 +/ORIGIN__AGENT + /ORIGIN__AGENT=agent + Selects only those entries that were entered into the queue by the +specified MX agent. Valid keywords are: LOCAL, SMTP, SITE, +MAIL, and DNSMTP. +.I-1 +/SINCE + /SINCE[=time] + Selects only those entries dated after the specified time. You can +specify time as an absolute time, a combination of absolute and delta +times, or as one of the following keywords: TODAY (default), TOMORROW, +or YESTERDAY. Specify one of the following qualifiers with the /SINCE +qualifier to indicate the time attribute to be used as the basis for +selection: /CREATED (default), /DELAY, /EXPIRE, or /MODIFIED. +.I-1 +/WAITING + /WAITING + Selects only those entries that are waiting for processing. +.I-1 +2 SHOW + Displays queue entries. +.NJ + Format: + QUEUE SHOW [entry-number,...] +.J + With no qualifiers, QUEUE SHOW gives a brief display for each active +(READY or IN-PROGRESS) queue entry. +.I-1 +3 Qualifiers +.I-1 +/ALL + /ALL + Causes the display of all queue entries, including those that have been +finished or cancelled. +.I-1 +/BEFORE + /BEFORE[=time] + Selects only those entries dated before the specified time. You can +specify time as an absolute time, a combination of absolute and delta +times, or as one of the following keywords: TODAY (default), TOMORROW, +or YESTERDAY. Specify one of the following qualifiers with the /BEFORE +qualifier to indicate the time attribute to be used as the basis for +selection: /CREATED (default), /DELAY, /EXPIRE, or /MODIFIED. +.I-1 +/BRIEF + /BRIEF + Causes a brief display of all queue entries, including those that have +been finished or cancelled. The information displayed +is taken only from the MX queue file and includes the target MX process +for each entry. +.I-1 +/CREATED + /CREATED + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /CREATED qualifier selects entries based on their +dates of creation. +.I-1 +/DATE + /DATE + Causes the creation and modification dates to be displayed for each queue +entry. +.I-1 +/DELAY + /DELAY + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /DELAY qualifier selects entries based on their +delay dates. +.I-1 +/DESTINATION__AGENT + /DESTINATION__AGENT=agent + Selects only those entries that are to be or have been processed by the +specified MX agent. Valid keywords are: ROUTER, MLF, LOCAL, SMTP, SITE, +DNSMTP, and HOLDING__QUEUE=n (where n ranges from 1 to 32, +the maximum number of holding queues). HOLD1 through HOLD8 are obsolte, +but still supported for backward compatibility with prior versions of MX. +This qualifier is most useful when used with /BRIEF. +.I-1 +/EXPIRE + /EXPIRE + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /EXPIRE qualifier selects entries based on their +dates of expiration. +.I-1 +/FULL + /FULL + Provides a more detailed display of each queue entry. +.I-1 +/HELD + /HELD + Selects only those entries that are in USER-HOLD or OPER-HOLD state. +.I-1 +/IN__PROGRESS + /IN__PROGRESS + Displays only entries marked as being in-progress (INPROG). +.I-1 +/MODIFIED + /MODIFIED + Modifies the time value specified with the /BEFORE or the /SINCE +qualifier. The /MODIFIED qualifier selects entries based on their +dates of modification. +.I-1 +/ORIGIN__AGENT + /ORIGIN__AGENT=agent + Selects only those entries that were entered into the queue by the +specified MX agent. Valid keywords are: LOCAL, SMTP, SITE, +MAIL, and DNSMTP. +.I-1 +/OUTPUT + /OUTPUT=file-spec + Directs the output of the command to the specified file. +.I-1 +/SELECTED + /SELECTED + Displays the entries that were selected by the last QUEUE SELECT +command. +.I-1 +/SINCE + /SINCE[=time] + Selects only those entries dated after the specified time. You can +specify time as an absolute time, a combination of absolute and delta +times, or as one of the following keywords: TODAY (default), TOMORROW, +or YESTERDAY. Specify one of the following qualifiers with the /SINCE +qualifier to indicate the time attribute to be used as the basis for +selection: /CREATED (default), /DELAY, /EXPIRE, or /MODIFIED. +.I-1 +/WAITING + /WAITING + Causes only those entries that are waiting for processing to be displayed. +.I-1 +2 STATISTICS + Displays statistics concerning the number of entries in the MX message queue. +.NJ + Format: + QUEUE STATISTICS +.J +.I-1 +2 SYNCHRONIZE + Synchronizes the message queue bitmap with the actual entries in the queue. +.NJ + Format: + QUEUE SYNCHRONIZE +.J +.I-1 +3 Qualifiers +.I-1 +/LOG + /LOG + Displays a log message about the synchronization. +.I-1 +/RESET + /RESET + Resets the "Highest entry used" counter displayed by QUEUE +STATISTICS. By default, the counter is not reset. +.I-1 +1 RESET + Sends a reset signal to one or more MX delivery agent processes, causing +them to reload their configuration information. +.NJ + Format: + RESET [agent,...] +.J + Accepted agent names are: DECNET__SMTP, LOCAL, MLF, ROUTER, SITE, +SMTP, and SMTP__SERVER. +If omitted, all agents are reset. +.I-1 +2 Qualifiers +.I-1 +/ACCOUNTING + /ACCOUNTING + Causes a new accounting file to be opened, for those agents supporting +accounting (DECNET__SMTP, LOCAL, MLF, ROUTER, and SMTP). +No reloading of configuration occurs when RESET/ACCOUNTING is used. +.I-1 +/CLUSTER + /CLUSTER + Causes the reset to affect agents cluster-wide; this is the default +behavior. Use the /NODE qualifier to restrict the reset action to +specific nodes in the cluster. +.I-1 +/NODE + /NODE[=(node[,...])] + Causes the specified agent resets to occur only on the specified nodes. +If no node names are specified, the local node is used by default. +.I-1 +1 REVIEW + Displays the subscribers of a locally-managed mailing list. +.NJ + Format: + REVIEW list-name +.J +.I-1 +2 Qualifier +.I-1 +/OUTPUT + /OUTPUT=file-spec + Directs the output of the REVIEW command to the specified file. +.I-1 +1 SAVE + Saves the current MX configuration to a file. To be used by the Router +and other processing agents, the file must be called MX__CONFIG.MXCFG and +reside in the MX__DIR directory. Alternatively, you can define the system-wide +logical name MX__CONFIG (in exec mode) to point to the real location of the +MX configuration file to be used by the processing agents. +.NJ + Format: + SAVE file-spec +.J +.I-1 +1 SET + The SET command sets flags for use by some of the delivery agents. +.NJ + Format: + SET option +.J +.I-1 +2 DECNET__SMTP + The SET DECNET__SMTP command sets flags for use by the SMTP-over-DECnet +delivery agent. +.NJ + Format: + SET DECNET__SMTP +.I-1 +3 Qualifiers +.I-1 +/ACCOUNTING + /ACCOUNTING + /NOACCOUNTING (default) +.J + Controls whether accounting records are written by the delivery agent. +If enabled, accounting records are written to the file MX__DNSMTP__ACC +(with a default directory of MX__DNSMTP__DIR: and a default type of DAT). +.I-1 +/MAXIMUM__RETRIES + /MAXIMUM__RETRIES=n + Specifies the maximum number of times the DECnet-SMTP agent should +try to deliver a message if the message cannot be delivered (due to +network failure). The default is 96. +.I-1 +/RETRY__INTERVAL + /RETRY__INTERVAL=hh:mm:ss + Specifies the minimum amount of time that should elapse between attempts +to deliver a message. The default is 00:30:00 (30 minutes). +.I-1 +2 LOCAL + The SET LOCAL command sets flags for use by the local delivery agent. +.NJ + Format: + SET LOCAL +.I-1 +3 Qualifiers +.I-1 +/ACCOUNTING + /ACCOUNTING + /NOACCOUNTING (default) +.J + Controls whether accounting records are written by the delivery agent. +If enabled, accounting records are written to the file MX__LOCAL__ACC +(with a default directory of MX__LOCAL__DIR: and a default type of DAT). +.I-1 +/CC__POSTMASTER + /CC__POSTMASTER + /NOCC__POSTMASTER + Specifies whether or not error messages resulting from LOCAL delivery +errors are mailed to the local POSTMASTER, in addition to the original +message sender. +.I-1 +/DISABLE__EXQUOTA + /DISABLE__EXQUOTA[=[NO]FATAL] + /NODISABLE__EXQUOTA + Specifies whether the EXQUOTA privilege should be disabled during +local delivery attempts. By default, EXQUOTA remains enabled during +local message delivery. Specifying /DISABLE__EXQUOTA=FATAL causes messages +that exceed the recipient's diskquota to be returned to sender immediately, +rather than going through normal retry procedures. +.I-1 +/HEADERS + /HEADERS=(TOP:([NO]hdrname[,...]),BOTTOM:([NO]hdrname[,...])) +.J + Controls the placement of message headers in local delivery of messages. +Any or all headers may be placed at the top and/or bottom of the message, +or not added to the message at all. Valid values for hdrname are: +.i+10;ALL +.i+10;BCC +.i+10;CC +.i+10;DATE +.i+10;ENCRYPTED +.i+10;FROM +.i+10;IN__REPLY__TO +.i+10;KEYWORDS +.i+10;MESSAGE__ID +.i+10;OTHER +.i+10;RECEIVED +.i+10;REFERENCES +.i+10;REPLY__TO +.i+10;RESENT__BCC +.i+10;RESENT__CC +.i+10;RESENT__DATE +.i+10;RESENT__FROM +.i+10;RESENT__MESSAGE__ID +.i+10;RESENT__REPLY__TO +.i+10;RESENT__SENDER +.i+10;RESENT__TO +.i+10;RETURN__PATH +.i+10;SENDER +.i+10;SUBJECT +.i+10;TO + The hdrname keywords may be negated. ALL specifies all headers; +NOALL specifies no headers. OTHER specifies all headers with a header +name not matching one of the other keywords. +.I-1 +/LONG__LINES + /LONG__LINES + /NOLONG__LINES (default) + Specifies that lines exceeding the MAIL-11 255 character maximum +should not be wrapped during delivery to what appears to be a +local user. This setting is disabled by default, so lines exceeding +the maximum length get wrapped at the nearest whitespace character +to the limit (if there are any). Enabling this +setting could cause mail delivery via VMS MAIL's DECnet support to +fail when MX cannot determine that a recipient is a DECnet +address. +.I-1 +/MAXIMUM__RETRIES + /MAXIMUM__RETRIES=n + Specifies the maximum number of times the local delivery agent should +try to deliver a message if the message cannot be delivered (due to +DECnet outage or locked mail file). The default is 96. +.I-1 +/MULTIPLE__FROM + /MULTIPLE__FROM (default) + /NOMULTIPLE__FROM + Controls whether or not the VMS Mail ``From:'' line on incoming +messages can contain multiple return addresses. By default, if an +RFC822 From: or Reply-To: line contains more than one address, as many +of those addresses as will fit are included on the VMS Mail ``From:'' +line (up to 255 characters). Specifying /NOMULTIPLE__FROM limits the +``From:'' line to a single address. +.I-1 +/OMIT__RESENT__HEADERS + /OMIT__RESENT_HEADERS + /NOOMIT__RESENT_HEADERS (default) + Specifies that MX forwarding using VMS Mail SET FORWARD should +omit the Resent- headers MX normally uses to detect forwarding loops. +This setting is disabled by default, and should only be enabled if +users' mail clients have trouble interpreting Resent- headers. +.I-1 +/QP__DECODE + /QP__DECODE + /NOQP__DECODE + Specifies whether or not incoming MIME quoted-printable messages are +automatically decoded by MX Local before delivery through VMS Mail. By +default, such messages are decoded. If your users read their mail via +POP or IMAP, you might want to disable the decoding to let the users' +browsers do the decoding. +.I-1 +/RETRY__INTERVAL + /RETRY__INTERVAL=hh:mm:ss + Specifies the minimum amount of time that should elapse between attempts +to deliver a message. The default is 00:30:00 (30 minutes). +.I-1 +2 MLF + The SET MLF command sets global parameters for the MLF +Mailing List/File Server agent. +.NJ + Format: + SET MLF [qualifiers] +.I-1 +3 Qualifiers +.I-1 +/DELAY__DAYS + /DELAY__DAYS=(dow[,...]) + /NODELAY__DAYS + Sets the days of the week on which all file servers' +delayed-send threshold should be honored. Defaults +to all days of the week. +.I-1 +/RECIPIENT__MAXIMUM + /RECIPIENT__MAXIMUM=number + /NORECIPIENT__MAXIMUM + Sets the maximum number of recipients per message generated +by the MLF agent. If your MLF agent services large mailing +lists with many remote subscribers, you may want to use this +setting to limit the number of recipients per message generated +by MLF. This will break up the distribution to the mailing list +into smaller chunks, allowing for more parallelism in delivery. + Setting too small a value, however, could create a lengthy backlog +in your MX message queue, depending on the number of subscribers +on your mailing list(s) and the number of messages the list receives +each day. + The default is /NORECIPIENT__MAXIMUM, which forces each incoming +mailing list message to be forwarded as just one outbound message. +.I-1 +2 ROUTER + The SET ROUTER command sets flags for use by the Router. +.NJ + Format: + SET ROUTER [qualifiers] +.I-1 +3 Qualifiers +.I-1 +/ACCOUNTING + /ACCOUNTING + /NOACCOUNTING (default) +.J + Controls whether accounting records are written by the Rourter. +If enabled, accounting records are written to the file MX__ROUTER__ACC +(with a default directory of MX__ROUTER__DIR: and a default type of DAT). + One accounting record is written for each recipient of each routed message, +either successful or unsuccessful. +.I-1 +/OMIT__VMSMAIL__SENDER + /OMIT__VMSMAIL__SENDER + /NOOMIT__VMSMAIL__SENDER (D) + Enables or disables the omission of the Sender: header for messages +sent from VMS Mail. Needed by some sites to work with other mailers that +don't adhere to RFC822. +.I-1 +/PERCENT__HACK + /PERCENT__HACK (D) + /NOPERCENT__HACK + Specify /NOPERCENT__HACK when you want to disable the automatic resolution +of percent-hacked addresses. It is enabled by default, and automatically +translates addresses of the form "user%host@localhost" to "user@host". +Percent-hack resolution may need to be disabled when you need to pass +MX mail through the VMS Mail interface and into another mail system. +.I-1 +2 SITE + The SET SITE command sets flags for use by the SITE delivery agent. +.NJ + Format: + SET SITE +.I-1 +3 Qualifiers +.I-1 +/MAXIMUM__RETRIES + /MAXIMUM__RETRIES=n + Specifies the maximum number of times the SITE agent should +try to deliver a message if the message cannot be delivered (due to +network failure). The default is 96. +.I-1 +/RETRY__INTERVAL + /RETRY__INTERVAL=hh:mm:ss + Specifies the minimum amount of time that should elapse between attempts +to deliver a message. The default is 00:30:00 (30 minutes). +.I-1 +2 SMTP + The SET SMTP command sets flags for use by the SMTP delivery agent +and SMTP server. +.NJ + Format: + SET SMTP +.I-1 +3 Qualifiers +.I-1 +/ACCOUNTING + /ACCOUNTING + /NOACCOUNTING (default) +.J + Controls whether accounting records are written by the delivery agent. +If enabled, accounting records are written to the file MX__SMTP__ACC +(with a default directory of MX__SMTP__DIR: and a default type of DAT). +.I-1 +/AUTHENTICATION + /AUTHENTICATION=(type,...) + /NOAUTHENTICATION (default) +.J + Enables or disables the authentication extension in the SMTP server. +The "type" keyword can be CRAM__MD5, which enables the use of MX's +private authentication database (see CREATE USER__DATABASE__FILE), +or PLAIN, which enables the use of the VMS user authorization file. + Specifying /NOAUTHENTICATION disables the authentication completely. +.I-1 +/DEFAULT__ROUTER + /DEFAULT__ROUTER=domain-name + Specifies the name of a host through which all SMTP-bound mail should +be sent if a host name lookup fails. +.I-1 +/DNS__RETRIES + /DNS__RETRIES=n + Specifies the maximum number of attempts to deliver a message when the +host name in a destination address cannot be resolved. The default is +12. +.I-1 +/MAXIMUM__RETRIES + /MAXIMUM__RETRIES=n + Specifies the maximum number of times the SMTP agent should +try to deliver a message if the message cannot be delivered (due to +network failure). The default is 96. +.I-1 +/PERCENT__HACK + /PERCENT__HACK (D) + /NOPERCENT__HACK + Specify /NOPERCENT__HACK when you want to reject any addresses containing +a percent-sign in the username portion of the address. Such addresses +are accepted by default. Disabling the percent hack may be necessary to +prevent other sites from using this feature to relay e-mail through your +system. +.I-1 +/RBL__CHECK + /RBL__CHECK[=(domain-name,...)] + /NORBL__CHECK (default) + Specifies whether the SMTP server should check to see if a +system connecting to it is on an Internet Realtime Blackhole List (RBL). +RBL checking is disabled by default. + You must specify one or more domain names as values for this qualifier; +consult your RBL provider for information on the domain names to use. +.I-1 +/RELAY__ALLOWED + /RELAY__ALLOWED (default) + /NORELAY__ALLOWED + Specifies whether the SMTP server will allow messages to be relayed +through your system from one outside system to another. This is +allowed by default. If you disable the relay function with +/NORELAY__ALLOWED, you may also need to tell MX which domains +it should consider "local" for the purposes of this check. See +the DEFINE LOCAL__DOMAIN command for more information. +.I-1 +/RETRY__INTERVAL + /RETRY__INTERVAL=hh:mm:ss + Specifies the minimum amount of time that should elapse between attempts +to deliver a message. The default is 00:30:00 (30 minutes). +.I-1 +/TLS + /TLS + /NOTLS (default) +.J + Controls whether SMTP_SERVER advertises and supports the STARTTLS +ESMTP command documented in RFC3207. +.I-1 +/VALIDATE__SENDER__DOMAIN + /[NO]VALIDATE__SENDER__DOMAIN + Enables or disables a check in the SMTP server on whether the +domain name appearing in an SMTP MAIL FROM command appears in the Domain Name System. +When enabled, a message from a sender whose domain name is invalid is +rejected. This setting is disabled by default. +.I-1 +/VERIFY__ALLOWED + /[NO]VERIFY__ALLOWED + Enables or disables the processing of VRFY commands by the SMTP server. +By default, VRFY is enabled. System administrators concerned about +network security should specify /NOVERIFY__ALLOWED to disable the VRFY +command in the SMTP server. +.I-1 +1 SHOW + The SHOW command displays all or part of the MX configuration. +.NJ + Format: + SHOW ALIASES [pattern] + SHOW CONFIGURATION__FILE + SHOW DECNET__SMTP + SHOW FILE__SERVER [pattern] + SHOW LISTS [pattern] + SHOW LOCAL + SHOW LOCAL__DOMAINS + SHOW PATHS [pattern] + SHOW REWRITE__RULES [pattern] + SHOW ROUTER + SHOW SITE + SHOW SMTP + SHOW SYSTEM__USERS + SHOW USERS [pattern] + SHOW VERSION + SHOW ALL +.J + Those commands taking a pattern will display all entries matching the specified +pattern, which defaults to "*". SHOW ALL displays all of the configuration +information. +.I-1 +2 Qualifiers +.I-1 +/BRIEF + /BRIEF + The /BRIEF qualifier causes SHOW to display information in an +abbreviated format. Only SHOW LISTS has a brief display; for all +other commands, the brief and full displays are identical. +.I-1 +/COMMAND + /COMMAND + /NOCOMMAND (default) + The /COMMAND qualifier causes the SHOW output to be formatted as MCP +commands, which could be executed later to reconstruct the configuration. +By default, the configuration information is displayed in a more +eye-pleasing and descriptive format. +.I-1 +/FULL + /FULL (default) + The /FULL qualifier causes SHOW to display information in its +normal, full format. Only SHOW LISTS has a brief display; for all +other commands, the brief and full displays are identical. +.I-1 +/OUTPUT + /OUTPUT=file-spec + The /OUTPUT qualifier can be used to direct the SHOW output into a file. +When used with the /COMMAND qualifier, SHOW/OUTPUT can be used to create +a command file that can be edited and then read back in with the "@" +input-indirection function to create a new configuration file from scratch. +.I-1 +1 SHUTDOWN + Sends a shutdown signal to one or more MX delivery agent processes, causing +them to exit cleanly. +.NJ + Format: + SHUTDOWN [agent,...] +.J + Accepted agent names are: DECNET__SMTP, LOCAL, MLF, ROUTER, SITE, +SMTP, SMTP__SERVER, and HOLDING__QUEUE=n (where n ranges +from 1 to 32, the maximum number of holding queues). HOLD1 through HOLD8 are +obsolete but still supported for backward compatibility with prior versions +of MX. +If omitted, all agents are shut down. +.I-1 +2 Qualifiers +.I-1 +/CLUSTER + /CLUSTER + Causes the specified agent shutdowns to occur cluster-wide. By default, +SHUTDOWN affects only agents on the local node. +.I-1 +/NODE + /NODE[=(node[,...])] + Causes the specified agent shutdowns to occur only on the specified nodes. +If no node names are specified, only agents on the local node are affected. +.I-1 +/WAIT + /WAIT + /NOWAIT (default) + Waits for the specified agent to exit before returning (up to 30 seconds). +.I-1 +1 STATUS + Displays the status of one or more MX agent processes. +.NJ + Format: + STATUS [agent,...] +.J + Accepted agent names are: DECNET__SMTP, LOCAL, MLF, ROUTER, SITE, +SMTP, SMTP__SERVER, and HOLDING__QUEUE=n (where n ranges +from 1 to 32, the maximum number of holding queues). HOLD1 through HOLD8 are +obsolete but still supported for backward compatibility with prior versions +of MX. +If omitted, status of all running agent processes is displayed. For each +process, the process ID, node name (on VMScluster systems), process name, +and agent type are displayed. +.I-1 +2 Qualifier +.I-1 +/NODE + /NODE=(node[,...]) + Causes the display of only those specified agents running on the specified +nodes. +.! +.I-1 +1 SPAWN + SPAWN is used to create a subprocess and transfer control to it. +.NJ + Format: + SPAWN [command] +.J +.I-1 +2 Parameter + command + Specifies a command line to be executed within the spawned subprocess. +If a command is given, then the spawned process will be deleted after +that command is executed. +.I-1 +2 Examples +.LITERAL + 1. prompt> SPAWN DIRECTORY + [Output of the DIRECTORY command] + . + . + . + prompt> + + The command above demonstrates spawning a subprocess to execute + a particular command. + + 2. prompt> SPAWN + sub_prompt> dir + . + . + . + + The spawned process created above will stick around until it + is explictly deleted (or its parent process is deleted). Once + you SPAWN a subprocess, you can transfer control between it and + program by using the DCL and program ATTACH commands. +.END LITERAL +.! +.I-1 +1 ATTACH + ATTACH is used to transfer control to another process in the current +process tree. +.NJ + Format: + ATTACH [process] +.J +.I-1 +2 Parameter + process + Specifies the process name of the process to which to attach. Not +required if one of the ATTACH qualifiers is used. +.I-1 +2 Qualifiers +.I-1 +/IDENTIFICATION + /IDENTIFICATION=pid + Specifies the PID of the process to which to attach. +.I-1 +/PARENT + /PARENT + Transfers control to the parent process of the process running MCP. +Returns an error if MCP is not running in a subprocess. +.I-1 +2 Examples +.LITERAL + MCP> ATTACH GOATHUNTER_1 + + The command above demonstrates attaching to the subprocess + named "GOATHUNTER_1". +.END LITERAL diff --git a/samples/Ruby/any.spec b/samples/Ruby/any.spec new file mode 100644 index 00000000..50188314 --- /dev/null +++ b/samples/Ruby/any.spec @@ -0,0 +1,44 @@ +require File.dirname(File.expand_path(__FILE__)) + '/../spec_helper' + +describe Spira::Types::Any do + + before :all do + @uri = RDF::URI('http://example.org') + end + + # this spec is going to be necessarily loose. The 'Any' type is defined to + # use RDF.rb's automatic RDF Literal boxing and unboxing, which may or may + # not change between verions. + # + context "when serializing" do + it "should serialize literals to RDF Literals" do + serialized = Spira::Types::Any.serialize(15) + serialized.should be_a RDF::Literal + serialized = Spira::Types::Any.serialize("test") + serialized.should be_a RDF::Literal + end + + it "should keep RDF::URIs as URIs" do + Spira::Types::Any.serialize(@uri).should == @uri + end + + it "should fail to serialize collections" do + lambda { Spira::Types::Any.serialize([]) }.should raise_error TypeError + end + end + + context "when unserializing" do + it "should unserialize to ruby types" do + value = Spira::Types::Any.unserialize(RDF::Literal.new(5, :datatype => RDF::XSD.integer)) + value.should == 5 + value = Spira::Types::Any.unserialize(RDF::Literal.new("a string")) + value.should == "a string" + end + + it "should unserialize URIs to URIs" do + Spira::Types::Any.unserialize(@uri).should == @uri + end + end + + +end diff --git a/samples/XML/HITSP_C32.sch b/samples/XML/HITSP_C32.sch new file mode 100644 index 00000000..62750fdd --- /dev/null +++ b/samples/XML/HITSP_C32.sch @@ -0,0 +1,207 @@ + + + + + + + + + + + + + + + + + + + + + +]> + + + HITSP_C32 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + &ent-2.16.840.1.113883.3.88.11.32.1; + + + + + &ent-2.16.840.1.113883.3.88.11.32.2; + + + + + &ent-2.16.840.1.113883.3.88.11.32.3; + + + + + &ent-2.16.840.1.113883.3.88.11.32.4; + + + + + &ent-2.16.840.1.113883.3.88.11.32.5; + + + + + &ent-2.16.840.1.113883.3.88.11.32.6; + + + + + &ent-2.16.840.1.113883.3.88.11.32.7; + + + + + &ent-2.16.840.1.113883.3.88.11.32.8; + + + + + &ent-2.16.840.1.113883.3.88.11.32.9; + + + + + &ent-2.16.840.1.113883.3.88.11.32.10; + + + + + &ent-2.16.840.1.113883.3.88.11.32.11; + + + + + &ent-2.16.840.1.113883.3.88.11.32.12; + + + + + &ent-2.16.840.1.113883.3.88.11.32.13; + + + + + &ent-2.16.840.1.113883.3.88.11.32.14; + + + + + &ent-2.16.840.1.113883.3.88.11.32.15; + + + + + &ent-2.16.840.1.113883.3.88.11.32.16; + + + + + &ent-2.16.840.1.113883.3.88.11.32.17; + + diff --git a/samples/XML/namespace-strict.sch b/samples/XML/namespace-strict.sch new file mode 100644 index 00000000..f55a5143 --- /dev/null +++ b/samples/XML/namespace-strict.sch @@ -0,0 +1,84 @@ + + + + + + + + + + + + + + + + + > + + + + + + + + + + + + + Unrecognized namespace prefix: + + + + Unrecognized namespace URI: + + + + + + Prefix + assigned incorrectly: + + + + + + + Namespace may not be declared here. + + + Namespace may not be undeclared here. + + + + + + + + + + \ No newline at end of file diff --git a/samples/XML/oasis-table.sch b/samples/XML/oasis-table.sch new file mode 100644 index 00000000..c947aeb2 --- /dev/null +++ b/samples/XML/oasis-table.sch @@ -0,0 +1,151 @@ + + + + + + + + + OASIS/CALS table validation + + + + + + + + + + + + + + + + tgroup/@cols is not given + @cols should be a natural number + (integer greater than zero). + The tgroup has + colspec, + but its @cols is given as ''. + tgroup/@cols is given as + , but all rows have entr. + + Without assigning @char or @charoff to everything, + assigning @align='char' to tgroup only aligns contents to right of center. + + + + + Malformed @colwidth. + @colwidth unit + () is not consistent with the + units on other colspecs. + + @colwidth must be positive + The same unit of measure should be used on every + colspec/@colwidth. + + @colnum + '' does not correspond to + the column's actual number () + The same @colname is assigned to more than + one colspec. + @align='char', but no @char is given. + @char is given, but alignment is not 'char'. + @charoff is given, but alignment is not 'char'. + + + + + + + + The row doesn't have enough entries ( + expected; + given). + + + + + No colspec is + named . + Entry's end + column () must follow its start column + (). + No colspec is + named . + No colspec is + named . + Entry is assigned an end + column () but not a start column. + Entry is assigned to column , + so it can't start at column . + + + + Entry must be assigned to a free column (after its preceding entries). + + + This entry doesn't fit into + its . + + + A row in which this entry appears has too many entries. + + + + Entry does not fit in row. ( are allowed; entry + is in column .) + + + + @char is given, but alignment is not 'char'. + @charoff is given, but alignment is not 'char'. + @charoff must be a whole number between 0 and 100. + + Entry is designated for character alignment, but no character (@char) is given on it or its colspec. + + + Entry is assigned an alignment character () + different from its column's (). + With @align='char', markup of + entry contents () will be ignored. + + + \ No newline at end of file diff --git a/script/convert-grammars b/script/convert-grammars index ec3287db..2155827f 100755 --- a/script/convert-grammars +++ b/script/convert-grammars @@ -42,7 +42,7 @@ class DirectoryPackage case File.extname(path.downcase) when '.plist' path.split('/')[-2] == 'Syntaxes' - when '.tmlanguage' + when '.tmlanguage', '.yaml-tmlanguage' true when '.cson', '.json' path.split('/')[-2] == 'grammars' @@ -114,7 +114,7 @@ class SVNPackage def fetch(tmp_dir) `svn export -q "#{url}/Syntaxes" "#{tmp_dir}/Syntaxes"` raise "Failed to export SVN repository: #{url}: #{$?.to_s}" unless $?.success? - Dir["#{tmp_dir}/Syntaxes/*.{plist,tmLanguage,tmlanguage}"] + Dir["#{tmp_dir}/Syntaxes/*.{plist,tmLanguage,tmlanguage,YAML-tmLanguage}"] end end @@ -148,6 +148,17 @@ def load_grammar(path) case File.extname(path.downcase) when '.plist', '.tmlanguage' Plist::parse_xml(path) + when '.yaml-tmlanguage' + content = File.read(path) + # Attempt to parse YAML file even if it has a YAML 1.2 header + if content.lines[0] =~ /^%YAML[ :]1\.2/ + content = content.lines[1..-1].join + end + begin + YAML.load(content) + rescue Psych::SyntaxError => e + $stderr.puts "Failed to parse YAML grammar '#{path}'" + end when '.cson' cson = `"#{CSONC}" "#{path}"` raise "Failed to convert CSON grammar '#{path}': #{$?.to_s}" unless $?.success? @@ -169,7 +180,7 @@ def load_grammars(tmp_dir, source, all_scopes) else SingleFile.new(source) end - elsif source.end_with?('.tmLanguage', '.plist') + elsif source.end_with?('.tmLanguage', '.plist', '.YAML-tmLanguage') SingleGrammar.new(source) elsif source.start_with?('https://github.com') GitHubPackage.new(source) @@ -185,7 +196,7 @@ def load_grammars(tmp_dir, source, all_scopes) p.fetch(tmp_dir).map do |path| grammar = load_grammar(path) - scope = grammar['scopeName'] + scope = grammar['scopeName'] || grammar['scope'] if all_scopes.key?(scope) unless all_scopes[scope] == p.url @@ -204,7 +215,7 @@ def install_grammars(grammars, path) installed = [] grammars.each do |grammar| - scope = grammar['scopeName'] + scope = grammar['scopeName'] || grammar['scope'] File.write(File.join(GRAMMARS_PATH, "#{scope}.json"), JSON.pretty_generate(grammar)) installed << scope end diff --git a/script/set-language-ids b/script/set-language-ids new file mode 100755 index 00000000..ecbe1e76 --- /dev/null +++ b/script/set-language-ids @@ -0,0 +1,82 @@ +#!/usr/bin/env ruby +require 'yaml' +require 'pry' + +header = <<-EOF +# Defines all Languages known to GitHub. +# +# type - Either data, programming, markup, prose, or nil +# aliases - An Array of additional aliases (implicitly +# includes name.downcase) +# ace_mode - A String name of the Ace Mode used for highlighting whenever +# a file is edited. This must match one of the filenames in http://git.io/3XO_Cg. +# Use "text" if a mode does not exist. +# wrap - Boolean wrap to enable line wrapping (default: false) +# extensions - An Array of associated extensions (the first one is +# considered the primary extension, the others should be +# listed alphabetically) +# interpreters - An Array of associated interpreters +# searchable - Boolean flag to enable searching (defaults to true) +# search_term - Deprecated: Some languages may be indexed under a +# different alias. Avoid defining new exceptions. +# language_id - Integer used as a language-name-independent indexed field so that we can rename +# languages in Linguist without reindexing all the code on GitHub. Must not be +# changed for existing languages without the explicit permission of GitHub staff. +# color - CSS hex color to represent the language. +# tm_scope - The TextMate scope that represents this programming +# language. This should match one of the scopes listed in +# the grammars.yml file. Use "none" if there is no grammar +# for this language. +# group - Name of the parent language. Languages in a group are counted +# in the statistics as the parent language. +# +# Any additions or modifications (even trivial) should have corresponding +# test changes in `test/test_blob.rb`. +# +# Please keep this list alphabetized. Capitalization comes before lowercase. + +EOF + +generated = true if ARGV[0] == "--force" +update = true if ARGV[0] == "--update" + +if generated + puts "You're regenerating all of the language_id attributes for all Linguist " + puts "languages defined in languages.yml. This is almost certainly NOT what" + puts "you meant to do!" + + language_index = 0 + + languages = YAML.load(File.read("lib/linguist/languages.yml")) + languages.each do |name, vals| + vals.merge!('language_id' => language_index) + language_index += 1 + end + + File.write("lib/linguist/languages.yml", header + YAML.dump(languages)) +elsif update + puts "Adding new language_id attributes to languages.yml that don't have one set" + languages = YAML.load(File.read("lib/linguist/languages.yml")) + + # First grab the maximum language_id + language_ids = [] + languages.each { |name, vals| language_ids << vals['language_id'] if vals.has_key?('language_id')} + max_language_id = language_ids.max + puts "Current maximum language_id is #{max_language_id}" + + missing_count = 0 + language_index = max_language_id + + languages.each do |name, vals| + unless vals.has_key?('language_id') + language_index += 1 + missing_count += 1 + vals.merge!('language_id' => language_index) + end + end + + File.write("lib/linguist/languages.yml", header + YAML.dump(languages)) + puts "Updated language_id attributes for #{missing_count} languages" +else + puts "Whatever you want me to do, I can't figure it out. Giving up..." +end diff --git a/test/test_language.rb b/test/test_language.rb index 5613f235..5c5aa02d 100644 --- a/test/test_language.rb +++ b/test/test_language.rb @@ -67,6 +67,22 @@ class TestLanguage < Minitest::Test assert_nil Language.find_by_alias(nil) end + # Note these are set by script/set-language-ids. If these tests fail then someone + # has changed the language_id fields set in languages.yml which is almost certainly + # not what you want to happen (these fields are used in GitHub's search indexes) + def test_language_ids + assert_equal 4, Language['ANTLR'].language_id + assert_equal 54, Language['Ceylon'].language_id + assert_equal 326, Language['Ruby'].language_id + assert_equal 421, Language['xBase'].language_id + end + + def test_find_by_id + assert_equal Language['Elixir'], Language.find_by_id(100) + assert_equal Language['Ruby'], Language.find_by_id(326) + assert_equal Language['xBase'], Language.find_by_id(421) + end + def test_groups # Test a couple identity cases assert_equal Language['Perl'], Language['Perl'].group @@ -386,6 +402,22 @@ class TestLanguage < Minitest::Test assert missing.empty?, message end + def test_all_languages_have_a_language_id_set + missing = Language.all.select { |language| language.language_id.nil? } + + message = "The following languages do not have a language_id listed in languages.yml. Please add language_id fields for all new languages.\n" + missing.each { |language| message << "#{language.name}\n" } + assert missing.empty?, message + end + + def test_all_language_id_are_unique + duplicates = Language.all.group_by{ |language| language.language_id }.select { |k, v| v.size > 1 }.map(&:first) + + message = "The following language_id are used several times in languages.yml. Please use script/set-language-ids --update as per the contribution guidelines.\n" + duplicates.each { |language_id| message << "#{language_id}\n" } + assert duplicates.empty?, message + end + def test_all_languages_have_a_valid_ace_mode ace_fixture_path = File.join('test', 'fixtures', 'ace_modes.json') skip("No ace_modes.json file") unless File.exist?(ace_fixture_path) diff --git a/vendor/grammars/Docker.tmbundle b/vendor/grammars/Docker.tmbundle index 08585643..2d7d56af 160000 --- a/vendor/grammars/Docker.tmbundle +++ b/vendor/grammars/Docker.tmbundle @@ -1 +1 @@ -Subproject commit 08585643c0b84eb6f76ef56fbba7183185e65548 +Subproject commit 2d7d56af17fdf425fdebb34019b8cbd71110250a diff --git a/vendor/grammars/Handlebars b/vendor/grammars/Handlebars index 94ef9439..c07f986a 160000 --- a/vendor/grammars/Handlebars +++ b/vendor/grammars/Handlebars @@ -1 +1 @@ -Subproject commit 94ef9439d81d41a193487dda835d742b584659f4 +Subproject commit c07f986ae74c2a1eb96d856cf147ba94b8eefc90 diff --git a/vendor/grammars/MagicPython b/vendor/grammars/MagicPython index 820a9310..f4ff7de2 160000 --- a/vendor/grammars/MagicPython +++ b/vendor/grammars/MagicPython @@ -1 +1 @@ -Subproject commit 820a9310f67b452257c45332fd16433b5f63296a +Subproject commit f4ff7de27f6ff9a4f1d8e0decd3cc7145dde2fa9 diff --git a/vendor/grammars/NSIS b/vendor/grammars/NSIS index e0524002..696d06cb 160000 --- a/vendor/grammars/NSIS +++ b/vendor/grammars/NSIS @@ -1 +1 @@ -Subproject commit e052400204103acc26c14feeb624dd7ce6157611 +Subproject commit 696d06cb2bd0dfc619c989c746e4b43eea689161 diff --git a/vendor/grammars/NimLime b/vendor/grammars/NimLime index 5089ecab..2f5ec25f 160000 --- a/vendor/grammars/NimLime +++ b/vendor/grammars/NimLime @@ -1 +1 @@ -Subproject commit 5089ecab59ed3211aa482c0fb4c5881f7f7c4e9d +Subproject commit 2f5ec25fe648fb5260b0e5d845d3d88bd109b37d diff --git a/vendor/grammars/PHP-Twig.tmbundle b/vendor/grammars/PHP-Twig.tmbundle index f4f7529a..9e802d52 160000 --- a/vendor/grammars/PHP-Twig.tmbundle +++ b/vendor/grammars/PHP-Twig.tmbundle @@ -1 +1 @@ -Subproject commit f4f7529ac2a07527caa7c9154b87c96d17e18aa1 +Subproject commit 9e802d525ed87a90ec7ff842f44c0c992fd56521 diff --git a/vendor/grammars/Sublime-Inform/.gitignore b/vendor/grammars/Sublime-Inform/.gitignore deleted file mode 100644 index 9bea4330..00000000 --- a/vendor/grammars/Sublime-Inform/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ - -.DS_Store diff --git a/vendor/grammars/Sublime-Inform/Inform7/book.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/book.sublime-snippet deleted file mode 100644 index d00b609b..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/book.sublime-snippet +++ /dev/null @@ -1,6 +0,0 @@ - - - book - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/chapter.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/chapter.sublime-snippet deleted file mode 100644 index 344ae92d..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/chapter.sublime-snippet +++ /dev/null @@ -1,6 +0,0 @@ - - - chapter - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/door.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/door.sublime-snippet deleted file mode 100644 index 9504585b..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/door.sublime-snippet +++ /dev/null @@ -1,7 +0,0 @@ - - - door - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/inform7.JSON-tmLanguage b/vendor/grammars/Sublime-Inform/Inform7/inform7.JSON-tmLanguage deleted file mode 100644 index e5b6e92b..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/inform7.JSON-tmLanguage +++ /dev/null @@ -1,34 +0,0 @@ -{ "name": "Inform7", - "scopeName": "source.Inform7", - "fileTypes": ["i7x"], - "patterns": [ - { "name": "keyword.control.Inform7", - "match": "\\b(Include|Release)\\b" - }, - { "name" : "comment.block.Inform7", - "begin" : "\\[", - "end" : "\\]", - "comment" : "All comments in Inform7 are delimited this way." - }, - { "name" : "string.quoted.double.Inform7", - "begin" : "\"", - "end" : "\"", - "patterns": [ - { "name" : "keyword.operator.Inform7", - "begin" : "\\[", - "end" : "\\]", - "comment" : "For logic inside of strings." - } - ] - }, - { "name" : "storage.type.Inform7", - "match" : "(Volume|Book|Chapter|Part|Section|Table)\\s+\\d?\\s+-?\\s+((?:\\w|\\s|-)*)", - "comment": "Matches headings for major sections in Inform7" - }, - { "name": "constant.numeric.Inform7", - "match": "([0-9])+", - "comment":"Gotta call out the numbers!" - } - ], - "uuid": "0c4cbdee-beb7-4ea6-af56-27246d479373" -} \ No newline at end of file diff --git a/vendor/grammars/Sublime-Inform/Inform7/inform7.tmLanguage b/vendor/grammars/Sublime-Inform/Inform7/inform7.tmLanguage deleted file mode 100755 index 5609885e..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/inform7.tmLanguage +++ /dev/null @@ -1,74 +0,0 @@ - - - - - fileTypes - - i7x - inform - ni - - name - Inform7 - patterns - - - match - \b(Include|Release)\b - name - keyword.control.Inform7 - - - begin - \[ - comment - All comments in Inform7 are delimited this way. - end - \] - name - comment.block.Inform7 - - - begin - " - end - " - name - string.quoted.double.Inform7 - patterns - - - begin - \[ - comment - For logic inside of strings. - end - \] - name - keyword.operator.Inform7 - - - - - comment - Matches headings for major sections in Inform7 - match - (Volume|Book|Chapter|Part|Section|Table)\s+\d?\s+-?\s+((?:\w|\s|-)*) - name - storage.type.Inform7 - - - comment - Gotta call out the numbers! - match - ([0-9])+ - name - constant.numeric.Inform7 - - - scopeName - source.Inform7 - uuid - 0c4cbdee-beb7-4ea6-af56-27246d479373 - - diff --git a/vendor/grammars/Sublime-Inform/Inform7/object.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/object.sublime-snippet deleted file mode 100644 index 65f040af..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/object.sublime-snippet +++ /dev/null @@ -1,8 +0,0 @@ - - - object - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/part.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/part.sublime-snippet deleted file mode 100644 index 9e161cca..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/part.sublime-snippet +++ /dev/null @@ -1,6 +0,0 @@ - - - part - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/room.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/room.sublime-snippet deleted file mode 100644 index b6abef45..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/room.sublime-snippet +++ /dev/null @@ -1,7 +0,0 @@ - - - room - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/scene.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/scene.sublime-snippet deleted file mode 100644 index fd4be030..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/scene.sublime-snippet +++ /dev/null @@ -1,11 +0,0 @@ - - - scene - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/section.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/section.sublime-snippet deleted file mode 100644 index 7ab043cb..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/section.sublime-snippet +++ /dev/null @@ -1,6 +0,0 @@ - - - section - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/Inform7/volume.sublime-snippet b/vendor/grammars/Sublime-Inform/Inform7/volume.sublime-snippet deleted file mode 100644 index 0721fcbf..00000000 --- a/vendor/grammars/Sublime-Inform/Inform7/volume.sublime-snippet +++ /dev/null @@ -1,6 +0,0 @@ - - - volume - source.Inform7 - diff --git a/vendor/grammars/Sublime-Inform/README.md b/vendor/grammars/Sublime-Inform/README.md deleted file mode 100644 index 3b907f1e..00000000 --- a/vendor/grammars/Sublime-Inform/README.md +++ /dev/null @@ -1,8 +0,0 @@ -#Inform7 Package for Sublime Text 2 -This package has a lot of little files that make Inform7 easier to edit in Sublime Text 2. that's why it's called what it is, you see. -##Usage -Grab the zip file, unzip it, and put it in your ```Packages``` Directory. -That's pretty much it. Open an ```i7x``` file in Sublime Text 2 and it'll be all highlighted and there's a bunch of snippets you can use and all that. - -##Want to submit a pull request for this readme file? -Please, please do. \ No newline at end of file diff --git a/vendor/grammars/Sublime-SQF-Language b/vendor/grammars/Sublime-SQF-Language index 77793199..984606e1 160000 --- a/vendor/grammars/Sublime-SQF-Language +++ b/vendor/grammars/Sublime-SQF-Language @@ -1 +1 @@ -Subproject commit 777931999d391173c509018fd38e4d124063f13d +Subproject commit 984606e146b4ef96753db7f3a16adeee2b152e24 diff --git a/vendor/grammars/Sublime-VimL b/vendor/grammars/Sublime-VimL index 4b23352c..b453aff6 160000 --- a/vendor/grammars/Sublime-VimL +++ b/vendor/grammars/Sublime-VimL @@ -1 +1 @@ -Subproject commit 4b23352ce5e48a191d55d61883a9478211df91fd +Subproject commit b453aff6f783769b6b895986da605a2db0db7379 diff --git a/vendor/grammars/SublimeGDB b/vendor/grammars/SublimeGDB index 0afb64f2..d9a512da 160000 --- a/vendor/grammars/SublimeGDB +++ b/vendor/grammars/SublimeGDB @@ -1 +1 @@ -Subproject commit 0afb64f2732bfb01af97f593d4f8c977a28dc510 +Subproject commit d9a512da6eb23b8193a8696a6fc1afd77f310d6e diff --git a/vendor/grammars/TLA b/vendor/grammars/TLA index 7e351a9c..5dc130ca 160000 --- a/vendor/grammars/TLA +++ b/vendor/grammars/TLA @@ -1 +1 @@ -Subproject commit 7e351a9cdf6fbf3132e35246ce190bad237fb39c +Subproject commit 5dc130cab32ba6cf8c53e3378cd58740728f3c17 diff --git a/vendor/grammars/applescript.tmbundle b/vendor/grammars/applescript.tmbundle index bfb42697..5067ef67 160000 --- a/vendor/grammars/applescript.tmbundle +++ b/vendor/grammars/applescript.tmbundle @@ -1 +1 @@ -Subproject commit bfb426974dd4ec9adcee4094f32a14a484b2e1f3 +Subproject commit 5067ef67a58f6f56a54460be1390d921bb400d45 diff --git a/vendor/grammars/atom-language-1c-bsl b/vendor/grammars/atom-language-1c-bsl new file mode 160000 index 00000000..787ea4fd --- /dev/null +++ b/vendor/grammars/atom-language-1c-bsl @@ -0,0 +1 @@ +Subproject commit 787ea4fd3ac7239325ca35341fb74b01284125dd diff --git a/vendor/grammars/atom-language-purescript b/vendor/grammars/atom-language-purescript index 83d18810..fc8b0bf9 160000 --- a/vendor/grammars/atom-language-purescript +++ b/vendor/grammars/atom-language-purescript @@ -1 +1 @@ -Subproject commit 83d188103fa2544fe037e3634c26ab6bbeb85b3e +Subproject commit fc8b0bf9da61886c6e3973c2d37e6aef88fabfb2 diff --git a/vendor/grammars/atom-language-stan b/vendor/grammars/atom-language-stan index 2fa2745d..0a79d383 160000 --- a/vendor/grammars/atom-language-stan +++ b/vendor/grammars/atom-language-stan @@ -1 +1 @@ -Subproject commit 2fa2745da7ab9de0ba42a9743d1942becb5e4c32 +Subproject commit 0a79d383b7e94fefb242e967d708e054faf656cd diff --git a/vendor/grammars/awk-sublime b/vendor/grammars/awk-sublime index 7ec7d154..72b487a1 160000 --- a/vendor/grammars/awk-sublime +++ b/vendor/grammars/awk-sublime @@ -1 +1 @@ -Subproject commit 7ec7d154469c05780cfeecca8fc00fda6f9ac0e7 +Subproject commit 72b487a1046d86b8a195b38fa18802d2abe30370 diff --git a/vendor/grammars/blitzmax b/vendor/grammars/blitzmax new file mode 160000 index 00000000..7ee21081 --- /dev/null +++ b/vendor/grammars/blitzmax @@ -0,0 +1 @@ +Subproject commit 7ee210811a19436f978c272266c484bbc5e36d95 diff --git a/vendor/grammars/c.tmbundle b/vendor/grammars/c.tmbundle index d26c3516..88cc9b71 160000 --- a/vendor/grammars/c.tmbundle +++ b/vendor/grammars/c.tmbundle @@ -1 +1 @@ -Subproject commit d26c35164a4d496fd2c0b4ea0c1aeed64d704702 +Subproject commit 88cc9b71faf9f1406c5a6a5b08741e6242c15e06 diff --git a/vendor/grammars/css.tmbundle b/vendor/grammars/css.tmbundle index 94f7111c..d79e9c01 160000 --- a/vendor/grammars/css.tmbundle +++ b/vendor/grammars/css.tmbundle @@ -1 +1 @@ -Subproject commit 94f7111c2953ac7b4cc42d313d9ad9b8701b8468 +Subproject commit d79e9c013769386a765198f7fb0f9dce39da829b diff --git a/vendor/grammars/cython b/vendor/grammars/cython new file mode 160000 index 00000000..e9f4d3a1 --- /dev/null +++ b/vendor/grammars/cython @@ -0,0 +1 @@ +Subproject commit e9f4d3a1e44a14df8f245f98591f62df34fbabd8 diff --git a/vendor/grammars/d.tmbundle b/vendor/grammars/d.tmbundle index e4beff2c..080e5343 160000 --- a/vendor/grammars/d.tmbundle +++ b/vendor/grammars/d.tmbundle @@ -1 +1 @@ -Subproject commit e4beff2ce50afecab1438f0013977fadf89f8a39 +Subproject commit 080e5343d8979d2b9c0502e80ac82d906bb7996f diff --git a/vendor/grammars/diff.tmbundle b/vendor/grammars/diff.tmbundle index 62de2cca..372abaae 160000 --- a/vendor/grammars/diff.tmbundle +++ b/vendor/grammars/diff.tmbundle @@ -1 +1 @@ -Subproject commit 62de2cca5cc5cfb77308fdc94d963f35e2d808d1 +Subproject commit 372abaaeb12620db3f9d5d984c4ee8c3c6224117 diff --git a/vendor/grammars/ebundles b/vendor/grammars/ebundles deleted file mode 160000 index d9b80213..00000000 --- a/vendor/grammars/ebundles +++ /dev/null @@ -1 +0,0 @@ -Subproject commit d9b802135a533abf113c164d25b23143a47283e7 diff --git a/vendor/grammars/elixir-tmbundle b/vendor/grammars/elixir-tmbundle index 6ee8051a..6d0417e8 160000 --- a/vendor/grammars/elixir-tmbundle +++ b/vendor/grammars/elixir-tmbundle @@ -1 +1 @@ -Subproject commit 6ee8051a75cd9bc7f20e08f2fde4475e95e9c67a +Subproject commit 6d0417e8eb7e182810755214d0a8cd6421146c01 diff --git a/vendor/grammars/forth b/vendor/grammars/forth new file mode 160000 index 00000000..0cf0ec91 --- /dev/null +++ b/vendor/grammars/forth @@ -0,0 +1 @@ +Subproject commit 0cf0ec91f65717903b41ea6cd62f6cd17788f0d0 diff --git a/vendor/grammars/haskell.tmbundle b/vendor/grammars/haskell.tmbundle deleted file mode 160000 index df3d5427..00000000 --- a/vendor/grammars/haskell.tmbundle +++ /dev/null @@ -1 +0,0 @@ -Subproject commit df3d54278a3ab3cfb30c37d94e06587478cc79ad diff --git a/vendor/grammars/html.tmbundle b/vendor/grammars/html.tmbundle index 2e9e024a..9f812c89 160000 --- a/vendor/grammars/html.tmbundle +++ b/vendor/grammars/html.tmbundle @@ -1 +1 @@ -Subproject commit 2e9e024a1b20c8bf8e68ba241359b4bbdb1045e1 +Subproject commit 9f812c89f4990a98391701caa77824c94860538f diff --git a/vendor/grammars/jade-tmbundle b/vendor/grammars/jade-tmbundle index 7c1304aa..f311a516 160000 --- a/vendor/grammars/jade-tmbundle +++ b/vendor/grammars/jade-tmbundle @@ -1 +1 @@ -Subproject commit 7c1304aa5a0d916a93fd296d3dd994219ecdc90f +Subproject commit f311a516bb29296fcebfdc7da8149b1c79dfb0a1 diff --git a/vendor/grammars/java.tmbundle b/vendor/grammars/java.tmbundle index 64294ae0..faffa518 160000 --- a/vendor/grammars/java.tmbundle +++ b/vendor/grammars/java.tmbundle @@ -1 +1 @@ -Subproject commit 64294ae0b62b64b1183c401e3803679eaddb4946 +Subproject commit faffa518d0b22b68b4e5e6b4c939722522b97d40 diff --git a/vendor/grammars/json.tmbundle b/vendor/grammars/json.tmbundle index 0762cbdc..563b6f62 160000 --- a/vendor/grammars/json.tmbundle +++ b/vendor/grammars/json.tmbundle @@ -1 +1 @@ -Subproject commit 0762cbdcb34dd98801b6323e75332cd4c9dbc07e +Subproject commit 563b6f629bcf2c77d239b03fa768f869a4cba368 diff --git a/vendor/grammars/language-asn1 b/vendor/grammars/language-asn1 new file mode 160000 index 00000000..d45daeb8 --- /dev/null +++ b/vendor/grammars/language-asn1 @@ -0,0 +1 @@ +Subproject commit d45daeb849f02a79d67585f629bdc83a06cc52e5 diff --git a/vendor/grammars/language-babel b/vendor/grammars/language-babel index 0d093e8f..656d5d3b 160000 --- a/vendor/grammars/language-babel +++ b/vendor/grammars/language-babel @@ -1 +1 @@ -Subproject commit 0d093e8ffeaa80602c6f3ae86fade6a3b5f56e4d +Subproject commit 656d5d3b42e317f28c7fce248709abda6fc70b95 diff --git a/vendor/grammars/language-batchfile b/vendor/grammars/language-batchfile new file mode 160000 index 00000000..100b6829 --- /dev/null +++ b/vendor/grammars/language-batchfile @@ -0,0 +1 @@ +Subproject commit 100b682992acf511ab330de2c54b8c42493964e4 diff --git a/vendor/grammars/language-blade b/vendor/grammars/language-blade index 50dcfb72..fcbe2c20 160000 --- a/vendor/grammars/language-blade +++ b/vendor/grammars/language-blade @@ -1 +1 @@ -Subproject commit 50dcfb72af30b267c4397f21742d79e4d564642f +Subproject commit fcbe2c202295ba1b3f3d2156b64a82999f51374d diff --git a/vendor/grammars/language-clojure b/vendor/grammars/language-clojure index d41af288..51484ae2 160000 --- a/vendor/grammars/language-clojure +++ b/vendor/grammars/language-clojure @@ -1 +1 @@ -Subproject commit d41af288008c6857198a3734d9f27e4f2f6650c5 +Subproject commit 51484ae2f76b59fe0ea4688a1b27d127d392bd07 diff --git a/vendor/grammars/language-coffee-script b/vendor/grammars/language-coffee-script index 9ebf4740..8f001efe 160000 --- a/vendor/grammars/language-coffee-script +++ b/vendor/grammars/language-coffee-script @@ -1 +1 @@ -Subproject commit 9ebf474016d7e984bfe40e36d7f5ea774dc1e4b9 +Subproject commit 8f001efe73422d0f7a0c16121588c34e0bd5fe8c diff --git a/vendor/grammars/language-crystal b/vendor/grammars/language-crystal index ec1e4991..0d7ac572 160000 --- a/vendor/grammars/language-crystal +++ b/vendor/grammars/language-crystal @@ -1 +1 @@ -Subproject commit ec1e4991e6647da9ca2c5337b795700c1f6ee7e4 +Subproject commit 0d7ac572e4628adf5206b03af9fc45cdd815476a diff --git a/vendor/grammars/language-csharp b/vendor/grammars/language-csharp index b3f1130b..c97c4bf7 160000 --- a/vendor/grammars/language-csharp +++ b/vendor/grammars/language-csharp @@ -1 +1 @@ -Subproject commit b3f1130b1ae7f0bab2763d45926033aba92fb48c +Subproject commit c97c4bf74d74502c0b78901b12aab09186dc0eba diff --git a/vendor/grammars/language-csound b/vendor/grammars/language-csound index f5c603ac..29d8eca1 160000 --- a/vendor/grammars/language-csound +++ b/vendor/grammars/language-csound @@ -1 +1 @@ -Subproject commit f5c603ac1168972d252a60edac2fab5dd3470b40 +Subproject commit 29d8eca1a8366295b9c7f052cbc667983d337a75 diff --git a/vendor/grammars/language-emacs-lisp b/vendor/grammars/language-emacs-lisp new file mode 160000 index 00000000..76ec86a3 --- /dev/null +++ b/vendor/grammars/language-emacs-lisp @@ -0,0 +1 @@ +Subproject commit 76ec86a3eb1bc819a4f19de7295a19602a935c09 diff --git a/vendor/grammars/language-gfm b/vendor/grammars/language-gfm index 54359235..a55c18c3 160000 --- a/vendor/grammars/language-gfm +++ b/vendor/grammars/language-gfm @@ -1 +1 @@ -Subproject commit 54359235212c921d4e09ed38575a9e9eb95635b8 +Subproject commit a55c18c3dc4d3fa9e5fb87fab0b0976b87526cbd diff --git a/vendor/grammars/language-graphql b/vendor/grammars/language-graphql index 037e5d46..4be0d1ae 160000 --- a/vendor/grammars/language-graphql +++ b/vendor/grammars/language-graphql @@ -1 +1 @@ -Subproject commit 037e5d46ea7c5eeeac412192ab8a3cf72157be2d +Subproject commit 4be0d1ae7b847182d4a743f43f44416d7f7d6423 diff --git a/vendor/grammars/language-haskell b/vendor/grammars/language-haskell new file mode 160000 index 00000000..296a7e94 --- /dev/null +++ b/vendor/grammars/language-haskell @@ -0,0 +1 @@ +Subproject commit 296a7e94df6b3c89c5247510b7ba4eb71f14c55f diff --git a/vendor/grammars/language-javascript b/vendor/grammars/language-javascript index 83f9e51b..b3d2bb64 160000 --- a/vendor/grammars/language-javascript +++ b/vendor/grammars/language-javascript @@ -1 +1 @@ -Subproject commit 83f9e51bc96b56d392e603c6efbbfba453e7c4a7 +Subproject commit b3d2bb649a2a2b2f1e8bf391bcd50c603ac1e127 diff --git a/vendor/grammars/language-less b/vendor/grammars/language-less index 234fd8a3..d4f5db5f 160000 --- a/vendor/grammars/language-less +++ b/vendor/grammars/language-less @@ -1 +1 @@ -Subproject commit 234fd8a37be054209a7e1726c29923f4171a2f90 +Subproject commit d4f5db5fba671244c1f2085752d1ea9ce34f8bad diff --git a/vendor/grammars/language-python b/vendor/grammars/language-python index d5ae6974..719e4404 160000 --- a/vendor/grammars/language-python +++ b/vendor/grammars/language-python @@ -1 +1 @@ -Subproject commit d5ae69749bde41cc9da8020786106958f376ef5b +Subproject commit 719e4404d2cd25a888a8111c62abd31a22a15ef3 diff --git a/vendor/grammars/language-renpy b/vendor/grammars/language-renpy index 883f51f4..a3b9bbed 160000 --- a/vendor/grammars/language-renpy +++ b/vendor/grammars/language-renpy @@ -1 +1 @@ -Subproject commit 883f51f4ef5d310121e45d30205f96d3ade4c248 +Subproject commit a3b9bbed668137ab8db5dbafea4d5611957e68ee diff --git a/vendor/grammars/language-restructuredtext b/vendor/grammars/language-restructuredtext index 71336125..f4f931ab 160000 --- a/vendor/grammars/language-restructuredtext +++ b/vendor/grammars/language-restructuredtext @@ -1 +1 @@ -Subproject commit 71336125686fc61e26da1f0b6642930295b467de +Subproject commit f4f931ab7fd2ee4c07db35d3b884c14585da6e3f diff --git a/vendor/grammars/language-roff b/vendor/grammars/language-roff new file mode 160000 index 00000000..f37fb6b7 --- /dev/null +++ b/vendor/grammars/language-roff @@ -0,0 +1 @@ +Subproject commit f37fb6b7c45837de47cdb0bcb9e7a5a257b1ea24 diff --git a/vendor/grammars/language-rpm-spec b/vendor/grammars/language-rpm-spec new file mode 160000 index 00000000..549b4241 --- /dev/null +++ b/vendor/grammars/language-rpm-spec @@ -0,0 +1 @@ +Subproject commit 549b4241074bfb81557173377efb6681673648ac diff --git a/vendor/grammars/language-shellscript b/vendor/grammars/language-shellscript index 8019ad83..6d66ca58 160000 --- a/vendor/grammars/language-shellscript +++ b/vendor/grammars/language-shellscript @@ -1 +1 @@ -Subproject commit 8019ad833cc55cec04e8fd89d492b66702c6884f +Subproject commit 6d66ca58c030a9509b9e01ce57456511c529eb6a diff --git a/vendor/grammars/language-toc-wow b/vendor/grammars/language-toc-wow index f538862f..03e7c2a0 160000 --- a/vendor/grammars/language-toc-wow +++ b/vendor/grammars/language-toc-wow @@ -1 +1 @@ -Subproject commit f538862fdd122f249c414d4d5b76f3c8d3b4d94d +Subproject commit 03e7c2a02f2c3b2b0101929547768af5a88a7ddf diff --git a/vendor/grammars/language-yaml b/vendor/grammars/language-yaml index 9f55beb6..784cecc6 160000 --- a/vendor/grammars/language-yaml +++ b/vendor/grammars/language-yaml @@ -1 +1 @@ -Subproject commit 9f55beb63517483971d256d521e30a7fb0b2bcc0 +Subproject commit 784cecc64ffdb891f6a7fbba62e476b0c833e66f diff --git a/vendor/grammars/latex.tmbundle b/vendor/grammars/latex.tmbundle index a5c14e1c..b973d17a 160000 --- a/vendor/grammars/latex.tmbundle +++ b/vendor/grammars/latex.tmbundle @@ -1 +1 @@ -Subproject commit a5c14e1ce9f29ceac4efd6578e03a12fe99e8cf8 +Subproject commit b973d17a03744d8184689c37d5b9be1511bb3b21 diff --git a/vendor/grammars/less.tmbundle/Commands/Save to CSS.tmCommand b/vendor/grammars/less.tmbundle/Commands/Save to CSS.tmCommand deleted file mode 100644 index 9f8e7561..00000000 --- a/vendor/grammars/less.tmbundle/Commands/Save to CSS.tmCommand +++ /dev/null @@ -1,47 +0,0 @@ - - - - - beforeRunningCommand - saveActiveFile - command - #!/usr/bin/env ruby18 - -file = ENV["TM_FILEPATH"] -target = file.sub(/\.less$/, ".css") -system("lessc \"#{file}\" \"#{target}\"") -puts "Compiled CSS to '#{target}'" - input - document - inputFormat - text - keyEquivalent - @b - name - Save to CSS - outputCaret - afterOutput - outputFormat - text - outputLocation - toolTip - requiredCommands - - - command - lessc - locations - - /opt/local/bin/lessc - /usr/local/bin/lessc - - - - scope - source.css.less - uuid - 78788223-5E5E-434E-98BE-17BCDF600611 - version - 2 - - diff --git a/vendor/grammars/less.tmbundle/Commands/Save to Minified CSS.tmCommand b/vendor/grammars/less.tmbundle/Commands/Save to Minified CSS.tmCommand deleted file mode 100644 index fc8fe21f..00000000 --- a/vendor/grammars/less.tmbundle/Commands/Save to Minified CSS.tmCommand +++ /dev/null @@ -1,47 +0,0 @@ - - - - - beforeRunningCommand - saveActiveFile - command - #!/usr/bin/env ruby18 - -file = ENV["TM_FILEPATH"] -target = file.sub(/\.less$/, ".css") -system("lessc -x \"#{file}\" \"#{target}\"") -puts "Compiled Minified CSS to '#{target}'" - input - document - inputFormat - text - keyEquivalent - ~@b - name - Save to Minified CSS - outputCaret - afterOutput - outputFormat - text - outputLocation - toolTip - requiredCommands - - - command - lessc - locations - - /opt/local/bin/lessc - /usr/local/bin/lessc - - - - scope - source.css.less - uuid - 448D3A8D-260E-4949-BA33-654886ECDCAF - version - 2 - - diff --git a/vendor/grammars/less.tmbundle/DragCommands/Insert inline Image.tmDragCommand b/vendor/grammars/less.tmbundle/DragCommands/Insert inline Image.tmDragCommand deleted file mode 100644 index 21ce88f4..00000000 --- a/vendor/grammars/less.tmbundle/DragCommands/Insert inline Image.tmDragCommand +++ /dev/null @@ -1,38 +0,0 @@ - - - - - beforeRunningCommand - nop - command - #!/usr/bin/env php -<?php -$path = getenv('TM_DROPPED_FILE'); -$path_parts = pathinfo($path); -$info = getimagesize($path); -list($width, $height) = $info; -$mime = $info['mime']; -$contents = base64_encode(file_get_contents($path)); - -echo "@gfx-{$path_parts['filename']}: \"data:{$mime};base64,{$contents}\";\n"; -echo "@gfx-{$path_parts['filename']}-width: {$width}px;\n"; -echo "@gfx-{$path_parts['filename']}-height: {$height}px;"; - draggedFileExtensions - - png - jpeg - jpg - gif - - input - selection - name - Insert inline Image - output - insertAsSnippet - scope - source.css.less - uuid - 7B0CA307-CC1C-4EE2-9F63-4825800ACDA7 - - diff --git a/vendor/grammars/less.tmbundle/Preferences/Comment.tmPreferences b/vendor/grammars/less.tmbundle/Preferences/Comment.tmPreferences deleted file mode 100644 index 1d8bf1fe..00000000 --- a/vendor/grammars/less.tmbundle/Preferences/Comment.tmPreferences +++ /dev/null @@ -1,36 +0,0 @@ - - - - - name - Comments - scope - source.css.less - settings - - shellVariables - - - name - TM_COMMENT_START - value - // - - - name - TM_COMMENT_START_2 - value - /* - - - name - TM_COMMENT_END_2 - value - */ - - - - uuid - D0CC551B-751D-4A7C-A738-2513E3C7F285 - - diff --git a/vendor/grammars/less.tmbundle/Syntaxes/LESS.tmLanguage b/vendor/grammars/less.tmbundle/Syntaxes/LESS.tmLanguage deleted file mode 100644 index ac6ff8ba..00000000 --- a/vendor/grammars/less.tmbundle/Syntaxes/LESS.tmLanguage +++ /dev/null @@ -1,434 +0,0 @@ - - - - - comment - LeSS - fileTypes - - less - - foldingStartMarker - /\*\*(?!\*)|\{\s*($|/\*(?!.*?\*/.*\S)) - foldingStopMarker - (?<!\*)\*\*/|^\s*\} - keyEquivalent - ^~L - name - LESS - patterns - - - match - \b(a|abbr|acronym|address|applet|article|area|audio|video|b|base|big|blockquote|body|br|button|caption|canvas|center|cite|code|col|colgroup|dd|del|details|dfn|div|dl|dt|em|embed|fieldset|figure|figcaption|form|frame|frameset|(h[1-6])|head|hr|html|i|iframe|img|input|ins|kbd|label|legend|li|link|map|mark|meta|menu|nav|noframes|noscript|object|ol|optgroup|option|output|p|param|pre|q|ruby|s|samp|script|select|small|span|strike|strong|style|sub|sup|summary|svg|table|tbody|td|textarea|tfoot|th|thead|title|tr|tt|u|ul|var|header|section|footer|aside|hgroup|time)\b - name - keyword.control.html.elements - - - begin - " - beginCaptures - - 0 - - name - punctuation.definition.string.begin.css - - - end - " - endCaptures - - 0 - - name - punctuation.definition.string.end.css - - - name - string.quoted.double.css - patterns - - - match - \\. - name - constant.character.escaped.css - - - - - begin - ' - beginCaptures - - 0 - - name - punctuation.definition.string.begin.css - - - end - ' - endCaptures - - 0 - - name - punctuation.definition.string.end.css - - - name - string.quoted.single.css - patterns - - - match - \\. - name - constant.character.escaped.css - - - - - captures - - 1 - - name - entity.other.attribute-name.class.css - - - match - (\.[a-zA-Z0-9_-]+) - - - begin - url\( - contentName - variable.parameter.url - end - \) - name - support.function.any-method.builtin.css - - - match - (#)([0-9a-fA-F]{3}|[0-9a-fA-F]{6})\b - name - constant.other.rgb-value.css - - - captures - - 0 - - name - entity.other.attribute-name.id - - - match - #[a-zA-Z0-9_:\(\)-]+ - name - meta.selector.css - - - begin - /\* - beginCaptures - - 0 - - name - punctuation.definition.comment.begin.css - - - end - \*/ - endCaptures - - 0 - - name - punctuation.definition.comment.end.css - - - name - comment.block.css - - - match - (-|\+)?\s*[0-9]+(\.[0-9]+)? - name - constant.numeric.css - - - match - (?<=[\d])(px|pt|cm|mm|in|em|ex|pc)\b|% - name - keyword.other.unit.css - - - captures - - 1 - - name - entity.other.attribute-name.pseudo-element.css - - - match - (:+(after|before|not|last-child|nth-of-type|nth-child|first-child|first-letter|first-line|selection|root)) - - - captures - - 1 - - name - entity.other.attribute-name.pseudo-class.css - - - match - (:+(active|hover|link|visited|focus)) - - - captures - - 1 - - name - punctuation.definition.entity.css - - 2 - - name - entity.other.attribute-name.attribute.css - - 3 - - name - punctuation.separator.operator.css - - 4 - - name - string.unquoted.attribute-value.css - - 5 - - name - string.quoted.double.attribute-value.css - - 6 - - name - punctuation.definition.string.begin.css - - 7 - - name - punctuation.definition.string.end.css - - - match - (?i)(\[)\s*(-?[_a-z\\[[:^ascii:]]][_a-z0-9\-\\[[:^ascii:]]]*)(?:\s*([~|^$*]?=)\s*(?:(-?[_a-z\\[[:^ascii:]]][_a-z0-9\-\\[[:^ascii:]]]*)|((?>(['"])(?:[^\\]|\\.)*?(\6)))))?\s*(\]) - name - meta.attribute-selector.css - - - captures - - 1 - - name - keyword.control.at-rule.import.css - - 2 - - name - punctuation.definition.keyword.css - - - match - ^\s*((@)import\b) - name - meta.at-rule.import.css - - - captures - - 1 - - name - support.type.property-name.css.vendor - - - match - (-(?:webkit|moz|khtml|o|icab|ms)-(?:background-size|border-radius|box-shadow|opacity|border-image))\s*: - - - captures - - 1 - - name - support.type.property-name.css - - - match - \b(azimuth|background-attachment|background-color|background-clip|background-image|background-position|background-repeat|background-size|background|behavior|border-bottom-color|border-bottom-style|border-bottom-width|border-bottom|border-collapse|border-color|border-left-color|border-left-style|border-left-width|border-left|border-right-color|border-right-style|border-right-width|border-right|border-spacing|border-style|border-top-color|border-top-style|border-top-width|border-top|border-width|border-radius|border|box-shadow|bottom|caption-side|clear|clip|color|content|counter-increment|counter-reset|cue-after|cue-before|cue|cursor|direction|display|elevation|empty-cells|filter|float|font-family|font-size-adjust|font-size|font-stretch|font-style|font-variant|font-weight|font|height|left|letter-spacing|line-height|list-style-image|list-style-position|list-style-type|list-style|margin-bottom|margin-left|margin-right|margin-top|marker-offset|margin|marks|max-height|max-width|min-height|min-width|opacity|orphans|outline-color|outline-style|outline-width|outline|overflow(-[xy])?|padding-bottom|padding-left|padding-right|padding-top|padding|page-break-after|page-break-before|page-break-inside|page|pause-after|pause-before|pause|pitch-range|pitch|play-during|position|pre-wrap|quotes|richness|right|size|speak-header|speak-numeral|speak-punctuation|speech-rate|speak|stress|table-layout|text-align|text-decoration|text-indent|text-shadow|text-transform|top|unicode-bidi|vertical-align|visibility|voice-family|volume|white-space|widows|width|word-spacing|word-wrap|z-index|zoom) - - - match - \b(absolute|all-scroll|always|auto|baseline|below|bidi-override|block|bold|bolder|both|bottom|break-all|break-word|capitalize|center|char|circle|col-resize|collapse|crosshair|dashed|decimal|default|disabled|disc|distribute-all-lines|distribute-letter|distribute-space|distribute|dotted|double|e-resize|ellipsis|fixed|groove|hand|help|hidden|horizontal|ideograph-alpha|ideograph-numeric|ideograph-parenthesis|ideograph-space|inactive|inherit|inline-block|inline|inset|inside|inter-ideograph|inter-word|italic|justify|keep-all|left|lighter|line-edge|line-through|line|linear|list-item|loose|lower-alpha|lower-roman|lowercase|lr-tb|ltr|medium|middle|move|n-resize|ne-resize|newspaper|no-drop|no-repeat|nw-resize|none|normal|not-allowed|nowrap|oblique|outset|outside|overline|pointer|progress|relative|repeat-x|repeat-y|repeat|right|ridge|row-resize|rtl|s-resize|scroll|se-resize|separate|small-caps|solid|square|static|strict|super|sw-resize|table-footer-group|table-header-group|tb-rl|text-bottom|text-top|text|thick|thin|top|transparent|underline|upper-alpha|upper-roman|uppercase|vertical-ideographic|vertical-text|visible|w-resize|wait|whitespace|padding-box)\b - name - support.constant.property-value.css - - - match - (\b(?i:arial|century|comic|courier|garamond|georgia|helvetica|impact|lucida|symbol|system|tahoma|times|trebuchet|utopia|verdana|webdings|sans-serif|serif|monospace)\b) - name - support.constant.font-name.css - - - comment - http://www.w3.org/TR/CSS21/syndata.html#value-def-color - match - \b(aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow)\b - name - support.constant.color.w3c-standard-color-name.css - - - match - \b(saturate|desaturate|lighten|darken|grayscale)\b - name - support.function.any-method.builtin.less - - - match - \b(rgb|rgba|hsl|hsla|url)\b - name - support.function.any-method.builtin.css - - - captures - - 1 - - name - support.function.any-method.vendor.css - - - match - (-(?:webkit|moz|khtml|o|icab)-(?:gradient|linear-gradient)) - - - match - \b(color-stop|from|to)\b - name - support.function.any-method.webkit.gradient.css - - - captures - - 1 - - name - support.function.less - - - match - (\.[a-zA-Z0-9_-]+)\s*(;|\() - - - begin - (^[ \t]+)?(?=//) - beginCaptures - - 1 - - name - punctuation.whitespace.comment.leading.less - - - end - (?!\G) - patterns - - - begin - // - beginCaptures - - 0 - - name - punctuation.definition.comment.less - - - end - \n - name - comment.line.double-slash.less - - - - - match - @[a-zA-Z0-9_-][\w-]* - name - variable.other.less - - - match - \$|%|&|\*|\-\-|\-|\+\+|\+|~|===|==|=|!=|!==|<=|>=|<<=|>>=|>>>=|<>|<|>|!|&&|\|\||\?\:|\*=|(?<!\()/=|%=|\+=|\-=|&=|\^=|\/\b - name - keyword.operator.less - - - captures - - 1 - - name - punctuation.section.property-list.begin.css - - 2 - - name - punctuation.section.property-list.end.css - - - comment - Match empty braces to give proper ↩ action - match - (\{)(\}) - name - meta.brace.curly.less - - - match - \{|\} - name - meta.brace.curly.less - - - match - \(|\) - name - meta.brace.round.less - - - match - \[|\] - name - meta.brace.square.less - - - scopeName - source.css.less - uuid - 9343D324-75A1-4733-A5C0-5D1D4B6182D0 - - diff --git a/vendor/grammars/less.tmbundle/info.plist b/vendor/grammars/less.tmbundle/info.plist deleted file mode 100644 index e555f0ba..00000000 --- a/vendor/grammars/less.tmbundle/info.plist +++ /dev/null @@ -1,26 +0,0 @@ - - - - - contactEmailRot13 - zfurrgf@juvgrsnyyf.bet - contactName - Michael Sheets - description - Extends CSS with dynamic behavior such as variables, mixins, operations and functions. - mainMenu - - items - - 78788223-5E5E-434E-98BE-17BCDF600611 - 448D3A8D-260E-4949-BA33-654886ECDCAF - - submenus - - - name - LESS - uuid - D1D51EE5-E89F-4B14-8AE4-FC364E540B47 - - diff --git a/vendor/grammars/objective-c.tmbundle b/vendor/grammars/objective-c.tmbundle index fdcedb95..d80c2bbd 160000 --- a/vendor/grammars/objective-c.tmbundle +++ b/vendor/grammars/objective-c.tmbundle @@ -1 +1 @@ -Subproject commit fdcedb95de8846220c49f769fee91045188767d9 +Subproject commit d80c2bbdef8433b3d2cf0af660ea460d97009735 diff --git a/vendor/grammars/parrot b/vendor/grammars/parrot new file mode 160000 index 00000000..b56e8413 --- /dev/null +++ b/vendor/grammars/parrot @@ -0,0 +1 @@ +Subproject commit b56e84139f2a8b75aa199a990d340b9a0463de16 diff --git a/vendor/grammars/pawn-sublime-language b/vendor/grammars/pawn-sublime-language index 879fae61..2940b429 160000 --- a/vendor/grammars/pawn-sublime-language +++ b/vendor/grammars/pawn-sublime-language @@ -1 +1 @@ -Subproject commit 879fae615707c5b0073d6ac9a28b701eb14a57b1 +Subproject commit 2940b429a66f300ccf07020e63a799afab6522bd diff --git a/vendor/grammars/r.tmbundle b/vendor/grammars/r.tmbundle index 44691a07..d005a0f1 160000 --- a/vendor/grammars/r.tmbundle +++ b/vendor/grammars/r.tmbundle @@ -1 +1 @@ -Subproject commit 44691a07734715b11a130a4af409508f53f83aa1 +Subproject commit d005a0f1055020757b797e4959d1b43ece3708aa diff --git a/vendor/grammars/ruby-slim.tmbundle b/vendor/grammars/ruby-slim.tmbundle index 7452b27e..2016357d 160000 --- a/vendor/grammars/ruby-slim.tmbundle +++ b/vendor/grammars/ruby-slim.tmbundle @@ -1 +1 @@ -Subproject commit 7452b27ea4aa8cbe19d99bd92aa40ac3560c6a93 +Subproject commit 2016357d9ca16b8c3e8c2aa9ac0a48ed46f27adb diff --git a/vendor/grammars/sas.tmbundle b/vendor/grammars/sas.tmbundle index 012368ab..776b5477 160000 --- a/vendor/grammars/sas.tmbundle +++ b/vendor/grammars/sas.tmbundle @@ -1 +1 @@ -Subproject commit 012368ab93235a4e4ff70785aaf2cbf5017e13fe +Subproject commit 776b54772b27f6f30be714fbabf9eb9abba3d013 diff --git a/vendor/grammars/secondlife-lsl b/vendor/grammars/secondlife-lsl new file mode 160000 index 00000000..ee359d63 --- /dev/null +++ b/vendor/grammars/secondlife-lsl @@ -0,0 +1 @@ +Subproject commit ee359d634c9d31f1d66bac416db626ddd11d39ed diff --git a/vendor/grammars/smali-sublime b/vendor/grammars/smali-sublime index 60a1fdb3..5bcea806 160000 --- a/vendor/grammars/smali-sublime +++ b/vendor/grammars/smali-sublime @@ -1 +1 @@ -Subproject commit 60a1fdb3442cd7082036f1a02e403a5f725ed837 +Subproject commit 5bcea806cf69a6ebce799b0995bdfd4d7865989e diff --git a/vendor/grammars/sourcepawn b/vendor/grammars/sourcepawn index 294d3ba0..d5e1022a 160000 --- a/vendor/grammars/sourcepawn +++ b/vendor/grammars/sourcepawn @@ -1 +1 @@ -Subproject commit 294d3ba0972f0456d9d3f554dcd8f97b51aa4d40 +Subproject commit d5e1022a4e09cdba32b416e682a2c31c72240733 diff --git a/vendor/grammars/sublime-autoit b/vendor/grammars/sublime-autoit index d4e742a7..6d87c55f 160000 --- a/vendor/grammars/sublime-autoit +++ b/vendor/grammars/sublime-autoit @@ -1 +1 @@ -Subproject commit d4e742a73afc8eb249f64736c43cb4976cafe9c8 +Subproject commit 6d87c55fd089950a456c864ce50f7d227f2bb06a diff --git a/vendor/grammars/sublime-rexx b/vendor/grammars/sublime-rexx new file mode 160000 index 00000000..a649cf3a --- /dev/null +++ b/vendor/grammars/sublime-rexx @@ -0,0 +1 @@ +Subproject commit a649cf3aefdade911e71f3cf086678c16b47fbbd diff --git a/vendor/grammars/sublime-rust b/vendor/grammars/sublime-rust index 167018cc..d3c63dec 160000 --- a/vendor/grammars/sublime-rust +++ b/vendor/grammars/sublime-rust @@ -1 +1 @@ -Subproject commit 167018cc0f76f51e3911c40af8faf914cb48f66f +Subproject commit d3c63dec579be852b1d8006dc58a9a6f2a9e6cdc diff --git a/vendor/grammars/sublime-typescript b/vendor/grammars/sublime-typescript index 0d538fc7..cfe1d982 160000 --- a/vendor/grammars/sublime-typescript +++ b/vendor/grammars/sublime-typescript @@ -1 +1 @@ -Subproject commit 0d538fc74884c812eece814acbe32e9bd8e28a3f +Subproject commit cfe1d982384e2434bfea0cc5159387d942f8f2e6 diff --git a/vendor/grammars/sublime_man_page_support b/vendor/grammars/sublime_man_page_support deleted file mode 160000 index f3568e9e..00000000 --- a/vendor/grammars/sublime_man_page_support +++ /dev/null @@ -1 +0,0 @@ -Subproject commit f3568e9e61c344cb91e926665ec714adb34ed24c diff --git a/vendor/grammars/swift.tmbundle b/vendor/grammars/swift.tmbundle index 662fd22b..b3cb4372 160000 --- a/vendor/grammars/swift.tmbundle +++ b/vendor/grammars/swift.tmbundle @@ -1 +1 @@ -Subproject commit 662fd22bf8e6d2ed1dfcb5881c23838bad620404 +Subproject commit b3cb4372f2e63175c72eaa6e94af2eb52bb6a9db diff --git a/vendor/grammars/vhdl b/vendor/grammars/vhdl new file mode 160000 index 00000000..e88be218 --- /dev/null +++ b/vendor/grammars/vhdl @@ -0,0 +1 @@ +Subproject commit e88be21845912df5622854747117930b302df8fd diff --git a/vendor/grammars/vue-syntax-highlight b/vendor/grammars/vue-syntax-highlight index a29a875b..909afa53 160000 --- a/vendor/grammars/vue-syntax-highlight +++ b/vendor/grammars/vue-syntax-highlight @@ -1 +1 @@ -Subproject commit a29a875bf3e81f780e905c223a96261c04732659 +Subproject commit 909afa5384d6dcd01f7d883fe2b8b6067f970a26 diff --git a/vendor/grammars/xquery b/vendor/grammars/xquery new file mode 160000 index 00000000..19080949 --- /dev/null +++ b/vendor/grammars/xquery @@ -0,0 +1 @@ +Subproject commit 19080949463e8eb6fca5ac94d597007a7c3605f8 diff --git a/vendor/licenses/grammar/atom-language-1c-bsl.txt b/vendor/licenses/grammar/atom-language-1c-bsl.txt new file mode 100644 index 00000000..b1f0d78c --- /dev/null +++ b/vendor/licenses/grammar/atom-language-1c-bsl.txt @@ -0,0 +1,25 @@ +--- +type: grammar +name: atom-language-1c-bsl +license: mit +--- +Copyright © 2015 xDrivenDevelopment + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR 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/vendor/licenses/grammar/haskell.tmbundle.txt b/vendor/licenses/grammar/blitzmax.txt similarity index 96% rename from vendor/licenses/grammar/haskell.tmbundle.txt rename to vendor/licenses/grammar/blitzmax.txt index 12ab34cf..179be3f1 100644 --- a/vendor/licenses/grammar/haskell.tmbundle.txt +++ b/vendor/licenses/grammar/blitzmax.txt @@ -1,6 +1,6 @@ --- type: grammar -name: haskell.tmbundle +name: blitzmax license: permissive curated: true --- diff --git a/vendor/licenses/grammar/cython.txt b/vendor/licenses/grammar/cython.txt new file mode 100644 index 00000000..31515e2f --- /dev/null +++ b/vendor/licenses/grammar/cython.txt @@ -0,0 +1,15 @@ +--- +type: grammar +name: cython +license: permissive +curated: true +--- + +If not otherwise specified (see below), files in this repository fall under the following license: + + Permission to copy, use, modify, sell and distribute this + software is granted. This software is provided "as is" without + express or implied warranty, and with no claim as to its + suitability for any purpose. + +An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”. diff --git a/vendor/licenses/grammar/ebundles.txt b/vendor/licenses/grammar/ebundles.txt deleted file mode 100644 index eccf4579..00000000 --- a/vendor/licenses/grammar/ebundles.txt +++ /dev/null @@ -1,26 +0,0 @@ ---- -type: grammar -name: ebundles -license: mit -curated: true ---- -If not otherwise specified (see below), files in this repository (located at https://ebundles.googlecode.com/svn/) fall under the MIT License: - - Permission is hereby granted, free of charge, to any person obtaining a copy of - this software and associated documentation files (the "Software"), to deal in - the Software without restriction, including without limitation the rights to - use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of - the Software, and to permit persons to whom the Software is furnished to do so, - subject to the following conditions: - - The above copyright notice and this permission notice shall be included in all - copies or substantial portions of the Software. - - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS - FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR - COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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. - -An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”. diff --git a/vendor/licenses/grammar/forth.txt b/vendor/licenses/grammar/forth.txt new file mode 100644 index 00000000..ec9c0253 --- /dev/null +++ b/vendor/licenses/grammar/forth.txt @@ -0,0 +1,14 @@ +--- +type: grammar +name: forth +license: permissive +curated: true +--- +If not otherwise specified (see below), files in this repository fall under the following license: + + Permission to copy, use, modify, sell and distribute this + software is granted. This software is provided "as is" without + express or implied warranty, and with no claim as to its + suitability for any purpose. + +An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”. diff --git a/vendor/licenses/grammar/language-asn1.txt b/vendor/licenses/grammar/language-asn1.txt new file mode 100644 index 00000000..3f9bfcae --- /dev/null +++ b/vendor/licenses/grammar/language-asn1.txt @@ -0,0 +1,26 @@ +--- +type: grammar +name: language-asn1 +license: mit +--- +The MIT License (MIT) + +Copyright (c) 2016 Alexander Langley + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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/vendor/grammars/less.tmbundle/README.md b/vendor/licenses/grammar/language-batchfile.txt similarity index 80% rename from vendor/grammars/less.tmbundle/README.md rename to vendor/licenses/grammar/language-batchfile.txt index ed6ac672..4f9ab62e 100644 --- a/vendor/grammars/less.tmbundle/README.md +++ b/vendor/licenses/grammar/language-batchfile.txt @@ -1,10 +1,9 @@ -# Installation - -You can install this bundle in TextMate by opening the preferences and going to the bundles tab. After installation it will be automatically updated for you. - -# License (MIT) - -Copyright (c) 2010 Scott Kyle and Rasmus Andersson +--- +type: grammar +name: language-batchfile +license: mit +--- +Copyright (c) 2014 Michael Mims Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/vendor/licenses/grammar/language-emacs-lisp.txt b/vendor/licenses/grammar/language-emacs-lisp.txt new file mode 100644 index 00000000..46603bd3 --- /dev/null +++ b/vendor/licenses/grammar/language-emacs-lisp.txt @@ -0,0 +1,18 @@ +--- +type: grammar +name: language-emacs-lisp +license: isc +--- +Copyright (c) 2016, John Gardner + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/vendor/grammars/Sublime-Inform/LICENSE.txt b/vendor/licenses/grammar/language-haskell.txt similarity index 92% rename from vendor/grammars/Sublime-Inform/LICENSE.txt rename to vendor/licenses/grammar/language-haskell.txt index cda6f052..d46acdb4 100644 --- a/vendor/grammars/Sublime-Inform/LICENSE.txt +++ b/vendor/licenses/grammar/language-haskell.txt @@ -1,6 +1,11 @@ +--- +type: grammar +name: language-haskell +license: mit +--- The MIT License (MIT) -Copyright (c) 2014 Nate Dickson +Copyright (c) 2015 Atom-Haskell Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/vendor/licenses/grammar/language-roff.txt b/vendor/licenses/grammar/language-roff.txt new file mode 100644 index 00000000..0bb79d80 --- /dev/null +++ b/vendor/licenses/grammar/language-roff.txt @@ -0,0 +1,18 @@ +--- +type: grammar +name: language-roff +license: isc +--- +Copyright (c) 2016, John Gardner + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/vendor/licenses/grammar/language-rpm-spec.txt b/vendor/licenses/grammar/language-rpm-spec.txt new file mode 100644 index 00000000..533fb6fa --- /dev/null +++ b/vendor/licenses/grammar/language-rpm-spec.txt @@ -0,0 +1,25 @@ +--- +type: grammar +name: language-rpm-spec +license: mit +--- +Copyright (c) 2015 Jeremiah Powell + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR 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/vendor/licenses/grammar/less.tmbundle.txt b/vendor/licenses/grammar/less.tmbundle.txt deleted file mode 100644 index 5d12ca2e..00000000 --- a/vendor/licenses/grammar/less.tmbundle.txt +++ /dev/null @@ -1,14 +0,0 @@ ---- -type: grammar -name: less.tmbundle -license: mit -curated: true ---- - -Copyright (c) 2010 Scott Kyle and Rasmus Andersson - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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/vendor/licenses/grammar/parrot.txt b/vendor/licenses/grammar/parrot.txt new file mode 100644 index 00000000..4175c715 --- /dev/null +++ b/vendor/licenses/grammar/parrot.txt @@ -0,0 +1,14 @@ +--- +type: grammar +name: parrot +license: permissive +curated: true +--- +If not otherwise specified (see below), files in this repository fall under the following license: + + Permission to copy, use, modify, sell and distribute this + software is granted. This software is provided "as is" without + express or implied warranty, and with no claim as to its + suitability for any purpose. + +An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”. diff --git a/vendor/licenses/grammar/secondlife-lsl.txt b/vendor/licenses/grammar/secondlife-lsl.txt new file mode 100644 index 00000000..cf255ab9 --- /dev/null +++ b/vendor/licenses/grammar/secondlife-lsl.txt @@ -0,0 +1,14 @@ +--- +type: grammar +name: secondlife-lsl +license: permissive +curated: true +--- +If not otherwise specified (see below), files in this repository fall under the following license: + + Permission to copy, use, modify, sell and distribute this + software is granted. This software is provided "as is" without + express or implied warranty, and with no claim as to its + suitability for any purpose. + +An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”. diff --git a/vendor/licenses/grammar/Sublime-Inform.txt b/vendor/licenses/grammar/sublime-rexx.txt similarity index 95% rename from vendor/licenses/grammar/Sublime-Inform.txt rename to vendor/licenses/grammar/sublime-rexx.txt index 15d8edfb..0c1fcfce 100644 --- a/vendor/licenses/grammar/Sublime-Inform.txt +++ b/vendor/licenses/grammar/sublime-rexx.txt @@ -1,11 +1,11 @@ --- type: grammar -name: Sublime-Inform +name: sublime-rexx license: mit --- The MIT License (MIT) -Copyright (c) 2014 Nate Dickson +Copyright (c) 2016 Mike Blocker Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/vendor/licenses/grammar/sublime_man_page_support.txt b/vendor/licenses/grammar/sublime_man_page_support.txt deleted file mode 100644 index f39a2a4e..00000000 --- a/vendor/licenses/grammar/sublime_man_page_support.txt +++ /dev/null @@ -1,25 +0,0 @@ ---- -type: grammar -name: sublime_man_page_support -license: mit ---- -The MIT License (MIT) - -Copyright (c) 2013 carsonoid - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software is furnished to do so, -subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS -FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR -COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 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/vendor/licenses/grammar/vhdl.txt b/vendor/licenses/grammar/vhdl.txt new file mode 100644 index 00000000..36b8e6df --- /dev/null +++ b/vendor/licenses/grammar/vhdl.txt @@ -0,0 +1,14 @@ +--- +type: grammar +name: vhdl +license: permissive +curated: true +--- +If not otherwise specified (see below), files in this repository fall under the following license: + + Permission to copy, use, modify, sell and distribute this + software is granted. This software is provided "as is" without + express or implied warranty, and with no claim as to its + suitability for any purpose. + +An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”. diff --git a/vendor/licenses/grammar/xquery.txt b/vendor/licenses/grammar/xquery.txt new file mode 100644 index 00000000..ce491a41 --- /dev/null +++ b/vendor/licenses/grammar/xquery.txt @@ -0,0 +1,14 @@ +--- +type: grammar +name: xquery +license: permissive +curated: true +--- +If not otherwise specified (see below), files in this repository fall under the following license: + + Permission to copy, use, modify, sell and distribute this + software is granted. This software is provided "as is" without + express or implied warranty, and with no claim as to its + suitability for any purpose. + +An exception is made for files in readable text which contain their own license information, or files where an accompanying file exists (in the same directory) with a “-license” suffix added to the base-name name of the original file, and an extension of txt, html, or similar. For example “tidy” is accompanied by “tidy-license.txt”.