Trim trailing whitespace

develop
Ryan Williams 2022-05-28 15:56:49 -07:00 committed by GitHub
parent 249ed2888f
commit 1c3ea000e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 7 deletions

@ -1020,7 +1020,7 @@ Fortress mode
where ``df.report_zoom_type.Generic`` skips recentering and enforces valid view bounds (the same as x = -30000,)
``df.report_zoom_type.Item`` brings the position onscreen without centering, and
``df.report_zoom_type.Unit`` centers the screen on the position. Default zoom type is ``df.report_zoom_type.Item``.
* ``dfhack.gui.revealInDwarfmodeMap(pos)``
Centers the view on the given position, which can be a ``df.coord`` instance
@ -1096,11 +1096,11 @@ Announcements
Takes a ``df.report_init`` (see: `structure definition <https://github.com/DFHack/df-structures/blob/master/df.announcements.xml>`_)
and a string and processes them just like DF does. Can also be built from parameters instead of a ``report_init``.
Setting ``is_sparring`` to *true* means the report will be added to sparring logs (if applicable) rather than hunting or combat.
The announcement will not display if units are involved and the player can't see them (or hear, for adventure mode sound announcement types.)
Text is parsed using ``&`` as an escape character, with ``&r`` adding a blank line (equivalent to ``\n \n``,)
``&&`` being just ``&``, and any other combination causing neither character to display.
If you want a guaranteed announcement without parsing, use ``dfhack.gui.showAutoAnnouncement`` instead.
Other

@ -126,12 +126,12 @@ namespace DFHack
// Show an announcement with effects determined by announcements.txt
DFHACK_EXPORT void showAutoAnnouncement(df::announcement_type type, df::coord pos, std::string message, int color = 7, bool bright = true, df::unit *unit1 = NULL, df::unit *unit2 = NULL);
// Process an announcement exactly like DF would, which might result in no announcement
DFHACK_EXPORT bool autoDFAnnouncement(df::report_init r, std::string message);
DFHACK_EXPORT bool autoDFAnnouncement(df::announcement_type type, df::coord pos, std::string message, int color = 7, bool bright = true,
df::unit *unit1 = NULL, df::unit *unit2 = NULL, bool is_sparring = false);
/*
* Cursor and window coords
*/

@ -1962,7 +1962,7 @@ void Gui::recenterViewscreen(int32_t x, int32_t y, int32_t z, df::report_zoom_ty
*df::global::window_x = clip_range(new_win_x, 0, (world->map.x_count - w));
*df::global::window_y = clip_range(new_win_y, 0, (world->map.y_count - h));
*df::global::window_z = clip_range(new_win_z, 0, (world->map.z_count - 1));
ui_sidebar_menus->minimap.need_render = true;
ui_sidebar_menus->minimap.need_scan = true;
@ -1975,7 +1975,7 @@ void Gui::pauseRecenter(int32_t x, int32_t y, int32_t z, bool pause)
return;
resetDwarfmodeView(pause);
if (x != -30000)
recenterViewscreen(x, y, z, report_zoom_type::Item);