Template:TAGO: Difference between revisions

From VASP Wiki
No edit summary
No edit summary
Line 6: Line 6:
     | red      = <code style="padding: 3px; background: #FCF3F4">[[{{{1}}}]] {{{op|{{=}}}}} {{{2|}}}</code>
     | red      = <code style="padding: 3px; background: #FCF3F4">[[{{{1}}}]] {{{op|{{=}}}}} {{{2|}}}</code>
     | purple  = <code style="padding: 3px; background: #F8F4FB">[[{{{1}}}]] {{{op|{{=}}}}} {{{2|}}}</code>
     | purple  = <code style="padding: 3px; background: #F8F4FB">[[{{{1}}}]] {{{op|{{=}}}}} {{{2|}}}</code>
     | #default = <code>[[{{{1}}}]] {{{op|{{=}}}}} {{{2|}}}</code>
     | #default = <code style="padding: 3px">[[{{{1}}}]] {{{op|{{=}}}}} {{{2|}}}</code>
   }}
   }}
  | {{#switch: {{{color}}}
  | {{#switch: {{{color}}}
Line 18: Line 18:
}}<noinclude>
}}<noinclude>
== Purpose ==
== Purpose ==
Prints a link to an {{FILE|INCAR}} tag, optionally as <code>TAG = value</code> pair.
Prints a link to an {{FILE|INCAR}} tag, optionally with colored background and/or as <code style="padding: 3px">TAG = value</code> pair.


== Parameters ==
== Parameters ==


  <nowiki> {{TAG|<<value>>}}</nowiki>
  <nowiki> {{TAGO|<tag_name>|<<value>>|<<color=color_name>>|<<op=operator>>}}</nowiki>


* <code>value</code>: ('''optional''') Value associated with {{FILE|INCAR}} tag, writes
* <code>tag_name</code>: The {{FILE|INCAR}} tag for which a link should be generated.
* <code>value</code>: ('''optional''') Value associated with {{FILE|INCAR}} tag, with no other arguments writes <code>MY_TAG = value</code>
* <code>color=color_name</code>: ('''optional''') Apply a color background, available <code>color_name</code> arguments are: <code style="background: #F3FCFB">green</code>, <code style="background: #F7F7F7">grey</code>, <code style="background: #F0F4FF">blue</code>, <code style="background: #FCF3F4">red</code> and <code style="background: #F8F4FB">purple</code>. Works also without the <code>value</code> argument.
* <code>op=operator</code>: ('''optional''') In case a different operator than <code>=</code> is required it can be provided as with the <code>op=</code> argument, e.g., <code><nowiki> {{TAGO|MY_TAG|3|op=>=}}</nowiki></code> produces <code>MY_TAG >= 3</code>.


<code style="border: 0px solid #2FB5AB; padding: 5px; background: #F3FCFB">TAG = value</code>
== Examples ==


<code style="background: #F3FCFB">TAG = value</code>
<nowiki>{{TAGO|IBRION}}
{{TAGO|IBRION|color=red}}


<code>TAG = value</code>
{{TAGO|IBRION|3|color=green}}


{{TAGO|ML_MODE}}
{{TAGO|IBRION|5|op=<}}


{{TAGO|ML_MODE}}
{{TAGO|IBRION|4|color=red|op=>}}</nowiki>


{{TAGO|ML_MODE|run}}
results in


Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd  {{TAGO|ML_MODE|color=red}} gubergren, no sea {{TAGO|ML_MODE|green|color=green}} takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
* {{TAGO|IBRION}}
* {{TAGO|IBRION|color=blue}}


{{NB|warning|Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd  {{TAGO|ML_MODE|color=blue}} gubergren, no sea {{TAGO|ML_MODE|12|color=purple|op=>=}} takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.}}
* {{TAGO|IBRION|3|color=green}}


Normal text around this tag description {{TAGO|ML_MODE}} continues here {{TAGO|ML_MODE|green|color=green}}. Some more text surrounding tag link.
* {{TAGO|IBRION|5|op=<}}


{{TAGO|ML_MODE|grey|color=grey}}
* {{TAGO|IBRION|4|color=red|op=?=}}


{{TAGO|ML_MODE|blue|color=blue}}
=== Remarks ===


{{TAGO|ML_MODE|red|color=red}}
* Can be combined with bold and italics format:
:<nowiki>''{{TAGO|IBRION|4|color=red|op=>}}''
'''{{TAGO|IBRION|4|color=blue|op=>}}'''
'''''{{TAGO|IBRION|4|color=purble|op=>}}'''''</nowiki>
:produces:
:* ''{{TAGO|IBRION|4|color=red|op=>}}''
:* '''{{TAGO|IBRION|4|color=blue|op=>}}'''
:* '''''{{TAGO|IBRION|4|color=purble|op=>}}'''''


{{TAGO|ML_MODE|purple|color=purple}}
* Also works inside of [[Template:NB]] boxes:
 
{{NB|tip|Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd  {{TAGO|ML_MODE|color=red}} gubergren, no sea {{TAGO|ML_MODE|RUN|color=green}} takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita {{TAGO|IBRION|3|op=>}} kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.|:}}
'''{{TAGO|ML_MODE|run|op=>=|color=green}}'''


</noinclude>
</noinclude>

Revision as of 10:09, 19 October 2023

[[{{{1}}}]]

Purpose

Prints a link to an INCAR tag, optionally with colored background and/or as TAG = value pair.

Parameters

 {{TAGO|<tag_name>|<<value>>|<<color=color_name>>|<<op=operator>>}}
  • tag_name: The INCAR tag for which a link should be generated.
  • value: (optional) Value associated with INCAR tag, with no other arguments writes MY_TAG = value
  • color=color_name: (optional) Apply a color background, available color_name arguments are: green, grey, blue, red and purple. Works also without the value argument.
  • op=operator: (optional) In case a different operator than = is required it can be provided as with the op= argument, e.g., {{TAGO|MY_TAG|3|op=>=}} produces MY_TAG >= 3.

Examples

{{TAGO|IBRION}}
 
 {{TAGO|IBRION|color=red}}

 {{TAGO|IBRION|3|color=green}}

 {{TAGO|IBRION|5|op=<}}

 {{TAGO|IBRION|4|color=red|op=>}}

results in

Remarks

  • Can be combined with bold and italics format:
:''{{TAGO|IBRION|4|color=red|op=>}}''
 '''{{TAGO|IBRION|4|color=blue|op=>}}'''
 '''''{{TAGO|IBRION|4|color=purble|op=>}}'''''
produces:
Tip: Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd ML_MODE gubergren, no sea ML_MODE = RUN takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita IBRION > 3 kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.