racket / racket/gui

Alt+Q reflow does not take into account indentation

Open
#45 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Racket
Stars
68
Forks
82
PR merge metrics
No merged PRs in 30d

Description

Racket version: 20160914-62f5b2c (today's nightly)

With the default paragraph width of 60, the X on the third line is character number 61, but Alt+Q does nothing. If an extra character is added, then Alt+Q correctly moves the last word of the third line to the fourth.

#lang scribble/manual
1234@tt{9 123456789 123456789 123456789 123456789 1234567890
 23456789 123456789 123456789 123456789 123456789 1234567890X
 23456789}

If an extra level of indentation is added, then two characters past the limit are ignored, so I think the spaces due to indentation are ignored.

#lang scribble/manual
1234@tt{9 123456789 123456789 123456789 123456789 123456789 123456789 1234567890
 @emph{89 123456789 123456789 123456789 123456789 123456789 123456789 1234567890
  3456789 123456789 123456789 123456789 123456789 123456789 123456789 1234567890XY
  3456789}}

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 Alt+Q behavior with the two Scribble snippets in the issue using the reported Racket nightly, then trace the GUI paragraph-reflow entry point. Done means reflow recognizes indentation when determining the paragraph width and moves words at the expected boundary in both examples; add regression coverage if the existing test location can be identified.

Written by the indexing model from the issue text.

Assessment

Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.