-
Notifications
You must be signed in to change notification settings - Fork 557
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
Xnos addition #94
Xnos addition #94
Conversation
great, thanks. was the |
Yep, that's an ide artifact, didn't intend to add it. Also still need to fix the Travis yaml, I likely just need to include sudo permissions on the pip install so that it adds to PATH. Do you know whether OSX High Sierra includes pip3 by default? I'm currently using system python, which probably isn't a great replication of a working environment. |
If you are running Python 3, then most likely
Not sure why the test is failing here but I'll have a look if you don't manage to work it out. |
Just using pip3 fixed everything. Let me know if you're wanting to merge or make any more changes beforehand. |
Thanks for sorting this out, and from a quick review it looks good to me. I'll do a bit of testing over the weekend and will merge unless anything comes up! |
@tompollard Just supporting this PR. I wanted the HTML output to also create clickable references to the pictures (the current implementations omits these likely due to the LaTeX annotation for referencing figures). Using
I tried to understand from your PR @dendrondal whether your commits include a similar 'fix', but am not sure. Did you encounter the LaTeX error
|
source/12_chapter_4.md
Outdated
|
||
<!-- | ||
Figures can be added with the following syntax: | ||
![my_caption \label{my_label}](source/figures/my_image.pdf){ width=50% } | ||
![main_text_caption](source/figures/my_image.pdf, "short_caption(optional)"){#fig:mylabel}{ width=50% } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here, there shouldn't be a comma between the image source and the short caption.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the support! I didn't realize it added links to the HTML, that's a nice bonus.
I'll fix that annotation, and see about fixing the template.tex
. To be honest, I had never used a template for the body and forgot to add it back in. I'll run it with the proposed changes to make sure it works as intended.
W.r.t. the no-prefix-figure
error message, that occurs if any figure doesn't have the {#number:label}
notation at the end. If I remember correctly, the pdf still compiled as expected, despite giving that error? I looked up this error on the fignos page, and it appears that adding the --standalone
flag may fix this, which will add some peace of mind for end users. Will try it out and get back to you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dendrondal sorry for not getting around to dealing with this yet. if you are planning an update, i'll hold on for that and will then check and merge. thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@davidverweij Can you elaborate a bit more on your issue with caption prefixes? I've re-run the build both with and without the addition to the template.tex
after adding the template
flag to the makefile, and the output appears the same to me.
README.md
Outdated
- [Pandoc](http://johnmacfarlane.net/pandoc), for converting the Markdown to the output format of your choice. You may also need to install [Pandoc cite-proc](http://pandoc.org/demo/example19/Extension-citations.html) to create the bibliography. | ||
- Install @martisak's shortcaption module for Pandoc, with `pip install pandoc-shortcaption` | ||
- [Pandoc](http://johnmacfarlane.net/pandoc), for converting the Markdown to the output format of your choice. | ||
- Pandoc plugins by running ```bash install.sh``` in the main direcotry |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you mean this bash script? I don't see it! Should the install instructions be added to the makefile instead? (e.g. with a make install
recipe)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, that script didn't make it to a later release, since the Dockerfile made it redundant. I've added it back in. Having a make install
recipe is an interesting idea. I'm going to put both in, as I don't want the lack of a shebang in the Makefile causing anyone headaches.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @dendrondal, this looks good. I've added a couple of minor comments. The main issue is that install.sh is missing currently. Should this be incorporated into the makefile?
|
||
\pagenumbering{roman} | ||
\setcounter{page}{3} | ||
\listoffigures |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just my 2 cents, but I would add a strong suggestion to ensure short captions are provided so this list remains comprehensible. Alternatively two figures (one with, and one without short caption) could show how to use this.
<!--
The \listoffigures will use short captions first, and the whole caption if none is present. To keep this list readable, ensure each figure has a short caption, e.g.
![main_text_caption](source/figures/my_image.pdf "short caption used in alt text and \listoffigures"){#fig:mylabel}{ width=50% }
-->
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added both for the sake of clarity.
Looks great, thanks @davidverweij and @dendrondal ! |
Adds Xnos & shorcaption compatibility, updating documentation accordingly, as outlined in #87