'Get display name for given window.
Depending on its state minimized, maximized and floating
appropriate characters are prepended.'

def get_taskname(self, window):

    state = ''
    if (window is None):
        pass
    elif window.minimized:
        state = self.txt_minimized
    elif window.maximized:
        state = self.txt_maximized
    elif window.floating:
        state = self.txt_floating
    return ('%s%s' % (state, (window.name if (window and window.name) else '?')))
