Is there a function in the OTAPI that returns the symbol name at the cursor? I don't want to know how to parse that myself using the editor buffer!

Is there a function in the OTAPI that returns the symbol name at the cursor? I don't want to know how to parse that myself using the editor buffer!

Comments

  1. Does OTAPI have any parsing services?

    ReplyDelete
  2. You might want to use CodeDom via IOTACodeDomProvider.

    ReplyDelete
  3. Hi 
    Unfortunately there is not OTAPI function. Look in the Gx_OTAUtils of the GExperts Project. The Function calls GxOtaGetCurrentIdentEx

    ReplyDelete
  4. I do use the private API function Editorbuffer.GetEditorToken for "[x] Find text at cursor"

    ReplyDelete
  5. Uwe Schuster And how can I get that function?

    ReplyDelete
  6. Stefan Glienke You're kidding me. Searching for Editorbuffer@GetEditorToken in $(BDSBIN) does not find coreide*.bpl and you don't know how to invoke such a function?

    ReplyDelete
  7. If its exported by the bpl it's not private, isn't it?

    ReplyDelete
  8. "private API" and not just private means in the OTA context something that an IDE developer would use. As IDE developer one would add EditorBuffer to the uses clause and write something like "S := GetEditorToken(TEditView(EV), 256, ['A'..'Z', 'a'..'z', '_', '0'..'9'], True, reAll);".

    ReplyDelete

Post a Comment