jinwen-xu / colorist Goto Github PK
View Code? Open in Web Editor NEWWrite your articles or books in a colorful way
Home Page: https://ctan.org/pkg/colorist
License: LaTeX Project Public License v1.3c
Write your articles or books in a colorful way
Home Page: https://ctan.org/pkg/colorist
License: LaTeX Project Public License v1.3c
Hi, I know that hyperref
is turned off in the fast
mode, as can been seen here.
fast
Mode with hyperref
- Class:
beaulivre
- LaTeX Engine: TeX Live 2022 on macOS (with all updates)
However, turning that off completely can introduce some trouble in the document. I have been using this code (repo here) in the preamble to do hyperref
stuff only when fast
mode is false:
\newcommand{\turnoffhypercolor}{\relax}
\ExplSyntaxOn
\bool_if:NF \l__colorclass_fast_bool
{
\hypersetup
{
, pdfauthor = { Wuqiong~Zhao~(Teddy~van~Jerry) }
, pdftitle = { mmCEsim~Documentation~\&~Tutorials }
, pdfsubject = { mmCEsim }
, colorlinks = true
, urlcolor = blue
, linkcolor = purple
, citecolor = red
}
\renewcommand{\turnoffhypercolor}{\hypersetup{hidelinks}}
}
\ExplSyntaxOff
But in the document, we may sometimes use the \hyperref
macro, for example
% Though \ref would do, we are just using this as an exmaple.
View \hyperref[sec:foo]{this section} for details.
\section{Foo}\label{sec:foo}
Check the fast
mode in the main document can be tedious.
I have tested by changing this line in the generated colorist-fancy.sty
and it worked properly. With my limited LaTeX knowledge, I reckon hyperref
in the draft
mode should work since no actual link is activated.
\bool_if:NTF \l__colorist_fast_bool
{
\RequirePackage { hyperref } % <- added
\hypersetup { draft } % <- added
% original setup for `\href` or `\texorpdfstring` removed
}
{
\RequirePackage { hyperref }
\RequirePackage { bookmark }
\hypersetup{ hidelinks, linktoc = all }
\bookmarksetup{ numbered }
% other stuff
}
The original way is to provide frequently used macros, but that can miss some (for instance \hyperref
or \hypertarget
) which can be dangerous, so maybe draft
mode of hyperref
should be more desirable? I noticed that the compiling speed is quite okay.
I really love this template and am wondering if pull requests are accepted. Since I have noticed that all commit messages are written in that format, I am not quite sure what to do if I submit a pull request to provide more functionality or enhance the documentation.
Here is a small list I propose to work on:
hyperref
option interface, as is in the beamer
class, so that I can use colorlinks
without influencing the colour in ToC;subsection
like that in memdesign which aligns those in a row so a lot of space would be saved. This is especially useful for the beaulivre
class since a book can be quite long;Thanks again for your work in providing this beautiful template.
I would like to use the normal font rather than sffamily for title page and contents. I am personally not a big fan of sffamily fonts. I was wondering if there was a way to keep them to default ones.
I want to create an environment called "goal" and have it be formatted the same way as a theorem. I'm unsure of how to do this in an efficient way.
I want to see examples of this package but can't find any here or online.
I then installed from CTAN, but it seems the .dtx file was not used to generate any PDF documentation.
Hi, I am really fascinated by this beautiful template. Currently, I am writing a tutorial book with beaulivre
.
Since I am not familiar with expl3, so I am not sure how to use index (command \index{item}
) in the document. So will there be native support for index? Personally I find it quite similar to the \DNF<>
command.
Thank you in advance!
I am now encountering a problem after updating beaulivre
and projlib
to the latest CTAN version (i.e. 0424).
I reckon this has something to do with the newly added theorem environment or their modification (Commits 5aeedfe, 8a52345, 27bae10, 455643f).
Due to my poor knowledge of expl3 and understanding of projlib
package, I cannot figure out where the problem lies.
beaulivre
0424, projlib
0424I am using LaTeXmk (XeLaTeX) to compile my document which has the class as
\documentclass[Chinese,TC,use boldface,simple name]{beaulivre} % the same result with `fast' option
Compile with options
latexmk -synctex=1 -interaction=nonstopmode -file-line-error -pdfxe
And with one of the errors
/usr/local/texlive/2022/texmf-dist/tex/latex/projlib/projlib-theorem.sty:167: Package create-theorem Error: The theorem-like environment "application"
(create-theorem) cannot be created, you have to name it
(create-theorem) before initialization.
Type <return> to continue.
...
l.167 }
In all, application
, claim
, construction
, recall
, proposition-definition
, theorem-definition
fail but I did not use these enviormnets in my document.
The complete log information is here.
Thank you in advance!
A minimal example
\documentclass{colorbook}
\title{Title}
\author{John Doe}
\begin{document}
\maketitle
\end{document}
results in two error messages, because of undefined control sequences:
./test.tex:5: Undefined control sequence.
\maketitle ...itle/before}\LocallyStopLineNumbers
\ProjLibTitlePage {,title=...l.5 \maketitle
(/usr/local/texlive/2022/texmf-dist/tex/latex/tex-gyre/t1qhv.fd) [1{/usr/local/texlive/2022/texmf-var/fonts/map/pdftex/updmap/pdftex.map}] [2]
./test.tex:5: Undefined control sequence.
\maketitle ...or ,date=\@date }\ResumeLineNumbers
\UseHook {cmd/maketitle/af...l.5 \maketitle
I do not know, if this is intended. Al least this usually wouldn't be expected.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.