rust-lang / rust-lang/rust

Typography: Sentence-ending punctuation (e.g., period) appears at the start of a new line.

Open
#148,254 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-rustdoc-ui T-rustdoc T-rustdoc-frontend
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

🐞 Typography: Punctuation Mark at Start of New Line

Description

When a long line of documentation is automatically wrapped, the period (full stop) or comma is occasionally displayed as the first character of the next line. This is against common typographic rules (widow/orphan control) and affects readability.

Where I found it

I found that when I read crate bytes . It looks like:

Image

And I checked the source code of the doc code in line 65 to 72 , it seems right.

Environment

Detail Value
Browser Google Chrome
Version 141.0.7390.123 (Official Build) (64 bit)
Operating System Windows 11 Pro
OS Version Code 25H2 (Build 26200.7019)
Screen Resolution 1920 x 1080
Display Scaling 150%

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the wrapping issue on the docs.rs bytes relation-with-read-and-write page, then compare it with the linked bytes source at src/lib.rs lines 65–72. Trace which documentation-rendering component controls line wrapping; done means sentence-ending periods and commas no longer appear as the first character of a line.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
documentation
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.