use of org.rstudio.studio.client.common.synctex.model.SourceLocation in project rstudio by rstudio.
the class TextEditingTarget method doSynctexSearch.
private void doSynctexSearch(boolean fromClick) {
SourceLocation sourceLocation = getSelectionAsSourceLocation(fromClick);
if (sourceLocation == null)
return;
// compute the target pdf
FileSystemItem editorFile = FileSystemItem.createFile(docUpdateSentinel_.getPath());
FileSystemItem targetFile = compilePdfHelper_.getTargetFile(editorFile);
String pdfFile = targetFile.getParentPath().completePath(targetFile.getStem() + ".pdf");
synctex_.forwardSearch(pdfFile, sourceLocation);
}
Aggregations