angband/angband — pull request #258 by bensemmler (2013-08-07 12:59:43+00:00)
Title: Monster Recall Cleanup

Changes
- Fixes 1710 (missing characters in recall descriptions on OS X)
- Fixes some pronoun capitalization ("which It may notice from 200 feet")
- Uses textblocks to build description and present on screen, instead of text_out or writing directly to the terminal (like object recall)
- Refactored a bunch of stuff; uses monster spell refactor and other tables where possible
- Textblocks can be appended with graphics tiles (textblock_append_pict())
- Textblocks can be placed or shown without a header by passing NULL as the header

Notes
- The new code can be toggled with the LORE_USE_TEXTBLOCK define in mon-lore.h. I didn't want to get rid of anything until it was better tested.
- I have only tested this on OS X.
- The diffs between spoilers (old and new) were matching. However, I haven't given the recall much play testing yet; I'll be doing that soon.
- The graphics tile in the recall title ("optional char/attr") should display properly, but this is another thing that I haven't thoroughly tested.
- Some bolt spells may show +- one point compared to the previous version. I'm assuming this is a rounding error between the old macros and the proper damage calculation functions.
- When 'l'ooking and then recalling, exiting the recall mode doesn't exit look mode. I liked this, so I didn't try to change it back (the old system would exit look mode when you exited the recall).
- I'm not able to test the presentation of recall via context menu. The OS X version apparently doesn't report right clicking. I'll fix this soon.

Known Issues
- mon-info.spo: writing textblocks to file doesn't appear to be writing Unicode chars correctly; working on a fix.
- mon-info.spo: everything is indented by one space (textblock_to_file doesn't like an indent of 0); working on a fix.
- Textblock wrapping: textblocks don't strip whitespace at the beginning of a line.