This content has been marked as final. Show 6 replies
That's a really good riddle!
The only object I could think of that fits the clue is Character. Sure
enough Character is listed in the OMV under the possible parents of a
Character. Under what situation that can happen? I've no idea... =-O
You're on the right track, but it's not character (nor any text object). The parent of a character is always the story (or XMLStory).
What do you know, I've just found two other related objects that have the same characteristic. They can be their own parent -- by which I mean, if you ask for:
the object you get is myObj. Even to the extent that:
myObj.parent == myObj
Okay. So when is a Cell its own parent?
myCell = myTable.cells;
myOtherCellRef = myCell.cells;
myOtherCellRef == myCell; returns true
myOtherCellRef.parent == myCell; also returns true
same thing happens with rows (and I assume columns).
I suspect that it has something to do with the fact that you can reference sets of cells or it could just be an accidental thing.
myCell = myTable.cells.cells.cells.cells;
also works and gives you the same cell and if you work your way up the parental chain it takes you four steps to get to the table.
The same basic concept applies to text objects. A
Character.characters.characters, etc. will always be the same
object. It only works down the parent chain. If you work up the chain,
the immediate parent will be the story.
I think the fact that it works down the chain is probably a feature
(i.e. if you do a search you can refer to characters no matter what
the search returns -- even a Character). The fact that cells work up the
chain is probably a bug...