Wednesday, August 7, 2013

XamlDesigner - BamlExtractor

One grate feature of the XamlDesigner is the ability to open compiled Assemblies that contain Xaml Files and extract the Xaml from the Assembly.

The BamlExtractor displays Styles, Controls (Windows, UserControls, etc.) and ResourceDictionaries.
The Xaml can then be selected for editing or viewing in the XamlDesigner.

This can be a very helpful feature if you want to inspect or create a Style or a Template that is defined in a different Assembly.


There still are several tasks that have to be done but I hope to soon be able to create an alpha Release.

Monday, April 22, 2013

Xaml Designer - The code editor

The wickedflame codeeditor is a small and simple editor for different programing languages written in C# and Xaml (WPF).

The basic features like text manipulation, Undo/Redo and navigation work (should) similar to any other Texteditor. 
The Syntaxhighlighting is defined in a simple xml file. At the moment there is a complete Syntaxhighlighting implementation for Xml/Xaml and a basic implementation for C#.



The Codecompletation is not finished jet. The Completition Window can be shown with items which get filtered as the code gets typed.


I am quite proud of this feature. I was able to extract the Namespaces and load the Assemblies. This way I am able to display all Types that can be contained in the code.
At the moment I only have a Xaml implementation but the C# version should be very easy to add because the basics are the same.

Some features that is still fully missing are:
  • Codeindentation
  • Textsearch / replace
  • Line numbering


Tuesday, April 16, 2013

Xaml Designer

It's been quiet for some time now. But now I finally started a new project an now I am at a state where I can show a little bit.

Xaml Designer

It's a simple editor for xaml with a graphical UI Designer.


I needed a Graphical UI Designer where I could load a *.xaml file and be able to manipulate this. The Project then started as a Test application to see how I could manipulate the XAML. Then I also wanted to see the resulting XAML and be able to manipulate it. So I looked around for a code TextBox. I found a few editors but was not very happy with them so I decided to create a new editor.

I created the Code editor from scratch. There are still some important features missing for a Code edtior like Intelisense (Autocomplete) and the automatic indentation rules.
The Synthaxhighlighting currently only supports C# and XML/XAML. The highlighting Engine is based on xml files. This way the editor can be extended very easily.

The UI Designer was also created from scratch. At the moment it supports selecting an element and Drag & Drop. With this function elements can be moved around and placed in different positions. The elements can be dropped in most Panels and ContentControls. ItemsControl and the remaining Panels still need to be implemented.

At the left side there is the LogicalTree to help selecting elements.

Next I will create a PropertyGrid to be able to change properties without having to edit the XAML.

At the moment I only support WPF but Silverlight is also planned and probably also WinRT.
But at the moment I am far away from any Beta or pre-stable version. I mostly use it in Debug mode and fix the errors on the run.
Hopefuly I will soon have a version ready for release.

Sunday, May 13, 2012

Personalplaner sources are online

I uploaded all sources of the new Personalplaner to personalplaner.codeplex.com.

For development I use a different reopsitory. When I started on the project I didn't expect to ever complete it. So I chose to host it on unfuddle.com.
When I decided to host the setup on codeplex as shareware I also came to the decision to upload the code. Now whenever I create a new stable version I upload the code as well.

I guess it doesn't allways end as expected. Originaly I didn't expect to ever finish the project. And by now I created 14 stable releases that are finished, useable, free and open source :-)

Have fun!

Thursday, May 10, 2012

Personalplaner v2 is stable


The stable version of the Personalplaner is 2.0.1.12131.

http://personalplaner.codeplex.com/

For this version the Personalplaner was completely redesigned.
A complete new Look was created. This was accomplished by porting the Personalplaner to WPF.
The Application was split into different layers.

  1. The Visual layer 
  2. The Logic layer
  3. The Application Data layer
  4. The Storage Logic layer
  5. The Data Storage
The Data Storage was not touched much. This is still a MSSQL Server.

The Storage Logic layer still uses Stored Procedures. These were modified or recreated.

The Application Data layer is the connection to the Storage. This was redesigned to a kind of service provider so that it could easily be replaced/ported to eg. WebServices.

The Logic layer was completely recreated. This layer now has an MVVM implementation uses a ServiceLocator pattern. With this redesign the Visual Layer could easily be replaced.

The Visual Layer was a complete redesign. 
  • There is only one main view in the window.
  • The main view can be displayed in a dark or a gray style
  • Secondary views are allways in a white style
  • When a secondary view is created, it is displayed insted of the main view. 
  • All secondary views are designed to look alike. 
  • The same user handling was applied to all views. 
  • Ending a view allways leads back to the previous view.
  • A view can be ended with a cancel button, a ok button or a 'back' arrow button
  • Windows/Dialogs are seldomely used
  • The content of the main view can be extended with plugins
  • The main menu is redesigned and split into tabs that can be selected
  • Descriptions are displayed in most functions










Thursday, April 12, 2012

Personalplaner v2

Soon I will be able to create the final and stable release of the Personalplaner v2.

I did a lot of development for the version 2.
I ported the GUI to the WPF platform. With this step I was able to completely redesign the whole layout of the application. I could template all controls and easily create new Styles for the complete application.




In addition the application was redesigned and split into different layers. All layers are strictly separated into their parts.

  1. The Gui layer
  2. The Logic and Busines layer
  3. The Data transport layer
  4. The Data/Storage layer
In addition I implemented a MVVM Framework (or something similar to a Framework...) to strengthen the separation betwean the Gui and the Logic/Business layers.


Some additional features since the first beta releas:

  • Added description Texts to most relevant Functions
  • Summs of the times of the Dienste are displayed in the Dienstestamm
  • Every Plan can be closed
  • Times can be set as decimals
  • Menu Delete and Finalize were moved to Extras
  • The layout for the displayed names can be chosen
  • The name of the database can be displayed in the main window
  • The pensum can optionaly be printed as well
  • Only Personalplaner Databases can be selected in the Logindialog and the Databasewizard
  • Creating the users in the database could cause errors on case sensitive databases
  • Most StoredProcedures were checked
At the moment the application is still only avaliable in german. But I have prepared everything to create a english version as well. I just need to do the translations and recheck everything to make shure I didn't miss anything. This will be done in a future release because at the moment I am primarily working to get the german version stable.

Thursday, September 22, 2011

Extending the Personalplaner

Every application should be extensible!
That's why I added the ability to create plugins for the Personalplaner. Well actually I did it mainly just for the fun of it...

To achieve this I used MEF. MEF started as a Codeplex project but now is fully integrated in the .NET Framework in the Assembly System.ComponentModel.Composition.

With the help of MEF it is realy easy to create and use plugins resp. export and import objects.
In my case I only had to create an Interface and implement this in the plugin class and add the class attribute [Export(typeof(IPlugin))] (IPlugin is the interface I created...)

[Export(typeof(IPlugin))]
public partial class PlanAnalysisPlugin : BaseControl, IPlugin
{
    ...
}


In the class that imports the plugins, I only needed to create a CompositionContainer that creates/imports the objects and a container that will containe the imported objects.

CompositionContainer _container;

//public IEnumerable<Lazy<IPlugin, IPluginMetadata>> Plugins
/// <summary>
/// Enumeration containing all loaded pluginsEnumeration containing all loaded plugins
/// </summary>
[ImportMany]
public IEnumerable<IPlugin> Plugins
{
    get;
    set;
}

private bool Compose()
{
    if (!Directory.Exists("plugins"))
        return false;

    var catalog = new AggregateCatalog();
    catalog.Catalogs.Add(new DirectoryCatalog("plugins"));

    _container = new CompositionContainer(catalog);

    try
    {
        this._container.ComposeParts(this);
    }
    catch (Exception)
    {
        return false;
    }

    return true;
}

In my case I decided to keep the plugins in the subfolder named plugins.


If the folder is empty then the application should look like this. On the left side there are only the options for Plan and About.


If I put my plugin into the folder plugins, the application should load and insert it in between Plan and About. In this case I created a plugin that shows some reports and displays some additional inforamation to the plans.


I know that I will most probably be the only person that will ever create a plugin or an extension for the Personalplaner. But with this I can easily extend the Personalplaner with new features without having to create a new version and a setup every time.