'Method to align the widgets laid out in a single row.
The horizontal spacing will be fixed. Identify all widgets
that can grow horizontally and let them do so. If their are
multiple widgets that can grow then they will all grow by the
same amount.
Any space that is left over will be added to a margin between
the widgets
@todo: parameter description'

def alignRow(self, block, widthShortfall):

    canGrowCount = 0
    for widget in block.widgetList:
        if widget.canGrowHorizontal():
            canGrowCount += 1
    if (canGrowCount > 0):
        growBy = (widthShortfall / canGrowCount)
        if (growBy > 0):
            for widget in block.widgetList:
                if widget.canGrowHorizontal():
                    widget.growHorizontal(growBy)
                    widthShortfall -= growBy
    if (widthShortfall > 0):
        marginGrow = (widthShortfall / len(block.widgetList))
        if (marginGrow > 0):
            for widget in block.widgetList:
                widget.addToHorizontalMargin(marginGrow)
                widthShortfall -= marginGrow
    if (widthShortfall > 0):
        for widget in block.widgetList:
            widget.addToHorizontalMargin(1)
            widthShortfall -= 1
            if (widthShortfall == 0):
                break
    for widget in block.widgetList:
        widgetHeight = (block.startPosn[0] + widget.getMatrixSize()[0])
        heightShortfall = (block.growToHeight - widgetHeight)
        if (heightShortfall > 0):
            if widget.canGrowVertical():
                widget.growVertical(heightShortfall)
            else:
                widget.addToVerticalMargin(heightShortfall)
