wpfXamlEditor
UNDER CONSTRUCTION
Overview
XamlEditor is a Xaml editor for an APL variable or for a file on disk. This user command is able to show the Xaml in color with folding, print it, reorganize it so it is more readable according to some settings set by the user. It is inspired by the work of Robby Ingebretsen of Kaxaml (http://www.Kaxaml.com). It is particularly valuable for APLers that like to keep their Xaml in the workspace. With XamlEditor they have a tool to maintain it without effort.
Usage
Once installed the user command can be invoke by typing ]XamlEditor (casing is not important, no argument). The following start-up screen will appear:
Here is a short description for each buttons:
Button |
Explanation |
Button |
Explanation |
Execute the Xaml and Show the Result in a Separate Window |
|
Select All the Xaml |
|
|
Scrub the Xaml According to Settings |
|
Delete the Selected Text |
|
Open a Dialog Box to Select a Xaml Variable in the WS |
|
Clear the Clipboard |
|
Open a Dialog Box to Save the Xaml as a Variable in the WS |
|
Undo Last Operation |
|
Open a Dialog Box to Select a File on Disk |
|
Redo Previous Operation |
|
Open a Dialog Box to Save the Xaml to a File |
|
Print All the Xaml |
|
Cut the Selected Text to The Clipboard |
|
Print Preview All the Xaml |
|
Copy the Selected Text to the Clipboard |
|
Make Selected Text a Comment |
|
Paste the Text From the clipboard |
|
Choose the Settings when Scrubbing |
Installation
Download the file wpfXamlEditor.1.0.zip. It contains the Dyalog user command file wpfXamlEditor.dyalog and a dll named ICSharpCode.AvalonEdit.dll
Copy the file wpfXamlEditor.dyalog to your user command directory (for advice how to organize your User Commands see UserCommands/WhereShouldTheyGo).
Copy the file ICSharpCode.AvalonEdit.dll to the same directory as your dyalog.exe file (as shown by doing +2 ⎕NQ'.' 'GetEnvironment' 'Dyalog')(you may need administrator privileges for doing that). That dll is free of charge and was written by Daniel Grunwald. It can be downloaded from CodeProject or from AvalonEdit but is included in the zip file for commodity.
Detailed Explanations
Execute the Xaml and Show the Result in a Separate Window |
The settings for scrubbing are saved in a xml file named XED.Settings.xml. The file will be created automatically the first time the user command runs. It will be located next to the wpfXamlEditor.dyalog file or in the AppData directory depending on the Windows version and security. The data of the file looks like this:
<Settings> <EditorFont>APL385 Unicode</EditorFont> <EditorFontSize>14</EditorFontSize> <ReducePrecision>0</ReducePrecision> <Precision>10</Precision> <AttributeCounteTolerance>2</AttributeCounteTolerance> <ReorderAttributes>1</ReorderAttributes> <RemoveCommonDefaultValues>1</RemoveCommonDefaultValues> <ConvertTabsToSpaces>1</ConvertTabsToSpaces> <SpaceCount>2</SpaceCount> </Settings>
It is used to build the Settings window (button of the command bar).
Look at the individual tooltips on the Window for more information on each settings.