Bo Peng wrote: > Now, JMarc mentioned that he would like to use a map for embedded > files.
That seems natural to me: At some place you have to translate from external to embedded names. Using a map for this purpose would fit exactly. If you need also the reverse translation then it might not be the best fit anymore, but unless there are some speed problems I'd probably still use it. > What do you have in mind? This is not a standalone problem > because this EmbeddedFileList can be looked up by 'absFilename()' and > by 'embeddedFilename()' because InsetGraphics can use either file, > depending on the embedding status. When this inset calls > registerEmbeddedFiles(), it can pass either name to the function. I would design the interface in such a way that it is always clear which name has to be used. IMO there are three types of names: - always embedded - always external - depending on the embedded status of that inset, either external or embedded. In other words, it is always exactly defined whether a name is embedded or external. > This is actually also related to the original problem with [Embedding > discussion 1], do we want multiple entries for multiple insets > referring to the same file? I would prefer to have each file only once. It does not make sense to me to allow to embed a file for one inset, but then say in another inset that also uses the same file to not embed it. That is a contradiction that should not exist IMO. Disclaimer: I did not look at or compile any code, and do not have the time to get deeper involved, so ignore all this if it does not make sense. Georg