def encode_label(text):
    """Encode text escapes for the static control and button labels

    The ampersand (&) needs to be encoded as && for wx.StaticText
    and wx.Button in order to keep it from signifying an accelerator.
    """
    return text.replace("&", "&&")