MediaWiki:Gadget-SemanticTemplatesNew.js

Aus Wikiversity

Hinweis: Leere nach dem Veröffentlichen den Browser-Cache, um die Änderungen sehen zu können.

  • Firefox/Safari: Umschalttaste drücken und gleichzeitig Aktualisieren anklicken oder entweder Strg+F5 oder Strg+R (⌘+R auf dem Mac) drücken
  • Google Chrome: Umschalttaste+Strg+R (⌘+Umschalttaste+R auf dem Mac) drücken
  • Internet Explorer/Edge: Strg+F5 drücken oder Strg drücken und gleichzeitig Aktualisieren anklicken
  • Opera: Strg+F5
//Version 0.62 - Support für neuen erweiterten Editor einfügen
//Version 0.61 - Anfangsbuchstaben bei MSW
//Version 0.60 - MDLUL ersetzt Mastalink
//Version 0.59 - Beweisaufgabe wie Aufgabe
//Version 0.58 - Bedingter Button für Kontrollseite
//Version 0.57 - Genauere Buttons für mathematische Texte
//Version 0.56 - Bedingter Button für Referenznummer
//Version 0.55 - Kategorienamen bei Texttyp automatisch eingefügt
//Version 0.54 - Dateiname bei "MSW" automatisch eingefügt
//Version 0.53 - Dateiname bei "Latexdeklaration" automatisch eingefügt
//Version 0.52 - Bedingte Kategorisierungen
//Version 0.51 - Bedingter Button für mathematisches Stichwort
//Version 0.50 - Weitere bedingte Buttons für Beweisstrukturen
//Version 0.49 - Button für mathematische Bedingung und mathematische Liste; bedingter Button für Stichwortumleitung
//Version 0.48 - Stärkere Strukturierung, Erweiterung bei Vorlagenbutton
//Version 0.47 - Stichwortbutton und bedingter Definitionswort-Button statt Betonung
//Version 0.46 - Operatorvorlage
//Version 0.45 - Testphase für semantische Tafeldarstellung nach unter abgetrennt
//Version 0.44 - Bedingter Button für Widerspruchsbeweis
//Version 0.43 - Bedingter Button für Induktionsbeweis
//Version 0.42 - Button für mathematische Vorlage im Display
//Version 0.41 - Button für Strukturvorlage
//Version 0.40 - Bedingter Button für Fallunterscheidung
//Version 0.39 - Bedingter Button für Zuweisung, für Definition (Testphase)
//Version 0.38 - Bedingter Button für Zwischenbehauptung
//Version 0.37 - Bedingter Button für Latexmakros
//Version 0.36 - Andere Buttons, Ausrichtung entfernt (durch Vergleichskette ersetzt), Einrückung entfernt, Operatorname nach links, Bild leicht nach rechts
//Version 0.35 - Bedingter Button für Vorlagengestaltung
//Version 0.34 - Button für Situationsbeschreibung
//Version 0.33 - Aufgabenstrukuren unter Aufgabenbedingung (man/Sie)
//Version 0.32 - Mathkon in Mathkor umbenannt und umgestaltet (für korrespondierende Terme)
//Version 0.31 - Bedingter Button für Bucheintrag
//Version 0.30 - Button für häufige Abbildungsstruktur
//Version 0.29 - Button für Vergleichskette (semantischer)
//Version 0.28 - Button für Mathkon
//Version 0.27 - Bedingter Button für Latexseite
//Version 0.26 - Button für Vortragseintrag unter der Bedingung /Themen und /Vorträge
//Version 0.25 - Bildbutton ergänzt um Dokumentationsmöglichkeit für Lizenz
//Version 0.24 - Button für Klammerzusätze. Textart und Objektkategorie-Zeile im mathematischen Text.
//Version 0.23 - Vorlagebutton und Parameterbutton eingeführt, Änderungen an D-Link und F-Link, Kategorisierungshilfe.
//Version 0.22 - "Faktstruktur" eingeführt.
//Version 0.21 - "math", "mathdisplay" und "inputbild" angepasst.
//Version 0.20 - "D-Link", "F-Link" eingeführt.
//Version 0.19 - "MathDisplay", "Aufzählung": zeilenweise Aufteilung der Elemente eingeführt.
//Version 0.18 - "Latex-Operatorname", "Bemerkung" ergänzt, Reihenfolge angepasst.
//Version 0.17 - "Beispiel" und "Aufgabe" ergänzt
//Version 0.16 - "Definition" und "Fakt" ergänzt
//Version 0.15 - "Mathdisplay" ergänzt, Reihenfolge verändert
//Version 0.1
//(c) 2008 by Exxu
//Released under GPL or CC-by-SA 2.5 (http://creativecommons.org/licenses/by-sa/2.5/deed.de)
//at your choice
//******************************************************************************************
// Add some more custom edit buttons to the toolbar if working in edit modus
// It inserts templates coming from [[Projekt:Semantische Vorlagen]]
//******************************************************************************************
// relies on [//de.wikiversity.org/w/skins/common/edit.js]
//******************************************************************************************
// Ergänzt die Editiersymbolleiste um eine Reihe spezifischer Schaltflächen im 
// "Bearbeiten"-Modus. 
// Die Schaltflächen entstanden im Ergebnis des [[Projekt:Semantische Vorlagen]].
//******************************************************************************************
// Benötigt: [//de.wikiversity.org/w/skins/common/edit.js]
 
function toolbarExtension_semanticTemplatesNewEditor(){	
	var textHere = " Hier Text einsetzen ";
	var formulaHere = " Hier Formel einsetzen ";
	var regx = mw.config.get('wgPageName').match(/Aufgabe|Beispiel|Bemerkung|Fakt_Beweis|Definition|Fakt/gi);
	var wgPageName = mw.config.get('wgPageName');
	// General format: 
	// $( '#wpTextbox1' ).wikiEditor( 'addToToolbar', { configuration object here } );

	// To add a toolbar section:
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'sections': {
			'SemanticTemplates': {
				'type': 'toolbar', // Can also be 'booklet'
				'label': 'Semantische Vorlagen'
			}
		}
	} );

	// To add a group to an existing toolbar section:
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'groups': {
			'SemanticTemplates': {
//				'label': 'Semantische Vorlagen'
				'label': ''
			}
		}
	} );
	
	//
	//
	//Bedingte Einsetzungshilfen
	//
	//

	//
	//
	//Bedingte Einsetzungshilfen für Stichworte
	//
	//

	if(wgPageName.match(/MSWUL/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Stichwortumleitung': {
					label: 'Stichwortumleitung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '<noinclude>{{MSWUL}}</noinclude>',
							peri: 'wohin',
						}
					}
				}
			}
		} );
	}
	
	if(wgPageName.match(/MSW/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematisches Stichwort': {
					label: 'Mathematisches Stichwort',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{MSW|Anf1=' + mw.config.get('wgTitle').substring (0, 1) + '|Anf2=' + mw.config.get('wgTitle').substring (1, 2) + '|Anf3=' + mw.config.get('wgTitle').substring (2, 3) + '|' + mw.config.get('wgTitle') + '}}',
						}
					}
				}
			}
		} );
	}
	
	if(wgPageName.match(/^MDLUL/)){
		var getStart = /^MDLUL\/(.*)/;
		getStart.exec(mw.config.get('wgTitle'));
		var start = RegExp.$1;
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Definitionsumleitung': {
					label: 'Definitionsumleitung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{MDLUL{{{opt|}}}|Start=' + start + '|Anf=' + start.substring (0, 1).toUpperCase() + start.substring (1, 2) + '|\nZiel=',
							peri: 'Ziel',
							post: '/Definition\n}}' 
						}
					}
				}
			}
		} );
	}
	
	
	if(wgPageName.match(/Faktreferenznummer$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Faktreferenznummer': {
					label: 'Faktreferenznummer',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Nummer im Kurs{{{opt|}}}|',
							peri: 'Satz',
							post: '||}}<noinclude>[[Kategorie:Referenznummer in einem Kurs]]</noinclude>' 
						}
					}
				}
			}
		} );
	}
	
	if(wgPageName.match(/Aufgabereferenznummer$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Aufgabereferenznummer': {
					label: 'Aufgabereferenznummer',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Nummer im Kurs{{{opt|}}}|Aufgabe|',
							peri: ' ',
							post: '|}}<noinclude>[[Kategorie:Referenznummer in einem Kurs]]</noinclude>' 
						}
					}
				}
			}
		} );
	}
	
	//
	//
	//Anredevarianten
	//
	//
	
	if(wgPageName.match(/Sie$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Anredevariante1': {
					label: 'Anredevariante',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Anredevariante|',
							peri: 'Dateiname',
							post: '}}' 
						}
					}
				}
			}
		} );
	}
	
	if(wgPageName.match(/Direkt$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Anredevariante2': {
					label: 'Anredevariante',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Anredevariante|',
							peri: 'Dateiname',
							post: '}}' 
						}
					}
				}
			}
		} );
	}
	
	//
	//
	//Bedingte Buttons für Latexversion
	//
	//

	if(wgPageName.match(/latex$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Latexdeklaration': {
					label: 'Latexdeklaration',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{latex|',
							peri: wgPageName.replace(/.latex$/,""),
							post: '}}' 
						}
					}
				}
			}
		} );
	}
	
	if(wgPageName.match(/latexmakros$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Latexmakrosseite': {
					label: 'Latexmakrosseite',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Latexmakros-Seite unter|',
							peri: 'Theorie',
							post: '|}}' 
						}
					}
				}
			}
		} );
	}
	
	//
	//
	//Bedingte Buttons für Kontrollversion (intern)
	//
	//
	
	if(wgPageName.match(/kontrolle$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Kontrollseite': {
					label: 'Kontrollseite',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Kontrollseite|',
							peri: wgPageName.replace(/.kontrolle$/,""),
							post: '}}' 
						}
					}
				}
			}
		} );
	}
	
	//
	//
	//Mathematische Umgebungen
	//
	//
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematische Formel (Latex)1': {
				label: 'Mathematische Formel (Latex)',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/9/90/Button_clipboard_math.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '{{math|term=',
						peri: formulaHere,
						post: '|SZ=}} ' 
					}
				}
			}
		}
	} ); 
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematische Formel (Latex)2': {
				label: 'Mathematische Formel (Latex)',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/9/90/Button_clipboard_math.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '{{mathl|term=',
						peri: formulaHere,
						post: '|SZ=}} ' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathdisplay': {
				label: 'Mathdisplay',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/1/16/Button_clipboard_mathdisplay.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nmath/disp|term=\n',
						peri: formulaHere,
						post: '\n|SZ=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematische Korrespondenz': {
				label: 'Mathematische Korrespondenz',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/5/5f/Button_sorterbar.png',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nmathkor|term1=\n',
						peri: formulaHere,
						post: '\n||term2=\n\n|SZ=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematische Liste': {
				label: 'Mathematische Liste',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/2/2c/Button_clipboard_enum.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nmathlist|term1=\n',
						peri: formulaHere,
						post: '\n||term2=\n\n||term3=\n\n|SZ=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematische Bedingung': {
				label: 'Mathematische Bedingung',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/5/5f/Button_sorterbar.png',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nmathbed|term=\n',
						peri: formulaHere,
						post: '\n||bedterm1=\n\n||bedterm2=\n\n|SZ=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Vergleichskette': {
				label: 'Vergleichskette',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/6/63/Button_clipboard_valign.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nMa:Vergleichskette/disp\n|',
						peri: formulaHere,
						post: '\n||\n||\n||\n||\n|SZ=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Abbildungsstruktur': {
				label: 'Abbildungsstruktur',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/f/ff/Button_arrow_right.png',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nMa:abbele/disp\n|name=\n|',
						peri: formulaHere,
						post: '|\n||\n|SZ=\n}}' 
					}
				}
			}
		}
	} );

	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Vorlage einfügen': {
				label: 'Vorlage einfügen',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/a/a6/Button_clipboard_template.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '{{',
						peri: ' Vorlagenname hier eingeben ',
						post: '|}} ' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematische Vorlage': {
				label: 'Mathematische Vorlage',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nMaVo|disp|\n',
						peri: ' Vorlagenname hier eingeben ',
						post: '\n|SZ=\n}}' 
					}
				}
			}
		}
	} );

	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'SemanticTemplates_Parameter': {
				label: 'Parameter',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/5/5a/Button_clipboard_parameter.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '{{{',
						peri: ' Hier Vorlagenparameter einsetzen ',
						post: '|}}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'SemanticTemplates_Operator': {
				label: 'Operator einfügen',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/a/a6/Button_clipboard_template.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: ' {{op:',
						peri: 'Operatornamen hier einfügen ',
						post: '||}} ' 
					}
				}
			}
		}
	} ); 
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Operatorname (Latex)': {
				label: 'Operatorname (Latex)',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/6/64/Button_clipboard_latex_operation.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\\operatorname{',
						peri: textHere,
						post: '} \\, ' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Aufzaehlung': {
				label: 'Aufzählung',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/2/2c/Button_clipboard_enum.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nAufzählung3\n|',
						peri: textHere,
						post: '\n|\n|\n}}' 
					}
				}
			}
		}
	} );
 
	//
	//
	//Einbindungen
	//
	//

	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Bild einbinden': {
				label: 'Bild einbinden',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/7/7c/Button_clipboard_image.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\ninputbild\n|',
						peri: ' Hier Bildname einsetzen ',
						post: '| 250px {{!}} right {{!}} \n|Text=\n|Autor=\n|Benutzer=\n|Domäne=\n|Lizenz=\n|Bemerkung=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Definition einbinden': {
				label: 'Definition einbinden',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/9/93/Button_clipboard_definition.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\ninputdefinition\n|',
						peri: ' Hier Definitionsname einsetzen ',
						post: '/Definition||\n}}' 
					}
				}
			}
		}
	} );
 
	//
	//
	//Spezielle Defintionsbuttons
	//
	//
	
	if(wgPageName.match(/Definition$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Definitionswort': {
					label: 'Definitionswort',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/7b/Button_clipboard_bold.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: ' {{Definitionswort|',
							peri: ' Definitionswort ',
							post: '|SZ=}} ' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Definitionsstruktur einbinden': {
					label: 'Definitionsstruktur einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/7b/Button_clipboard_bold.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nDefinitionsstruktur\n|Situation=\n',
							peri: ' Situation für Definition ',
							post: '\n|Kern=\n\n|Zusatz=\n}}' 
						}
					}
				}
			}
		} );
	}

	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Fakt einbinden': {
				label: 'Fakt einbinden',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/9/97/Button_clipboard_fact.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\ninputfaktbeweis\n|',
						peri: ' Hier Faktname einsetzen ',
						post: '/Fakt|||\n||\n}}' 
					}
				}
			}
		}
	} );
 
	//
	//
	//Spezielle Beweisbuttons (aktiv bei /Fakt Beweis)
	//
	//

	if(wgPageName.match(/Fakt_Beweis$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Teilbeweis': {
					label: 'Teilbeweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/6/6d/Button_recycling.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nTeilbeweis\n|Teilziel=|Teilstrategie=\n|Teilbeweis=\n',
							peri: 'Beweis',
							post: '\n|Teilabschluss=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Ringbeweis': {
					label: 'Ringbeweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/6/6d/Button_recycling.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nRingbeweis\n|Strategie=\n|Richtung=123\n|Beweis12=\n',
							peri: 'Beweis von 1 nach 2',
							post: '\n|Beweis23=\n\n|Beweis31=\n\n|Abschluss=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Fallunterscheidung': {
					label: 'Fallunterscheidung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nFallunterscheidung\n|Fall1=\n',
							peri: 'Fall1',
							post: '\n|Fall2=\n\n|Fall3=|Fall4=|Fall5=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Widerspruchsbeweis': {
					label: 'Widerspruchsbeweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/a/a5/Buttonexperimenty.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nWiderspruchsbeweis\n|Strategie=\n\n|Annahme=\n',
							peri: 'Annahme',
							post: '\n|Argumentation=\n\n|Widerspruch=\n\n|Zusammenfassung=\n\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Induktionsbeweis': {
					label: 'Induktionsbeweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/a/ad/Button_l_nl.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nInduktionsbeweis\n|Strategie=\n',
							peri: 'Induktion',
							post: '\n|Anfang=\n\n|Schluss=\n\n|Zusammenfassung=\n\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zwischenbehauptung': {
					label: 'Zwischenbehauptung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZwischenbehauptung\n|Behauptung=\n',
							peri: 'Zwischenbehauptung',
							post: '\n|SZ0=.\n|Beweis=\n\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
	}

	//
	//
	//Weitere Strukturen
	//
	//
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Bemerkung einbinden': {
				label: 'Bemerkung einbinden',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/3/32/Button_clipboard_information.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\ninputbemerkung\n|',
						peri: ' Hier Bemerkungsname einsetzen ',
						post: '/Bemerkung||\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Beispiel einbinden': {
				label: 'Beispiel einbinden',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/2/23/Button_clipboard_example.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\ninputbeispiel\n|',
						peri: ' Hier Beispielname einsetzen ',
						post: '/Beispiel||\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Aufgabe einbinden': {
				label: 'Aufgabe einbinden',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/c/c7/Button_clipboard_task.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\ninputaufgabe\n|',
						peri: ' Hier Aufgabenname einsetzen ',
						post: '/Aufgabe||\n|zusatz=\n|tipp=\n}}' 
					}
				}
			}
		}
	} );

	//
	//
	//Spezielle Aufgabenbuttons (aktiv nur bei /Aufgabe und /Beweis)
	//
	//

	if(wgPageName.match(/Aufgabe$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zeigeanweisung einbinden1': {
					label: 'Zeigeanweisung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/e/ec/Button_aviso_borrado.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZeigeanweisung\n|Mittel=\n|Präsub=\n|Subjekt=',
							peri: 'Subjekt (Grammatik)',
							post: '\n|Verbpräp=\n|Verb=\n|Refl=\n|Prädikat=\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zeigeanweisung einbinden2': {
					label: 'Zeigeanweisung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/e/ec/Button_aviso_borrado.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZeigeanweisung\n|Mittel=\n|Präsub=\n|Subjekt=',
							peri: 'Subjekt (Grammatik)',
							post: '\n|Verbpräp=\n|Verb=\n|Prädikat=\n|SZ0=\n|Übergang=und\n|Präsub2=\n|Subjekt2=\n|Verbpräp2=\n|Verb2=\n|Prädikat2=\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'n Sie': {
					label: 'n Sie',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/3/35/Sister_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{n Sie}}',
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'ManSie Unterscheidung einbinden': {
					label: 'ManSie Unterscheidung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/3/35/Sister_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{ManSie|Man ',
							peri: 'bestimme',
							post: '|en Sie}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Aufgabenformvorlage': {
					label: 'Aufgabenformvorlage',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/a/a6/Button_clipboard_template.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{',
							peri: 'Aufgabenformname',
							post: '/Aufgabenform||SZ=}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Beweisaufgabe$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zeigeanweisung einbinden': {
					label: 'Zeigeanweisung einbinden',
					type: 'button',
					icon: '"//upload.wikimedia.org/wikipedia/commons/e/ec/Button_aviso_borrado.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZeigeanweisung\n|Mittel=\n|Präsub=\n|Subjekt=',
							peri: 'Subjekt (Grammatik)',
							post: '\n|Verbpräp=\n|Verb=\n|Refl=\n|Prädikat=\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zeigeanweisung einbinden2': {
					label: 'Zeigeanweisung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/e/ec/Button_aviso_borrado.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZeigeanweisung\n|Mittel=\n|Präsub=\n|Subjekt=',
							peri: 'Subjekt (Grammatik)',
							post: '\n|Verbpräp=\n|Verb=\n|Prädikat=\n|SZ0=\n|Übergang=und\n|Präsub2=\n|Subjekt2=\n|Verbpräp2=\n|Verb2=\n|Prädikat2=\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'n Sie': {
					label: 'n Sie',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/3/35/Sister_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{n Sie}}',
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'ManSie Unterscheidung einbinden': {
					label: 'ManSie Unterscheidung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/3/35/Sister_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{ManSie|Man ',
							peri: 'bestimme',
							post: '|en Sie}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Aufgabenformvorlage': {
					label: 'Aufgabenformvorlage',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/a/a6/Button_clipboard_template.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{',
							peri: 'Aufgabenformname',
							post: '/Aufgabenform||SZ=}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Aufgabenform$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zeigeanweisung einbinden': {
					label: 'Zeigeanweisung einbinden',
					type: 'button',
					icon: '"//upload.wikimedia.org/wikipedia/commons/e/ec/Button_aviso_borrado.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZeigeanweisung\n|Mittel=\n|Präsub=\n|Subjekt=',
							peri: 'Subjekt (Grammatik)',
							post: '\n|Verbpräp=\n|Verb=\n|Refl=\n|Prädikat=\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zeigeanweisung einbinden2': {
					label: 'Zeigeanweisung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/e/ec/Button_aviso_borrado.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZeigeanweisung\n|Mittel=\n|Präsub=\n|Subjekt=',
							peri: 'Subjekt (Grammatik)',
							post: '\n|Verbpräp=\n|Verb=\n|Prädikat=\n|SZ0=\n|Übergang=und\n|Präsub2=\n|Subjekt2=\n|Verbpräp2=\n|Verb2=\n|Prädikat2=\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'n Sie': {
					label: 'n Sie',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/3/35/Sister_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{n Sie}}',
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'ManSie Unterscheidung einbinden': {
					label: 'ManSie Unterscheidung einbinden',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/3/35/Sister_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{ManSie|Man ',
							peri: 'bestimme',
							post: '|en Sie}}' 
						}
					}
				}
			}
		} );
	}

	//
	//
	//Button für mathematischer Text (abhängig vom Texttyp)
	//
	//

	if(wgPageName.match(/Definition$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Definition': {
					label: 'Mathematischer Text/Definition',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Definition{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Definition\n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=   \n|Definitionswort=\n|Definitionswort2=\n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Fakt$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Definition': {
					label: 'Mathematischer Text/Fakt',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Fakt{{{opt|}}}\n|Text=\n{{\nFaktstruktur|typ=\n|Situation=\n',
							peri: textHere,
							post: '\n|Voraussetzung=\n\n|Übergang=\n|Folgerung=\n\n|Zusatz=\n}}\n|Textart=Fakt \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Faktname=\n|Abfrage=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Fakt_Beweis$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Beweis': {
					label: 'Mathematischer Text/Beweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Beweis{{{opt|}}}\n|Text=\n{{\nBeweisstruktur\n|Strategie=\n|Notation=\n|Beweis=\n',
							peri: textHere,
							post: '\n|Abschluss=\n}}\n|Textart=Beweis \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie= \n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Aufgabe$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Aufgabe': {
					label: 'Mathematischer Text/Aufgabe',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Aufgabe{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Aufgabe \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Lösung=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Beweisaufgabe$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Beweisaufgabe': {
					label: 'Mathematischer Text/Aufgabe',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Aufgabe{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Aufgabe \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Lösung=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}
 
 
 
 
 
	if(wgPageName.match(/Aufgabenform$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Aufgabenform': {
					label: 'Mathematischer Text/Aufgabenform',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Aufgabenform{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Aufgabe \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Lösung=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Beispiel$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Beispiel': {
					label: 'Mathematischer Text/Beispiel',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Beispiel{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Beispiel \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Bemerkung$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Bemerkung': {
					label: 'Mathematischer Text/Bemerkung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Bemerkung{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Bemerkung \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Lösung$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Lösung': {
					label: 'Mathematischer Text/Lösung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Lösung{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Lösung \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Aufgabe=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Verfahren$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Verfahren': {
					label: 'Mathematischer Text/Verfahren',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Verfahren{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Verfahren \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	//
	//
	//Textabschnitte
	//
	//
 
	if(wgPageName.match(/Textabschnitt$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Textabschnitt': {
					label: 'Mathematischer Textabschnitt',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Textabschnitt{{{opt|}}}\n|Inhalt=\n',
							peri: textHere,
							post: '\n|Textart=Textabschnitt\n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Situation$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Mathematischer Text/Situation': {
					label: 'Mathematischer Text/Situation',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nMathematischer Text/Situation{{{opt|}}}\n|Text=\n',
							peri: textHere,
							post: '\n|Textart=Situation\n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Autor=\n|Bearbeitungsstand=\n}}' 
						}
					}
				}
			}
		} );
	}
 
	//
	//
	//Unbedingter Fakt (vorübergehend)
	//
	//
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Mathematischer Text/Fakt': {
				label: 'Mathematischer Text/Fakt',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_mathematical_text.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '{{\nMathematischer Text/Fakt{{{opt|}}}\n|Text=\n',
						peri: textHere,
						post: '\n|Textart=Fakt \n|Kategorie=\n|Kategorie2=\n|Kategorie3=\n|Objektkategorie=\n|Stichwort=\n|Faktname=\n|Abfrage=\n|Autor=\n|Bearbeitungsstand=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Situationsvorlage': {
				label: 'Situationsvorlage',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/a/a6/Button_clipboard_template.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '{{',
						peri: ' Vorlagenname ',
						post: '/Situation|SZ=}}' 
					}
				}
			}
		}
	} );
 
	//
	//
	//Links
	//
	//
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Definitions-Link': {
				label: 'Definitions-Link',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/1/11/Button_clipboard_Dlink.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nDefinitionslink\n|',
						peri: 'Definitionsbegriff hier einfügen',
						post: '|\n|kon=|msw=|\n|Definitionsseitenname=\n/Definition\n|Refname=\n{{{def|}}}\n|SZ=\n}}' 
					}
				}
			}
		}
	} );
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Fakt-Link': {
				label: 'Fakt-Link',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/c/cb/Button_clipboard_Flink.gif',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{\nFaktlink\n|Präwort=||Faktseitenname=\n',
						peri: textHere,
						post: '/Fakt\n|Refname={{{ref|}}}|refb={{{refb|}}}\n|SZ=\n}}\n' 
					}
				}
			}
		}
	} );
 
	//
	//
	//Kategorisierung
	//
	//

	if(wgPageName.match(/Aufgaben$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Aufgaben-Kategorisierung': {
					label: 'Aufgaben-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nAufgaben-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Aufgaben$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}

	if(wgPageName.match(/Arbeitsblätter$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Arbeitsblatt-Kategorisierung': {
					label: 'Arbeitsblatt-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nArbeitsblatt-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Arbeitsblätter$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Beispiele$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Beispiel-Kategorisierung': {
					label: 'Beispiel-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nBeispiel-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Beispiele$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Bemerkungen$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Bemerkungs-Kategorisierung': {
					label: 'Bemerkungs-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nBemerkungs-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Bemerkungen$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Beweise$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Beweis-Kategorisierung': {
					label: 'Beweis-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nBeweis-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Beweise$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Definitionen$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Definitions-Kategorisierung': {
					label: 'Definitions-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nDefinitions-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Definitionen$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Fakten$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Fakten-Kategorisierung': {
					label: 'Fakten-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nFakten-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Fakten$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Klausuren$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Klausur-Kategorisierung': {
					label: 'Klausur-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nKlausur-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Klausuren$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Lösungen$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Lösungs-Kategorisierung': {
					label: 'Lösungs-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nLösungs-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Lösungen$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Situationsbeschreibungen$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Situation-Kategorisierung': {
					label: 'Situation-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nSituation-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Situationsbeschreibungen$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Textabschnitte$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Textabschnitt-Kategorisierung': {
					label: 'Textabschnitt-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nTextabschnitts-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Textabschnitte$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
 
	if(wgPageName.match(/Strukturvorlagen$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Vorlagen-Kategorisierung': {
					label: 'Vorlagen-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nVorlagen-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Strukturvorlagen$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
 
 
 
	if(wgPageName.match(/Verfahren$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Verfahrens-Kategorisierung': {
					label: 'Verfahrens-Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nVerfahrens-Kategorie unter\n|',
							peri: mw.config.get('wgTitle').replace(/.Verfahren$/,""),
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}
 
	if(mw.config.get('wgCanonicalNamespace').match("Category")){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Kategorisierung': {
					label: 'Kategorisierung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\n-Kategorie unter\n|',
							peri: textHere,
							post: '|\n||}}' 
						}
					}
				}
			}
		} );
	}

	//
	//
	//Buttons zum Schreiben von Strukturvorlagen
	//
	//
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'If-Bedingung': {
				label: 'If-Bedingung',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/6/62/Button_desambig.png',
				action: {
					type: 'encapsulate',
					options: {
						pre: '\n{{#if:{{{',
						peri: 'Bedingung einfügen',
						post: '|}}}|  |   }}' 
					}
				}
			}
		}
	} );
 
	if(mw.config.get('wgCanonicalNamespace').match("Template")){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Strukturvorlage': {
					label: 'Strukturvorlage',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '<includeonly>{{#switch:{{{opt|}}}\n|wort=\n|#default=\n {{#switch: {{#titleparts:{{FULLPAGENAME}}|1|-1}}\n|latex=\n|#default=',
							peri: 'Struktur',
							post: '\n}}\n}}</includeonly><noinclude>{{Operatorvorlage| |}}</noinclude>' 
						}
					}
				}
			}
		} );
	}
 
	//
	//
	//Einträge für Vorträge und Literatur
	//
	//
 
	if(wgPageName.match(/Themen$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Vortragseintrag': {
					label: 'Vortragseintrag',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nVortragseintrag{{{opt|}}}\n|Sprecher=\n|Sprecher2=\n||Thema=',
							peri: '  ',
							post: '\n|Titel=\n|Datum=\n|Raum=\n|Ort=\n|Zusammenfassung=\n|Literatur=\n|Aktuell=\n|Status=\n|Vortragstyp=\n|Sonstiges=\n}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Vorträge$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Vortragseintrag': {
					label: 'Vortragseintrag',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nVortragseintrag{{{opt|}}}\n|Sprecher=\n|Thema=',
							peri: '  ',
							post: '\n|Titel=\n|Datum=\n|Raum=\n|Ort=\n|Zusammenfassung=\n|Literatur=\n|Aktuell=\n|Status=\n|Vortragstyp=\n|Sonstiges=\n}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Literatureintrag/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Bucheintrag': {
					label: 'Bucheintrag',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nBucheintrag{{{opt|}}}\n|Zitatstichwort=\n|Vorname=',
							peri: 'Vorname',
							post: '\n|Nachname=\n|Vorname2=\n|Nachname2=\n|Titel=\n|Teiltitel=\n|Untertitel=\n|Jahr=\n|Verlag=\n|Ort=\n|Auflage=\n|ISBN= ---  \n|Reihe=\n|Band=\n|Nummer=\n|Bemerkung=\n}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Literatur$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Eintrag im Literaturverzeichnis1': {
					label: 'Eintrag im Literaturverzeichnis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Literaturverzeichnis|',
							peri: 'Literaturstichwort',
							post: '}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Literaturverzeichnis$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Eintrag im Literaturverzeichnis1': {
					label: 'Eintrag im Literaturverzeichnis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{Literaturverzeichnis|',
							peri: 'Literaturstichwort',
							post: '}}' 
						}
					}
				}
			}
		} );
	}
 
	if(wgPageName.match(/Lift/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Bedingter Lift': {
					label: 'Bedingter Lift',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/1/11/Button_clipboard_Dlink.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{#if:{{{',
							peri: 'Parameter',
							post: '|}}}|</br><nowiki>|(</nowiki>{{{1|}}}<nowiki>)=</nowiki>{{{|}}}|}} ' 
						}
					}
				}
			}
		} );
	}

	//
	//
	//Testphase
	//
	//

	if(wgPageName.match(/Test$/)){
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Semantische Definition': {
					label: 'Semantische Definition',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nSema:Definition\n|Kontext=\n|Grundmenge=\n|Typ=\n|Attribut1=\n|Attribut2=\n|Element=',
							peri: 'Elementsymbol',
							post: '\n|Defbegriff=\n|\Bed1={{Lift|Bed1|term=\n|\n}}\n|Bed2={{Lift|Bed2|term=\n|\n}}\n|Bed3={{Lift|Bed3|term=\n|\n}} \n|Bed4={{Lift|Bed4|term=\n|\n}}\n|Bed5={{Lift|Bed5|term=\n|\n}}\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Semantische Zuweisung': {
					label: 'Semantische Zuweisung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/d/d8/Button_archivo_borrar.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: 'Sema=Zuweisung\n|Modus=\n|\Element',
							peri: 'Elementsymbol',
							post: '\n|Menge=\n|Eig1=\n|Eig2=\n|Eig3=' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Semantische Implikation': {
					label: 'Semantische Implikation',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: 'Sema=Implikation\n|Voraus={{Lift|Voraus|term=',
							peri: 'Voraussetzung',
							post: '\n|\n}}\n|Folg={{Lift|Folg|term=\n|\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Semantisches Oder': {
					label: 'Semantisches Oder',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: 'Sema=Oder\n|Alt1=',
							peri: 'Alternative',
							post: '\n|Alt2=\n|Alt3=\n' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Zwischenbehauptung': {
					label: 'Zwischenbehauptung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/9/97/Button_clipboard_fact.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nZwischenbehauptung\n|Behauptung=\n',
							peri: 'Zwischenbehauptung',
							post: '\n|SZ0=.\n|Beweis=\n\n|SZ=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Fallunterscheidung': {
					label: 'Fallunterscheidung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/ba/Button_clipboard_category.gif',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nFallunterscheidung\n|Fall1=\n',
							peri: 'Fall1',
							post: '\n|Fall2=\n\n|Fall3=|Fall4=|Fall5=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Widerspruchsbeweis': {
					label: 'Widerspruchsbeweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/a/a5/Buttonexperimenty.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nWiderspruchsbeweis\n|Strategie=\n\n|Annahme=\n',
							peri: 'Annahme',
							post: '\n|Argumentation=\n\n|Widerspruch=\n\n|Zusammenfassung=\n\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Induktionsbeweis': {
					label: 'Induktionsbeweis',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/a/ad/Button_l_nl.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nInduktionsbeweis\n|Strategie=\n',
							peri: 'Induktion',
							post: '\n|Anfang=\n\n|Induktionsvoraussetzung=\n\n|Schluss=\n\n|Zusammenfassung=\n\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Argumentation': {
					label: 'Argumentation',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/b/b6/Vjazyce-button.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '{{\nTest:Argumentation\n|Z1={{TestLift|Term1|term=',
							peri: 'term1',
							post: '\n||Grund=\n}}\n|Z2={{TestLift|Term2|term=\n||Grund=\n}}\n|Z3={{TestLift|Term3|term=\n||Grund=\n}}\n|Z4={{TestLift|Term4|term=\n||Grund=\n}}\n|Z5={{TestLift|Term5|term=\n||Grund=\n}}\n|Z6={{TestLift|Term6|term=\n||Grund=\n}}\n|Z7={{TestLift|Term7|term=\n||Grund=\n}}\n|Z8={{TestLift|Term8|term=\n||Grund=\n}}\n|Z9={{TestLift|Term9|term=\n||Grund=\n }}\n|Z10={{TestLift|Term10|term=\n||Grund=\n}}\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Test:Zuweisung': {
					label: 'Test:Zuweisung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/d/d8/Button_archivo_borrar.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nTest:Zuweisung|term=',
							peri: 'term',
							post: '\n|Attribut=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Test:Existenz': {
					label: 'Test:Existenz',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/2/2d/CE_icon.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nTest:Existenz|term=',
							peri: 'term',
							post: '|mit1=|mit2=\n|Attribut=\n|Grund=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Test:Objekteinführung': {
					label: 'Test:Objekteinführung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nTest:Objekteinführung|term=',
							peri: 'term',
							post: '|mit1=|mit2=\n|Attribut=\n}}' 
						}
					}
				}
			}
		} );
		
		$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
			'section': 'SemanticTemplates',
			'group': 'SemanticTemplates',
			'tools': {
				'Test:Objektbenennung': {
					label: 'Test:Objektbenennung',
					type: 'button',
					icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
					action: {
						type: 'encapsulate',
						options: {
							pre: '\n{{\nTest:Objektbenennung|name=',
							peri: 'name',
							post: '|term=|\n}}' 
						}
					}
				}
			}
		} );
	}

	//
	//
	//Einsetzungshilfen Umstellung
	//
	//
	
	$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
		'section': 'SemanticTemplates',
		'group': 'SemanticTemplates',
		'tools': {
			'Kat': {
				label: 'Kat',
				type: 'button',
				icon: '//upload.wikimedia.org/wikipedia/commons/7/74/Button_oeil.png',
				action: {
					type: 'encapsulate',
					options: {
						pre: '[[Kategorie:Mathematische Standardlinks]]',
					}
				}
			}
		}
	} );
}

// Check that the toolbar is available
if ( $.fn.wikiEditor ) {
	// Execute on document ready
	$( toolbarExtension_semanticTemplatesNewEditor );
}