Dave Jarvis' Repositories

git clone https://repo.autonoma.ca/repo/keenquotes.git
M README.md
51 51
See the source code for details.
52 52
53
# Apostrophes
54
55
In UNICODE, apostrophes have no semantic meaning. This unfortunate decision
56
means that you have a choice in how straight apostrophes are converted to
57
your typographic requirements. Using the `-a` option, you may provide one
58
of the following values:
59
60
* `regular` -- Keep the straight apostrophe (and curl using the font).
61
* `modifier` -- Use UNICODE character 0x02BC.
62
* `apos` -- Use `'`, which is not HTML4-compliant.
63
* `aposhex` -- Use `'`, which works with HTML4.
64
* `quote` -- Use `’`, which is semantically incorrect and will likely produce the desired typography.
65
* `quotehex` -- Use `’`, which will likely produce the desired typography without embedding the semantically misleading "name" of "right single quote".
66
53 67
# Build
54 68
M src/main/java/com/whitemagicsoftware/keenquotes/app/Settings.java
86 86
  @CommandLine.Option(
87 87
    names = {"-a", "--apostrophe"},
88
    description = "Converted apostrophe entity (regular, modifier, hex, entity)"
88
    description = "Converted apostrophe entity (see docs)"
89 89
  )
90 90
  private String mApostrophe;
M src/main/java/com/whitemagicsoftware/keenquotes/parser/Apostrophe.java
19 19
  CONVERT_MODIFIER( "ʼ", "modifier" ),
20 20
  /**
21
   * Apostrophes become XML APOSTROPHE ({@code '}).
22
   */
23
  CONVERT_APOS( "'", "apos" ),
24
  /**
21 25
   * Apostrophes become APOSTROPHE ({@code '}).
22 26
   */
23
  CONVERT_APOS_HEX( "'", "hex" ),
27
  CONVERT_APOS_HEX( "'", "aposhex" ),
24 28
  /**
25
   * Apostrophes become XML APOSTROPHE ({@code '}).
29
   * Apostrophes become RIGHT SINGLE QUOTATION MARK ({@code ’}).
26 30
   */
27
  CONVERT_APOS_ENTITY( "'", "entity" );
31
  CONVERT_RSQUOTE( "’", "quote" ),
32
  /**
33
   * Apostrophes become RIGHT SINGLE QUOTATION MARK in hex ({@code ’}).
34
   */
35
  CONVERT_RSQUOTE_HEX( "’", "quotehex" );
28 36
29 37
  private final String mCode;