MCPcopy Create free account
hub / github.com/NetHack/NetHack / frame_tty_window

Function frame_tty_window

outdated/sys/mac/mactty.c:1176–1196  ·  view source on GitHub ↗

* Frame an area in an aesthetically pleasing way. */

Source from the content-addressed store, hash-verified

1174 * Frame an area in an aesthetically pleasing way.
1175 */
1176short
1177frame_tty_window(WindowPtr window, short from_x, short from_y, short to_x,
1178 short to_y, short frame_fatness)
1179{
1180 Rect r;
1181 RECORD_EXISTS(record);
1182
1183 if (from_x > to_x || from_y > to_y) {
1184 return general_failure;
1185 }
1186 pos_rect(record, &r, from_x, from_y, to_x, to_y);
1187 select_offscreen_port(record);
1188 PenSize(frame_fatness, frame_fatness);
1189 FrameRect(&r);
1190 PenNormal();
1191 accumulate_rect(record, &r);
1192 if (DRAW_DIRECT) {
1193 update_tty(window);
1194 } else
1195 select_onscreen_window(record);
1196}
1197
1198/*
1199 * Highlighting a specific part of the tty window

Callers

nothing calls this directly

Calls 5

pos_rectFunction · 0.85
select_offscreen_portFunction · 0.85
accumulate_rectFunction · 0.85
update_ttyFunction · 0.85
select_onscreen_windowFunction · 0.85

Tested by

no test coverage detected