From ce495dfbfd3eaecb84b3c536ad2176a7249d5b19 Mon Sep 17 00:00:00 2001 From: Loek Le Blansch Date: Thu, 5 Sep 2024 08:30:46 +0200 Subject: add some banned practices to contributing.md --- contributing.md | 16 ++++++++++++++++ projdoc.cls | 5 +++++ time.txt | 1 + 3 files changed, 22 insertions(+) diff --git a/contributing.md b/contributing.md index ab14b71..770d02e 100644 --- a/contributing.md +++ b/contributing.md @@ -15,6 +15,22 @@ other document. - Images should be placed in the img/ folder - Labels and bibliography keys should only consist of characters from the following set: `[a-z0-9:-]` (lower-case, numbers, colon, dash). +- Quotes are opened with the tilde (`) + +# Banned practices + +- **Using `\newpage`** + + Widows and orphans are handled by LaTeX. If you want to prevent a page break + from occurring between two paragraphs, use the `\noparbreak` command at the + end of the first paragraph. For larger chunks, the `\needspace{}` + command should be used instead. +- **Using `\href`** + + Add the source in sources.bib and cite this source instead. +- **Using `\textbf` or `\textit` to emphasize** + + Use `\emph`, single quotes or an em dash (`---`) instead. # References diff --git a/projdoc.cls b/projdoc.cls index b43fe56..c6abaca 100644 --- a/projdoc.cls +++ b/projdoc.cls @@ -259,3 +259,8 @@ \fitimg{\includegraphics[scale=0.6]{#1}}% } +% prevent page break between two paragraphs +\makeatletter +\newcommand\noparbreak{\par\nobreak\@afterheading} +\makeatother + diff --git a/time.txt b/time.txt index 6a592e0..22ed74f 100644 --- a/time.txt +++ b/time.txt @@ -6,6 +6,7 @@ loek: 2024-09-04 1h30m repository scaffolding / latex example code loek: 2024-09-04 50m poc / dynamic library linking test example loek: 2024-09-04 45m repository scaffolding / visual studio code latex configuration loek: 2024-09-04 20m repository scaffolding / visual studio code cmake configuration +loek: 2024-09-05 15m repository scaffolding / additional latex contributing guidelines # vim:ft=cfg -- cgit v1.2.3