Specifying custom Bounds for a component, for use with the '(F)rame' shortcut
Let's say I have a component that has various properties which represent a physical amount of space in the scene... something like a LineRenderer with a string of points, or some other form of programmatic spatial representation (not a Mesh or Collider, etc.)
Is there a way to specify the world space Bounds of this object (which I would calculate using my custom properties) so that the (F)rame shortcut will work accurately? Something like a override Bounds GetComponentBounds() interface I can override in my script?
Or is there some other way to override the Bounds used by the (F)rame shortcut, so I can update it when my object is selected?
I'm looking for a solution as well. I need this everytime I create a waypoint system or anything with lines, that are not rendered but have a volume which should be focussed when editing points.
Yeah, those are the same cases I'd like it for, also... but I still haven't found a solution yet. Let me know if you find something.
This is not a solution to what should be some kind of override for the built-in Frame command, but it's possible to call SceneViewo.lastActiveScene.Frame(Bounds) ourselves. In special cases (like a custom inspector and scene view tool), we could intercept all keyboard commands in the scene view and watch for the 'F', calling the frame method ourselves.