Commit b0fa314dfc8d7a84a5bd664366a787a6a73164b8
1 parent
3923aabb
Exists in
master
and in
3 other branches
Fixing oversize.
Showing
2 changed files
with
6 additions
and
2 deletions
Show diff stats
src/core/sf.c
@@ -793,6 +793,7 @@ static void do_qr_usable_area(H3270 *hSession) | @@ -793,6 +793,7 @@ static void do_qr_usable_area(H3270 *hSession) | ||
793 | SET16(hSession->output.ptr, hSession->max.cols); /* usable width */ | 793 | SET16(hSession->output.ptr, hSession->max.cols); /* usable width */ |
794 | SET16(hSession->output.ptr, hSession->max.rows); /* usable height */ | 794 | SET16(hSession->output.ptr, hSession->max.rows); /* usable height */ |
795 | *hSession->output.ptr++ = 0x01; /* units (mm) */ | 795 | *hSession->output.ptr++ = 0x01; /* units (mm) */ |
796 | + | ||
796 | num = display_widthMM(); | 797 | num = display_widthMM(); |
797 | denom = display_width(); | 798 | denom = display_width(); |
798 | while (!(num %2) && !(denom % 2)) | 799 | while (!(num %2) && !(denom % 2)) |
@@ -802,6 +803,7 @@ static void do_qr_usable_area(H3270 *hSession) | @@ -802,6 +803,7 @@ static void do_qr_usable_area(H3270 *hSession) | ||
802 | } | 803 | } |
803 | SET16(hSession->output.ptr, (int)num); /* Xr numerator */ | 804 | SET16(hSession->output.ptr, (int)num); /* Xr numerator */ |
804 | SET16(hSession->output.ptr, (int)denom); /* Xr denominator */ | 805 | SET16(hSession->output.ptr, (int)denom); /* Xr denominator */ |
806 | + | ||
805 | num = display_heightMM(); | 807 | num = display_heightMM(); |
806 | denom = display_height(); | 808 | denom = display_height(); |
807 | while (!(num %2) && !(denom % 2)) | 809 | while (!(num %2) && !(denom % 2)) |
@@ -809,11 +811,14 @@ static void do_qr_usable_area(H3270 *hSession) | @@ -809,11 +811,14 @@ static void do_qr_usable_area(H3270 *hSession) | ||
809 | num /= 2; | 811 | num /= 2; |
810 | denom /= 2; | 812 | denom /= 2; |
811 | } | 813 | } |
814 | + | ||
812 | SET16(hSession->output.ptr, (int)num); /* Yr numerator */ | 815 | SET16(hSession->output.ptr, (int)num); /* Yr numerator */ |
813 | SET16(hSession->output.ptr, (int)denom); /* Yr denominator */ | 816 | SET16(hSession->output.ptr, (int)denom); /* Yr denominator */ |
817 | + | ||
814 | *hSession->output.ptr++ = *char_width; /* AW */ | 818 | *hSession->output.ptr++ = *char_width; /* AW */ |
815 | *hSession->output.ptr++ = *char_height; /* AH */ | 819 | *hSession->output.ptr++ = *char_height; /* AH */ |
816 | - SET16(hSession->output.ptr, hSession->max.cols * hSession->max.cols); /* buffer, questionable */ | 820 | + |
821 | + SET16(hSession->output.ptr, hSession->max.cols * hSession->max.rows); /* buffer, questionable */ | ||
817 | 822 | ||
818 | } | 823 | } |
819 | 824 |
src/include/screenc.h
@@ -41,7 +41,6 @@ | @@ -41,7 +41,6 @@ | ||
41 | #define display_width() 1 | 41 | #define display_width() 1 |
42 | 42 | ||
43 | LIB3270_INTERNAL int screen_init(H3270 *session); | 43 | LIB3270_INTERNAL int screen_init(H3270 *session); |
44 | -// LIB3270_INTERNAL Boolean screen_new_display_charsets(char *cslist, char *csname); | ||
45 | LIB3270_INTERNAL void mcursor_set(H3270 *session,LIB3270_POINTER m); | 44 | LIB3270_INTERNAL void mcursor_set(H3270 *session,LIB3270_POINTER m); |
46 | 45 | ||
47 | #define mcursor_locked(x) mcursor_set(x,LIB3270_POINTER_LOCKED) | 46 | #define mcursor_locked(x) mcursor_set(x,LIB3270_POINTER_LOCKED) |