bghull / quizmaker

A workflow automation tool for the creation of pub trivia slide decks.
https://vml.pythonanywhere.com
GNU General Public License v3.0
0 stars 0 forks source link

Text is not formatted correctly when opening output file on iPhone #1

Open bghull opened 3 years ago

bghull commented 3 years ago

User sent a screenshot from her phone showing overlapping text in the answer slides. After examination, the problem appears to be two-fold:

  1. The default text of the template slides was Calibri, which is not available on Apple devices. The iPhone system default font is used instead which, being a serif font, messes everything up.
  2. The question placeholders on the answer slides have a vertical alignment of "middle" by default, but only on Windows/Android; iPhone .pptx handler seems to default to "top", causing some questions to overlap the answers.
  3. Minor quibble: the numbers and bullets of the Rules slide are not formatted correctly either.

Part of this was addressed by changing the font in the template slide master to Arial, and bottom-aligning the text boxes. Some text manipulation is still needed to ensure overflow does not overlap the text above or below the question (i.e. make the text larger or smaller to bring the line count to 2 even though it makes the text very small), but at least now the visual output is consistent between devices.

Long-term fixes would include:

bghull commented 3 years ago

8a89da13adc607435ddb284064a045d39a03a1d6 03e2cf0f80bbedf0e8d17475fd0a30c517848746 9061c09cc1c1c78cdc84e3713892a64ae6dbf603

bghull commented 3 years ago

The Answer slides are now (again) one large text box. This makes the edit pass easier: simply select all of the text in the box and click the "font size up/down" buttons to make it fit the box. Note that the answers are slightly larger than the questions by design but that can be removed if necessary for fitting.

The script handles making each answer line bold and in the teal accent color of the theme.

After more testing, there still seems to be a small issue with line breaks: newline character \n does not actually make a blank line between answers on iPhone, while \r\n causes the text to overfill (still without blank lines between). So the text fits, it's just smaller than it looks on desktop.