David Richardson
bb1cd85466
AppKit: Add justified text alignment to CPTypesetter
...
CPTypesetter lacked handling for CPJustifiedTextAlignment, causing justified paragraphs to fall back to left alignment. Additionally, centred and right-aligned text improperly spanned the full container width by ignoring paragraph indents, and trailing spaces on wrapped lines incorrectly shifted line positioning.
* AppKit/CPTextView/CPTypesetter.j:
- Implement CPJustifiedTextAlignment layout by distributing spare width evenly across line spaces.
- Preserve left alignment for paragraph final lines and segments preceding a tab, matching Cocoa behavior.
- Constrain centred, right-aligned, and justified lines between head and tail indents.
- Exclude trailing spaces from visible line width to allow proper hanging alignment.
* AppKit/CPTextView/CPLayoutManager.j:
- Update _CPLineFragment to record extra space widths and render spans with matching CSS word-spacing.
- Ensure fragment equality checks account for word-spacing variations.
* Tests/Manual/TextEditor/WORKLIST.md:
- Mark justified and centred text layout tests as completed.
Centred and justified paragraphs now conform to standard Cocoa layout behavior.
2026-10-24 10:17:42 -06:00
..
2026-10-09 16:47:46 -06:00
2026-10-09 16:47:46 -06:00
2026-10-20 17:35:13 -06:00
2026-08-27 23:17:15 -06:00
2026-10-23 16:45:51 -06:00
2026-10-06 17:42:56 -06:00
2026-09-01 08:34:36 -06:00
2026-10-24 10:17:42 -06:00
2026-10-23 20:20:51 -06:00
2026-10-06 19:40:40 -06:00
2020-10-02 12:13:00 +02:00
2022-12-09 10:15:38 +01:00
2019-03-28 14:01:31 -07:00
2013-08-12 16:46:14 +02:00
2026-10-06 18:50:09 -06:00
2026-08-25 22:34:22 -06:00
2026-10-09 16:47:46 -06:00
2026-08-24 09:21:10 -06:00
2026-07-21 15:15:53 -06:00
2013-01-23 15:48:55 +07:00
2012-12-20 14:22:09 +01:00
2014-11-06 10:17:05 -08:00
2012-12-20 14:22:09 +01:00
2013-01-23 15:48:55 +07:00
2012-12-20 14:22:09 +01:00
2026-07-21 15:15:53 -06:00
2026-10-23 19:30:48 -06:00
2013-03-13 12:22:10 -04:00
2026-10-22 12:37:02 -06:00
2014-11-06 10:17:05 -08:00
2026-07-21 15:15:53 -06:00
2015-07-02 16:35:35 -07:00
2026-10-23 16:45:51 -06:00
2020-03-11 10:30:00 +01:00
2025-09-02 17:38:10 +03:00
2026-07-21 15:15:53 -06:00
2019-06-24 17:36:15 +02:00
2026-07-21 15:15:53 -06:00
2026-03-07 16:17:36 +01:00
2026-07-21 15:15:53 -06:00
2015-05-19 14:30:09 -07:00
2026-07-21 15:15:53 -06:00
2013-02-08 11:26:56 +00:00
2026-10-20 17:35:13 -06:00
2026-04-03 19:00:09 +02:00
2026-08-29 12:25:14 -06:00
2013-01-23 15:48:55 +07:00
2026-07-21 15:15:53 -06:00
2026-08-12 13:25:52 -06:00
2026-10-15 09:26:12 -06:00
2026-08-21 15:55:25 -06:00
2013-01-18 14:24:37 +01:00
2026-08-31 17:04:24 -06:00
2026-08-12 13:25:52 -06:00
2020-01-31 13:43:58 +01:00
2025-12-26 10:42:41 +01:00
2020-01-31 13:43:58 +01:00
2014-11-06 10:17:05 -08:00
2026-10-06 17:41:26 -06:00
2013-01-24 19:18:39 +08:00
2026-08-12 13:25:52 -06:00
2026-10-06 17:50:55 -06:00
2026-09-01 08:34:36 -06:00
2016-02-06 20:39:49 +01:00
2016-02-06 20:39:49 +01:00
2019-03-31 17:37:44 +02:00
2026-08-29 12:25:14 -06:00
2026-10-06 18:50:09 -06:00
2026-10-13 10:01:47 -06:00
2025-04-28 15:40:57 +02:00
2020-10-09 11:47:18 +02:00
2025-06-22 11:04:46 +02:00
2013-01-20 07:24:00 +07:00
2026-10-06 17:41:26 -06:00
2026-07-21 15:15:53 -06:00
2026-10-23 21:49:41 -06:00
2026-07-21 15:15:53 -06:00
2020-10-23 08:42:00 +02:00
2018-04-04 14:40:46 -07:00
2026-07-21 15:15:53 -06:00
2026-10-23 20:20:51 -06:00
2018-03-04 18:40:33 +01:00
2026-08-21 15:52:17 -06:00
2026-08-05 13:47:28 -06:00
2026-10-23 21:10:17 -06:00
2026-07-21 15:15:53 -06:00
2011-03-25 22:52:57 -04:00
2024-07-19 06:36:58 +02:00
2015-01-13 14:11:16 -08:00
2014-11-06 10:17:05 -08:00
2026-08-21 15:55:25 -06:00
2013-08-12 16:39:54 +02:00
2026-07-21 15:15:53 -06:00
2026-10-20 17:35:13 -06:00
2025-09-24 14:20:37 +02:00
2026-08-14 20:09:17 -06:00
2026-07-21 15:15:53 -06:00
2026-08-31 17:04:24 -06:00
2020-01-31 13:43:58 +01:00
2019-04-08 14:39:02 +02:00
2026-10-06 17:42:56 -06:00
2026-10-06 17:55:58 -06:00
2016-10-20 17:24:18 +02:00
2019-12-19 09:08:33 +01:00
2026-10-01 16:03:10 -06:00
2026-07-21 15:15:53 -06:00
2020-04-06 13:10:34 +02:00
2026-10-01 16:03:10 -06:00
2026-03-07 17:11:25 +01:00
2012-12-20 14:22:09 +01:00
2026-07-21 15:15:53 -06:00
2026-08-25 21:09:51 +02:00
2026-08-28 13:35:27 -06:00
2020-01-31 13:43:58 +01:00
2026-10-09 16:47:46 -06:00
2013-08-12 16:46:14 +02:00
2025-07-05 16:28:16 +02:00
2026-09-01 08:34:36 -06:00
2026-09-01 08:34:36 -06:00
2020-01-31 13:43:58 +01:00
2012-02-24 19:44:13 +00:00
2022-03-17 21:07:16 +01:00
2026-08-12 13:25:52 -06:00