Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

replace auxiliary tex filename indices with names #3

Open
johnyf opened this issue Jul 18, 2014 · 2 comments
Open

replace auxiliary tex filename indices with names #3

johnyf opened this issue Jul 18, 2014 · 2 comments

Comments

@johnyf
Copy link
Contributor

johnyf commented Jul 18, 2014

Attempting to compile subsets of a document (e.g., a single beamer slide) can result in a different value for the fignum counter. As a result, the ordering of figures is corrupted and they appear shifted inside the document. So one needs to repeatedly compile the whole document to maintain them at the correct positions.

If external dot files are used, then the input file name can be substituted as part of the output file name. This will ensure a consistent mapping between included graphs and the included tex files containing the corresponding tikz code. The difference is analogous to that between a list and a dict.

For inline dot code within dot2tex environments, file indexing could still be used, but an optional environment parameter can be added, to provide a name for each graph, to be used as the distinguishing substring in the auxiliary file's name.

@kjellmf
Copy link
Collaborator

kjellmf commented Jul 18, 2014

Good idea. I will add support for this in the next version of dot2tex and dot2texi.sty

@johnyf
Copy link
Contributor Author

johnyf commented Jul 20, 2014

2588e9d4318adab459941b9c2bcb885bebc021a2 introduces a \includedottex command (a previous version of which was mentioned in #2), with auxiliary tex file names that are derived from the dot file paths, by replacing / by _ and ./ by _ using package xstring. The reason for maintaining the complete path in the file name is to avoid name conflicts of identically named files that reside in different paths.

It introduces also a new option force, to tell dot2tex to convert the dot file irrespective of the freshness of the corresponding output file.

I can send a pull request if it seems appropriate (though I am not a tex expert, so some additional work may be needed to make this cross-platform).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants