def METHOD_NAME(self, object, style, width, trait):
    content = []
    shape = object.shape
    format_func = self.editor.factory.format_func
    format_str = self.editor.factory.format_str
    for i in range(shape[0]):
        items = []
        for j in range(shape[1]):
            name = "f%d_%d" % (i, j)
            self.add_trait(
                name,
                trait(
                    object[i, j],
                    event="field",
                    auto_set=self.editor.factory.auto_set,
                    enter_set=self.editor.factory.enter_set,
                ),
            )
            items.append(
                Item(
                    name=name,
                    style=style,
                    width=width,
                    format_func=format_func,
                    format_str=format_str,
                    padding=-3,
                )
            )
        group = Group(orientation="horizontal", show_labels=False, *items)
        content.append(group)
    return View(Group(show_labels=False, *content))