I tried to create Customer attribute which renders as readonly in the backend, but couldn't find an easy way to do it.
"Easy" for me means a new flag when creating an attribute (like label, frontend_class etc.) - say adminhtml_readonly - which changes the way its default renderer displays the input - exactly the way it renders when the attribute is locked().
Although the classes that render various HTML elements do support readonly functionality, I'm not sure if those can be easily coupled with an EAV attr flag.
I guess this can only be done for a couple of inputs, like text, textarea, but it'll be nice to be able to mark the attribute as readonly even for (multi)selects, file, images or others.