public SettingsDialog( AddIn addIn ) : base(addIn) { KeyName = "LannSettings"; DisplayName = "Laan Settings"; DescriptivePhrase = "Set preferences for Laan SMSS Addin"; ButtonText = "Laan Settings"; //ToolTip = "Formats the current file"; }
public OutputOnly( AddIn addIn ) : base(addIn) { KeyName = "LaanSqlPareseOnly"; DisplayName = "Output Parsed SQL"; DescriptivePhrase = "Outputting Parsed SQL"; ButtonText = "&Parse SQL"; ToolTip = "parses and outputs SQL"; ImageIndex = 59; KeyboardBinding = "Text Editor::Ctrl+Shift+E"; }
/// <summary> /// Initializes a new instance of the SqlTemplateOptionAction class. /// </summary> public SqlTemplateOptionAction(AddIn addIn) : base(addIn) { KeyName = "LaanSqlTemplateOptionView"; DisplayName = "View Laan Sql Templates"; DescriptivePhrase = "Viewing Laan Sql Templates"; ButtonText = "Sql Template Designer"; ToolTip = "View Laan Sql Templates"; ImageIndex = 59; KeyboardBinding = "Text Editor::Ctrl+Alt+O"; }
public SqlTemplating(AddIn addIn) : base(addIn) { Templates = LoadTemplates(); KeyName = "LaanSqlTemplating"; DisplayName = "Insert Template"; DescriptivePhrase = "Inserting Template"; ButtonText = "Insert &Template"; ToolTip = "Inserts a template at the cursor"; ImageIndex = 59; KeyboardBinding = "Text Editor::`"; }
public SaveResultAs2( AddIn addIn ) : base(addIn) { KeyName = "LannSqlSaveResultsAs2"; DisplayName = "Save Results As"; DescriptivePhrase = "Save Results to log file and optionally copy file to clipboard"; ButtonText = "Save Results to .log"; //ToolTip = "hi there"; SaveResultsAsPatternName = Settings.Constants.SaveResultsAsPattern2; SaveResultsAsPatternDefault = Settings.Defaults.SaveResultsAsPattern2; SaveResultsAsCopyToClipboardName = Settings.Constants.SaveResultsCopyToClipboard2; SaveResultsAsCopyToClipboardDefault = Settings.Defaults.SaveResultsCopyToClipboard2; }
// Experimental (not working!) //private static int GetStartIndent( TextDocument textDocument ) //{ // var text = textDocument.Selection.Text; // int index = 0; // while ( ( text[ index ] == ' ' ) && ( text[ index ] != '\n' ) ) // index++; // return index + textDocument.Selection.AnchorColumn; //} public SqlFormatter(AddIn addIn) : base(addIn) { _engine = new FormattingEngine(); _engine.IndentStep = 0; // experimental: GetStartIndent( textDocument ) / engine.TabSize; KeyName = "LaanSqlFormat"; DisplayName = "Format SQL"; DescriptivePhrase = "Formatting SQL"; ButtonText = "Format S&QL"; ToolTip = "Formats the current file"; ImageIndex = 59; KeyboardBinding = "Text Editor::Ctrl+`"; }
public DropDownList( AddIn addIn ) : base(addIn) { }
public ParseOnly( AddIn addIn ) : base(addIn) { }
public ScopedUndoContext( AddIn addIn, string name ) { _addIn = addIn; _addIn.OpenUndoContext( name, true ); }
/// <summary> /// Initializes a new instance of the Action class. /// </summary> public BaseAction(AddIn addIn) { AddIn = addIn; ImageIndex = AddIn.DefaultImageIndex; ShowWaitCursor = false; }
public ScopedUndoContext(AddIn addIn, string name) { _addIn = addIn; _addIn.OpenUndoContext(name, true); }