Mind Mate: Mind Mapping on Windows 7 and 8

(for background on Mind Mate, click here)

I have been developing Mind Mate on Windows 10 machine, so wasn’t sure how it is going to behave on earlier versions of OS. Today, I tested it on Windows 7 and 8 using VMs made available by Microsoft.

Mind Mate worked perfectly on Windows 8 but encountered few issues on Windows 7 related to Windows Ribbon Control. These issues are:

– Images in PNG format are not displayed in the ribbon. Seems like Ribbon control on Win7 only supports BMP, that too generated in a certain version of BMP specification. I found that only PixelFormer knows how to generate the right BMP file for Windows 7 Ribbon control.

– Controls don’t layout properly after initial launch, it requires resizing the main window once, then it starts working fine.

– Non true type fonts are not supported.

These issues are resolved in the new Build. Download it from here and give it a go.

Developed Mind Mapping software–codenamed ‘Mind Mate’

Mind Map is a graphical way of representing concepts and ideas. It starts with the main idea at the center with branches going into details.

Personally, I use it for all my notes taking, to-do lists, managing project information etc. Probably it goes beyond what normal usage of the term Mind Map implies but I found many people using Mind Mapping software in the same way. The appeal of Mind Mapping software, in the regard, is the ability to handle the depth of information. Due to outlining you focus on the level of information you want, dig deeper into a topic or zoom out to the headlines with ease.

FreeMind and XMind are the most popular software out there. Personally, I prefer FreeMind as it is more suitable to the usage style I described above. XMind is more focused towards presentation, rather than daily usage for notes taking. Unfortunately, FreeMind is a not being developed very actively.

Since last couple of years, I have been developing my own Mind Mapping software on Github. It started just as a pastime and somehow I managed to put in some hours week after week. It has been a fun ride and a very good learning experience. I switched to it for my daily use for a few months now. Today I prepared an installer for MindMate to make it more accessible. Please download it and give it a short. I will wait for your feedback.

It would be my pleasure if you are interested in contributing to the project in any role. It could be as a developer, document writer, tester or just providing feedback as a user.

Download Windows Installer or Portable Zip from here: MindMate

(MindMate only supports Windows 10 for now, will test and build it for earlier version soon. MindMate works fine on Windows 10, 8 and  7)

Review: Nietzsche and the Postmodern Condition by Rick Roderick

Rick Roderick in his overbearing sarcastic style thrashes popular culture and modernity with the aid of Nietzsche’s writings.

He describes Nietzsche as a ‘Master of Suspicion’, a phrase taken from Paul Ricœur. Nietzsche’s definition of truth, the coin worn out by constant use losing its real value and leaving just the metal behind, is epitomical of his method of suspicion. So often we take our understanding of truths for granted, not bothering to see what it really is.

Rick Roderick reads Nietzsche in a much more metaphorical way than other scholars I have come across. For him, Nietzsche’s eternal recurrence is not a theory about cosmology, rather it is meant to challenge you to live a life that you would want to relive over and over. Same applies to Nietzsche writings about God.

Rick Roderick finds plain and simple atheism boring as it doesn’t add value or tell you anything meaningful. On the other hand, writers like Nietzsche are interesting as they understand the significance of religion for humankind and feel the gravity of our condition.

Rick sarcastically criticizes modernity and popular western culture. Donald Trump and other names prop up from time to time in this regard.

In the lecture on the genealogy of morals, Rick talks about the immoral beginning of our morals and the values behind our values. He questions all the talk about love by preachers and looks at it with suspicion. In particular, he cites Thomas Aquinas regarding the desire of believers to watch bad people burn in hell and take satisfaction out of it.

On Nietzsche’s will to power, Rick Roderick defends him on the charge of providing philosophical fuel for fascism. He spends the most time with Michel Foucault’s expansion of Nietzsche’s arguments in his book, Discipline and Punish.

Rick praises Nietzschean analysis of how knowledge is always surrounded by structures of power.

For detailed notes, check out this link.

Review: ​ Philosophy and Human Values by Rick Roderick

The series of lectures is a passionate critique of modern mass culture with frequent references to contemporary politics and Hollywood films. Blade Runner, 1982 science fiction, get mentioned quite a few times in particular.

Do not expect a systematic, structured exposition of the topic, rather it’s an engaging series of lectures, more concerned with making ideas relevant to our present situation than getting the subject matter across.

Rick defines his personal position on values as fallibilist, it is to have strong beliefs about human values but without a further belief that you cannot be mistaken.

Starting with Socrates and his life of inquiry, he explains Greek values and the ideal of excellence. Moves on to how Epicureanism is associated more with the rising Roman empire while Stoicism with the declining.

He presents the two dominant modern ethical theories: Kant’s Categorical Imperative and Mill’s Utilitarianism. While having more admiration for Kant’s theory, Rick points out that neither theory is completely satisfactory.

Mill valued freedom too much to leave it at the mercy of his utilitarianism, so he came up with the harm principle, which is in some tension with his original theory. Harm principle only allows for coercion of individual by society to prevent harm to others.

But this conception of freedom by Mill is very thin, wholly negative. Freedom should be such that it enables you and gives you a real choice, not just an illusion of it.

When it comes to Hegel, each epoch in history defines freedom in its own terms. Left wing Hegelian, Karl Marx, expanded on this and developed a thorough criticism of Capitalism and a new ideal of freedom.

Finally, Rick talks about Nietzsche, master of suspicion, and then Kierkegaard, one of the most profound modern Christian thinkers.

You can find detailed lectures notes here. Also, full transcript of lectures is available at rickroderick.org

Completed ‘Introduction to Ariba’ course from openSAP

Ariba is a cloud-based Procurement and Supply Chain Management solutions from SAP.

This 3-week course ran from 10th November 2015 to 9th December 2015 and covered the following topics:

  • Week 1: The Digital Economy and Ariba Spend Visibility, Ariba Supplier Information Management
  • Week 2: Ariba Sourcing Professional, Ariba Contract Management, and Ariba Procure-to-Pay
  • Week 3: Ariba Network, Payment Innovations, and Seller Advantages


Review: Pixar in a box Tutorial by Khan Academy

Pixar is a box’ is an excellent tutorial at Khan Academy developed in collaboration with Pixar Animation Studios. It is about some of the Math concepts that we learn in school and how they apply to making animated movies. The content is meant for secondary school students (and above Smile).

Tutorial sketches a broad outline of the pipeline for producing animation, with each lesson digging deeper into a particular concept and its Mathematics.

1- Environment Modeling talks about representing curves (parabolic curves) using three points, rather than equations. It is more intuitive to work with three control points while designing and animating curves. This knowledge about curves is applied to create grass blade. A lot of grass blades are put together with randomness and animation offsets to create a natural looking grass field.

2- Character Modeling describes how polygons are used to start modeling shapes and subdivision algorithm is used to smoothen out the edges. 2D sketch of Human hand is designed using this technique without much effort. The crux of the lesson is the mathematics of subdivision and its application in 2D and 3D.

3- Animation lesson explains the role of Bezier curve in representing animation. A realistic bouncing ball animation is created in hands-on exercise.

4- Crowds are created by joining a number of parts in various combinations.  Lesson explores the concepts of permutations and apply it to calculating the number of possible combinations.

5- Sets & Staging deals with placing characters in the environment. Environment contains various objects which are placed around in the scene after scaling and rotating them as required. The lesson explains the mathematics behind these geometric transformations.

6- Rendering is a particularly exciting lesson which brings out the complexity of the whole process. While rendering we have to determine the color of each pixel in a frame taking into account all the light sources, camera position, all objects in the scene and how each object reflects or refracts light. This is done by casting rays out of the light sources and bouncing them off various surfaces. Diffuse and Specular properties of a surface determine how light will be reflected by it.

‘‘Pixar in a box’ is highly recommended as a fun way to learn.

Pixar in a box

Developed a basic, light-weight library for scheduling tasks in C# .Net

Source code can be found at GitHub


TaskScheduler is a simple and efficient C# .Net library that runs given tasks at the specified date and time.

  • Efficient : There is no polling. Only runs when a task is due. This is achieved though AutoResetEvent.
  • Simple : Merely 8 KB in size. Pretty easy to use but addresses limited number of use cases.


.Net Framework comes with various Timer classes which give us the ability to run a task periodically.

Apart from Timers which run periodically, we don’t have any class which executes tasks at a given time. A usual work around is to use Timer of a second or so (based on your need), then keep checking if any task is due in timer’s event and execute the task when due. In order to be more resource friendly, TaskSchedular takes a different approach instead of continuous polling for task due date.

How TaskScheduler Works

It runs in it’s own thread and doesn’t consume any CPU resouces till a task is due. This is acheived through Wait Handle (AutoResetEvent). All scheduled tasks are executed in the same thread, which means:

  • tasks are not running in GUI thread so any code which is related to GUI should be invoked on the GUI thread. See this blog post for running code in GUI thread using Control.Invoke.
  • tasks are never executed in parallel as there is only one thread. This has following upshots:
    • saves us from thread synhronization issues within tasks.
    • this library might not the the right one for you if you need more parallelism. In such a case, check out alternatives like Quartz.NET and FluentScheduler.


Starting TaskScheduler
var schedular = new TaskSchedular.TaskSchedular();
Adding task
schedular.AddTask(new TaskSchedular.Task()
        StartTime = DateTime.Now.AddSeconds(30),
        TaskAction = () =>
            // do some work here
        Recurrance = TimeSpan.FromSeconds(30)

Note: TaskSchedular is has a tolerance of 1 second by default, that is, if a task is due within a second, it will execute it right away.

Book Review: Operational Decision Management for Dummies

ODM for Dummies BookBusiness rules and validations related to an automated Business Process are generally hidden deep within the application source code and configuration settings. They are not openly accessible, easily to change or review. They might be duplicated several times across the source code.

Operational Decision Management (ODM) systems try to remedy this situation by providing a central repository for business rules. This repository acts as a single source of truth for users as well as systems. Rules are generally specified in the form of Decision Tables or Trees.

ODM complements BPM (Business Process Management) systems well, as BPM is also metadata driven with a focus on business process workflows and SOA (Serice Oriented Architecture) for integration.

Operational Decision Management for Dummies is a free booklet sponsored by IBM which provides a nice and quick definition of ODM systems. It is recommended for anyone interested in understanding what ODM is, what are its use cases and potential pay offs.

You can also check out this article for some concrete examples on how operational decisions (business rules) are automated by any ODM system.

MouseHover event in Windows Forms .Net – Generating it repeatedly

MouseHover Event

When mouse is stationary for some time over a Windows Forms control, Mouse Hover event is generated. This event is generated only once during mouse’s stay and movement over a control. If mouse leaves and re-enters the control, system again starts tracking for Mouse Hover and will generate the event accordingly.

A common use of Mouse Hover event is to display tool tip.

Following code attaches MouseHover handler to a control.

myControl.MouseHover += myControl_MouseHover;

The handler just logs that event is generated.

void myControl_MouseHover(object sender, EventArgs e)
        "MouseHover event generated");

Generating Mouse Hover event repeatedly

In some scenarios, it could be desirable to generate Mouse Hover event repeatedly inside a control, whenever mouse becomes stationary. For instance, this could be useful if you have a user-drawn control and want to generate Mouse Hover events for individual user-drawn components. To achieve this, we need to reset the Hover event every time it is generated. This can be done by calling TrackMouseEvent method in MouseMove event.

Adding MouseMove event handler…

myControl.MouseMove += myControl_MouseMove;

Calling TrackMouseEvent to reset tracking of Hover event:

void myControl_MouseMove(object sender, MouseEventArgs e)
    const uint HOVER_DEFAULT = 0xFFFFFFFF;
    TRACKMOUSEEVENT trackMouseEvent = 
    TrackMouseEvent(ref trackMouseEvent);

As TrackMouseEvent is a native method, we need to define it using DllImport along with the TRACKMOUSEEVENT structure.

static extern int TrackMouseEvent(ref TRACKMOUSEEVENT lpEventTrack);

    public Int32 cbSize;    // using Int32 instead of UInt32 is safe here, and this avoids casting the result  of Marshal.SizeOf()
    public TMEFlags dwFlags;
    public IntPtr hWnd;
    public UInt32 dwHoverTime;

    public TRACKMOUSEEVENT(TMEFlags dwFlags, IntPtr hWnd, UInt32 dwHoverTime)
        this.cbSize = System.Runtime.InteropServices.Marshal.SizeOf(typeof(TRACKMOUSEEVENT));
        this.dwFlags = dwFlags;
        this.hWnd = hWnd;
        this.dwHoverTime = dwHoverTime;

/// <summary>
/// The services requested. This member can be a combination of the following values.
/// </summary>
/// <seealso cref="http://msdn.microsoft.com/en-us/library/ms645604%28v=vs.85%29.aspx"/>
public enum TMEFlags : uint
    /// <summary>
    /// The caller wants to cancel a prior tracking request. The caller should also specify the type of tracking that it wants to cancel. For example, to cancel hover tracking, the caller must pass the TME_CANCEL and TME_HOVER flags.
    /// </summary>
    TME_CANCEL = 0x80000000,
    /// <summary>
    /// The caller wants hover notification. Notification is delivered as a WM_MOUSEHOVER message.
    /// If the caller requests hover tracking while hover tracking is already active, the hover timer will be reset.
    /// This flag is ignored if the mouse pointer is not over the specified window or area.
    /// </summary>
    TME_HOVER = 0x00000001,
    /// <summary>
    /// The caller wants leave notification. Notification is delivered as a WM_MOUSELEAVE message. If the mouse is not over the specified window or area, a leave notification is generated immediately and no further tracking is performed.
    /// </summary>
    TME_LEAVE = 0x00000002,
    /// <summary>
    /// The caller wants hover and leave notification for the nonclient areas. Notification is delivered as WM_NCMOUSEHOVER and WM_NCMOUSELEAVE messages.
    /// </summary>
    TME_NONCLIENT = 0x00000010,
    /// <summary>
    /// The function fills in the structure instead of treating it as a tracking request. The structure is filled such that had that structure been passed to TrackMouseEvent, it would generate the current tracking. The only anomaly is that the hover time-out returned is always the actual time-out and not HOVER_DEFAULT, if HOVER_DEFAULT was specified during the original TrackMouseEvent request.
    /// </summary>
    TME_QUERY = 0x40000000,

Above ensures that Hover event is generated whenever mouse stays still for sometime, and not only once after mouse enters the control.