Difference between revisions of "Form:Snippet"

From The Foundry MODO SDK wiki
Jump to: navigation, search
(Created page with "<noinclude> This is the "Snippet" form. To create a page with this form, enter the page name below; if a page with that name already exists, you will be sent to a form to edit...")
 
 
Line 3: Line 3:
 
To create a page with this form, enter the page name below;
 
To create a page with this form, enter the page name below;
 
if a page with that name already exists, you will be sent to a form to edit that page.
 
if a page with that name already exists, you will be sent to a form to edit that page.
 
 
{{#forminput:form=Snippet|button text=Add Code Snippet|query string=namespace=Snippet}}
 
{{#forminput:form=Snippet|button text=Add Code Snippet|query string=namespace=Snippet}}
 
 
</noinclude><includeonly>
 
</noinclude><includeonly>
 
{{#default_form:snippet}}
 
{{#default_form:snippet}}
<div id="wikiPreview" style="display: none; padding-bottom: 25px; margin-bottom: 25px; border-bottom: 1px solid #AAAAAA;"></div>
 
 
{{{for template|Snippet}}}
 
{{{for template|Snippet}}}
{| class="formtable"
+
'''Description''':<br />
! Language:
+
A brief description or summary of the snippet aand it's purpose<br />
| {{{field|lang|mandatory|list|input type=dropdown|values=CPP,Python,Perl,LUA,XML|default=CPP}}}
+
{{{field|summary|input type=textarea|rows=3|editor=wikieditor}}}
|-
+
<br />
! Summary:  
+
'''Code''':<br />
| {{{field|summary|input type=textarea|editor=wikieditor}}}
+
Add the source for the snippet by adding syntax highlight tags from the 'Code' section of the toolbar. You may enter multiple blocks of code in any language or mix of languages you and separated by any further commentary required. You may also embed Gists or Pastebin pastes by adding the necessary tags which are also found in the 'Code' section of the toolbar.<br />
|-
+
{{{field|code|input type=textarea|rows=15|editor=wikieditor}}}
! Code:  
+
<br />
| {{{field|code|input type=textarea|editor=wikieditor|rows=20|cols=150}}}
+
'''Categories''':<br />
|}
+
Tag your snippet with categories to aid in searching. At least one tag is required which should be the main language or languages covered by the snippet. Each tag should be separated by a comma, no spaces. For consistency use one or more of the following tags for the languages supported by modo: CPP, Python, Perl, LUA, Config.<br />
 +
{{{field|lang|mandatory|input type=tokens}}}
 
{{{end template}}}
 
{{{end template}}}
 
{{{standard input|summary}}}
 
  
 
{{{standard input|minor edit}}} {{{standard input|watch}}}
 
{{{standard input|minor edit}}} {{{standard input|watch}}}

Latest revision as of 10:58, 24 November 2015

This is the "Snippet" form. To create a page with this form, enter the page name below; if a page with that name already exists, you will be sent to a form to edit that page.