Dear LyX-Developers, After spending some time this morning looking at various LFUNs that are used to insert different types of insets (e.g., LFUN_NOTE_INSERT, etc.), I had a question about what the best way to programmatically create an inset with text is.
Here is what I would like to accomplish: From within one of the two custom views I'm creating (expanded outline pane/corkboard), I'd like for a user to create a new section, or new summary note. In the view, a new object will appear that prompts for text. Then, once the text has been entered and the display destroyed, a method will then locate the appropriate place in the document and add the correct type of inset with text. In the example of the note inset, I thought it might be possible to chain several together several existing LFUNs, specifically LFUN_NOTE_INSERT and LFUN_SELF_INSERT. I haven't yet worked out what the best way to do this with headings is yet. So, I suppose here is my question: Is this the best way to do this, or am I missing something? Is there another LFUN that can be used to add an inset (with text) to a particular location in a document? I'd appreciate any thoughts. Cheers, Rob
