Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Regarding marker in the external file

Generally speaking, marker persistence (aka resource on which it is created) is not necessary tied to annotation displayed in an editor.

You can create a marker on a project/workspace resource with a special attribute recognized by your model.  And then attach to editors a custom annotation model that would search through existing markers and display annotations for the relevant ones.


One example of such annotation model is org.eclipse.cdt.internal.ui.editor.ExternalSearchAnnotationModel . If you create a marker on any resource with an attribute ICModelMarker.C_MODEL_MARKER_EXTERNAL_LOCATION with value of external file path, an annotation will be displayed in editor for that path.


Another example with breakpoints is org.eclipse.cdt.dsf.mi.service.MIBreakpointsManager.addBreakpointProblemMarker. You can attempt to set a breakpoint on external file and follow how the new problem marker is set.








From: cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Srirekha P. K.
Sent: Tuesday, June 17, 2014 14:35
To: cdt-dev@xxxxxxxxxxx
Subject: [cdt-dev] Regarding marker in the external file




How can I add markers in an external file opened in eclipse editor?


 When I tried to create marker, I am getting null for the resource,  since the file is  not in the workspace. But it is possible to add breakpoint in the external file. Could anyone help me?





Confidentiality Statement / Disclaimer : This message and any attachments is intended for the sole use of the intended recipient. It may contain confidential information. Any unauthorized use, dissemination or modification is strictly prohibited. If you are not the intended recipient, please notify the sender immediately then delete it from all your systems, and do not copy, use or print. Internet communications are not secure and it is the responsibility of the recipient to make sure that it is virus/malicious code exempt.

The company/sender cannot be responsible for any unauthorized alterations or modifications made to the contents. If you require any form of confirmation of the contents, please contact the company/sender. The company/sender is not liable for any errors or omissions in the content of this message.

Back to the top