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

<span class="if BIBTEXTYPE==article">Artikel</span> #37

Closed
Abakaba opened this issue Sep 18, 2018 · 6 comments
Closed

<span class="if BIBTEXTYPE==article">Artikel</span> #37

Abakaba opened this issue Sep 18, 2018 · 6 comments
Assignees

Comments

@Abakaba
Copy link

Abakaba commented Sep 18, 2018

Can I use the if statement also for BIBTEXTYPE?

@pcooksey pcooksey self-assigned this Sep 19, 2018
@pcooksey
Copy link
Owner

There is no == for the if statements. They only check if a class exists for that bibtex entry.

Currently if you use the bibtextype it will take the values found in this link. What you want is to customize the output for each bibtex type?

@pcooksey
Copy link
Owner

pcooksey commented Sep 19, 2018

Please checkout the develop branch (2e6098d) and let me know if it handles your case. I added == to the if statements. So in your case it should work like so:

<span class="if BIBTEXTYPEKEY==@ARTICLE">Artikel</span>

Notice that I've used BIBTEXTYPEKEY and not BIBTEXTYPE which is set internally to defined values. The wiki was missing BIBTEXTYPEKEY updated wiki link. Also, @ARTICLE needs to be capitalized and have an @ symbol in the beginning.

@Abakaba
Copy link
Author

Abakaba commented Sep 21, 2018

Cool! This works nicely! Many thanks.
This allows me now to have a lable on the publication type per bibtex entry.
As soon as my page is ready, I will share it with you.

@Abakaba Abakaba closed this as completed Sep 21, 2018
@Abakaba
Copy link
Author

Abakaba commented Oct 9, 2018

I am just wondering if you plan to merge this feature in the master branch?
Furthermore, it seems like the develop branch (2e6098d) an d all latest branches do not display special characters. e.g. {~n} or {'o}.

I would really appreciate if you can generate one version which contains the functionality
Artikel and displays special characters.

Many thanks in advance.

@Abakaba Abakaba reopened this Oct 9, 2018
@pcooksey
Copy link
Owner

Of course! Just got a little busy. I've merged the == into master (2e6098d).

As for the displaying special characters,

  1. Special characters are entered as {\"a} or {\"{a}} not \"{a}.

So you should escape the special character. This was found in Chapter 2 Helpful Tips
So, it works for me when doing {\~n}

That said, I do believe there are some lingering issues with the special character display. So I'll create a new issue #38 for generating a test for all the special characters that are supported by bibtex. However, this may take some time as I am in the middle of other work.

@pcooksey
Copy link
Owner

I'm closing this issue. Please refer to issue #38 if you are still having issues with displaying special characters.

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