Ammy is a modern UI language that either replaces or compliments XAML in your projects.
IValueConverter
s for every simple taskWindow "MyApp.MainWindow" {
Title: "My first Application"
Grid {
TextBlock { "Hello, World!" }
}
}
Note that you don't need to import any namespaces manually. In case you need to import external namespace, there is C# a using
keyword available.
alias FormField (labelText, binding)
{
StackPanel {
Orientation: Horizontal
TextBlock { Text: $labelText }
TextBlock {
Text: $binding
}
}
}
Window "MyApp.MainWindow" {
Title: "My First App"
StackPanel {
@FormField ("First name", bind FirstName)
@FormField ("Last name", bind LastName)
TextBlock {
Text: bind
convert (MyViewModel vm) => "Hello, " + vm.FirstName + " " + vm.LastName
}
}
}
Ammy.sln
solution in VS2017 and build itAmmy.VisualStudio
project as StartUp Project and start Debugging sessionAmmy.Tests.sln
solutionAmmy.Test.Workbench
project is for debuggingAmmy.Test.Wpf
contains permanent tests that should all compileAmmy uses Nitra for parsing and typing. First, file is parsed with syntax defined in Syntax.nitra. Resulting ParseTree
is then mapped to AST (Mapping.nitra, MappingExpr.nitra, MappingFunctions.nitra).
Semantic analysis is a process where types loaded from Backend are binded to AST. This process defined inside Ast and AstBase projects in .nitra
files.
Sidekick library has two primary functions. 1) ExpressionConverter
used for inline binding converters 2) Runtime update logic
Build assembly is a glue between IDE/MSBuild and Ammy language.
Ammy.VisualStudio only contains service providers. These providers use RuntimeLoader to load Ammy.VisualStudio.Service assembly and load actual services. Ammy.VisualStudio.Service contains all the logic for highlighting, intelli-sense, regions, adornments, classisifiers and other stuff.