EDIT: CEikGlobalEditor's ConstructL also takes parent as a parameter (which was already set to this), so the SetMopParent apparently does not do anything. Now I wonder what the MopParent should really point to.
Okay, I have now stepped through iInfo->UpdateScrollBarsL() to see what happens (if anything should happen). It seems to calculate if the scrollbar should be shown and then size (relic from Psion, I guess) and location for the scroller thumb. Then it attempts to draw the scrollbar, which does not either draw anything or produce anything that would resemble an error. Despite this, ScrollBarExists() returns false.
One problem with scrollbars on the S60 platform is that the area where the scrollbars are drawn belongs to the topmost control. With SetMopParent you have to establish the path so that the element who wants to draw the scrollbar can get to the topmost Control.
In other words, each control has to call SetMopParent on all the other controls it contains. This has to start with the view class or the AppUi class. The important thing is to call SetMopParent *before* ConstructL.
If one element in does not call SetMopParent for its component, the editor has no way to get to the control which own the scrollbar area and cannot draw one.
I have the following code:
iEditor = new (ELeave) CEikRichTextEditor();