def unicode_item_filter(item, action_dict):
    """
    Filter table items by category and search string

    action_dict has the following entries controlling filtering:
        cat_filter - filter for the category. if None ignore filter. 'L*' filters any Letter category
        name_filter is a keyword to find the the char name, None for no filter
        item_data ['no_filter'] True then passes filter automatically
    """
    try:
        if item.item_data and item.item_data['no_filter'] is True:
            return (False, True)
    except KeyError:
        pass

    try:
        cat_filter = action_dict['cat_filter']
        in_name = action_dict['name_filter']
    except (KeyError):
        return (False, True)

    cat1 = cat2 = None

    if cat_filter is not None and len(cat_filter) == 2:
        cat1 = cat_filter[0] if cat_filter[0] != '*' else None
        cat2 = cat_filter[1] if cat_filter[1] != '*' else None

    ch_name = item.values[1]
    ch_cat = item.values[2]

    try:
        if (cat1 is None or ch_cat[0]==cat1) and (cat2 is None or ch_cat[1]==cat2) and (in_name is None or in_name in ch_name):
            return (False, True)
    except (IndexError, TypeError):
        pass

    return (True, False)