Closed jlaurens closed 3 months ago
That's fast, thanks. Although looks like the help message is backwards, it should be:
--- a/synctex_main.c
+++ b/synctex_main.c
@@ -257,8 +257,8 @@ int synctex_return(int status) {
p[length] = 0;
if (strcmp(p, "?") == 0) {
puts("q to quit");
- puts("e line:column:input to edit");
- puts("v page:x:y to view");
+ puts("e page:x:y:file to edit");
+ puts("v line:column:input to view");
continue;
}
if (strcmp(p, "q") == 0) {
Also regarding documentation, it seem to me that page_hint
argument does not really exist, unlike what is written in the documentation.
--- a/synctex_main.c
+++ b/synctex_main.c
@@ -356,17 +356,14 @@ void synctex_help_view(const char * error,...) {
fputs("synctex view: forwards or direct synchronization,\n"
"command sent by the editor to view the output corresponding to the position under the mouse\n"
"\n"
- "usage: synctex view -i line:column:[page_hint:]input -o output [-d directory] [-x viewer-command] [-h before/offset:middle/after]\n"
+ "usage: synctex view -i line:column:input -o output [-d directory] [-x viewer-command] [-h before/offset:middle/after]\n"
"\n"
- "-i line:column:[page_hint:]input\n"
+ "-i line:column:input\n"
" specify the line, column, optional page hint and input file.\n"
" The line and column are 1 based integers,\n"
" they allow to identify every character in a file.\n"
" column is the offset of a character relative to the containing line.\n"
" Pass 0 if this information is not relevant.\n"
- " page_hint is the currently displayed page number.\n"
- " If there is an answer on that page, it will be returned.\n"
- " Pass 0 if this information is not available to you.\n"
" input is either the name of the main source file or an included document.\n"
" It must be the very name as understood by TeX, id est the name exactly as it appears in the log file.\n"
" It does not matter if the file actually exists or not, except that the command is not really useful.\n"
Now with page_hint
implemented we can update the document for consistentency.
https://github.com/user202729/synctex/commit/249fd850f7150f6f0cd50de7853a08b50cf51d82
Actually, the correct specification would be line[:column[[:page_hint]:input]]
, but that's way too clunky.
new interactive mode