Would it be possible to add a new macro tag to reflect the language (document type) of the current file? This isn't that hard to detect from the file extension, I realize, but since Zeus has already done that classification, it might make language-dependent macros a little bit more robust, with less code redundancy. Some languages also use multiple file extensions for a document type (depends on shop conventions, I guess), so specifying this in one place rather than Zeus config + one or more language-dependent macros would be a nice convenience.
Bill Diener
New Macro Tag Request
Hi Bill,
So for example given a COBOL active document this new tag would return the following string:
Even though it the Zeus configuration is wrong since it should have been configured as COBOL Document Type 
That should work don't you think
PS: I could also parse the string to remove the Document Type portion but I am not sure that is a good idea.
Cheers Jussi
Sure. I create a new macro tag described as follows:Would it be possible to add a new macro tag to reflect the language (document type) of the current file?
Code: Select all
$DTD i.e the DocumentTypeDescription
Code: Select all
Cobol Document Type

That should work don't you think

PS: I could also parse the string to remove the Document Type portion but I am not sure that is a good idea.
Cheers Jussi
Hi Bill,
This latest patch include the new $DTD macro tag: http://www.zeusedit.com/z300/zeus-beta-patch.zip
Here's an example:

Generally I am always very happy when people offer suggestion on how to make Zeus better.
Cheers Jussi
This latest patch include the new $DTD macro tag: http://www.zeusedit.com/z300/zeus-beta-patch.zip
Here's an example:
Code: Select all
function key_macro()
document_type = macro_tag("$DTD")
message(document_type)
end
key_macro() -- run the macro
Thanksyour willingness to consider suggestions and the responsiveness with which they get implemented are excellent!

Generally I am always very happy when people offer suggestion on how to make Zeus better.
Cheers Jussi