Merge pull request #6665 from bgort/font

Add proportional font adjustment ratio
master
bgort 7 years ago committed by GitHub
commit df42428281

@ -1165,4 +1165,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1165,4 +1165,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1142,4 +1142,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1171,4 +1171,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1161,4 +1161,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1163,4 +1163,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1162,4 +1162,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1160,4 +1160,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1160,4 +1160,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1165,4 +1165,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1160,4 +1160,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1165,4 +1165,14 @@
*/ */
#define NO_WORKSPACE_OFFSETS #define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1158,4 +1158,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -1161,4 +1161,14 @@
*/ */
//#define NO_WORKSPACE_OFFSETS //#define NO_WORKSPACE_OFFSETS
/**
* This affects the way Marlin outputs blacks of spaces via serial connection by multiplying the number
* of spaces to be output by the ratio set below. This allows for better alignment of output for commands
* like G29 O, which renders a mesh/grid.
*
* For clients that use a fixed-width font (like OctoPrint), leave this at 1.0; otherwise, adjust
* accordingly for your client and font.
*/
#define PROPORTIONAL_FONT_RATIO 1.0
#endif // CONFIGURATION_ADV_H #endif // CONFIGURATION_ADV_H

@ -33,4 +33,4 @@ void serial_echopair_P(const char* s_P, float v) { serialprintPGM(s_P);
void serial_echopair_P(const char* s_P, double v) { serialprintPGM(s_P); SERIAL_ECHO(v); } void serial_echopair_P(const char* s_P, double v) { serialprintPGM(s_P); SERIAL_ECHO(v); }
void serial_echopair_P(const char* s_P, unsigned long v) { serialprintPGM(s_P); SERIAL_ECHO(v); } void serial_echopair_P(const char* s_P, unsigned long v) { serialprintPGM(s_P); SERIAL_ECHO(v); }
void serial_spaces(uint8_t count) { while (count--) MYSERIAL.write(' '); } void serial_spaces(uint8_t count) { count *= (PROPORTIONAL_FONT_RATIO); while (count--) MYSERIAL.write(' '); }

@ -136,7 +136,7 @@
void unified_bed_leveling::display_map(const int map_type) { void unified_bed_leveling::display_map(const int map_type) {
const bool map0 = map_type == 0; const bool map0 = map_type == 0;
constexpr uint8_t spaces = 11 * (GRID_MAX_POINTS_X - 2); constexpr uint8_t spaces = 9 * (GRID_MAX_POINTS_X - 2);
if (map0) { if (map0) {
SERIAL_PROTOCOLLNPGM("\nBed Topography Report:\n"); SERIAL_PROTOCOLLNPGM("\nBed Topography Report:\n");
@ -145,7 +145,7 @@
serial_echo_xy(GRID_MAX_POINTS_X - 1, GRID_MAX_POINTS_Y - 1); serial_echo_xy(GRID_MAX_POINTS_X - 1, GRID_MAX_POINTS_Y - 1);
SERIAL_EOL; SERIAL_EOL;
serial_echo_xy(UBL_MESH_MIN_X, UBL_MESH_MAX_Y); serial_echo_xy(UBL_MESH_MIN_X, UBL_MESH_MAX_Y);
SERIAL_ECHO_SP(spaces - 3); SERIAL_ECHO_SP(spaces);
serial_echo_xy(UBL_MESH_MAX_X, UBL_MESH_MAX_Y); serial_echo_xy(UBL_MESH_MAX_X, UBL_MESH_MAX_Y);
SERIAL_EOL; SERIAL_EOL;
} }
@ -190,7 +190,7 @@
if (map0) { if (map0) {
serial_echo_xy(UBL_MESH_MIN_X, UBL_MESH_MIN_Y); serial_echo_xy(UBL_MESH_MIN_X, UBL_MESH_MIN_Y);
SERIAL_ECHO_SP(spaces + 1); SERIAL_ECHO_SP(spaces + 4);
serial_echo_xy(UBL_MESH_MAX_X, UBL_MESH_MIN_Y); serial_echo_xy(UBL_MESH_MAX_X, UBL_MESH_MIN_Y);
SERIAL_EOL; SERIAL_EOL;
serial_echo_xy(0, 0); serial_echo_xy(0, 0);

Loading…
Cancel
Save