BricsCAD TEXTQLTY Variable
BricsCAD V12 introduced improvements in TrueType text rendering for Linux. At the same time, they introduced a new system variable, TEXTQLTY, which also has an effect on TrueType text rendering.
This page explores what the TEXTQLTY variable actually does (but is biased towards trying to get high quality text at small sizes.)
Bricsys Announces TEXTQLTY
Let’s take another look at the Release Notes where Bricsys announced TEXTQLTY:
Excerpt from Bricscad V12 Release Notes, Version 12.1.16, 2012-02-20
- SR29641, SR32973 - TTF QUALITY: Improved text rendering on Linux. Now TEXTQLTY variable is used in the following manner:
- TEXTQLTY < 49: old rendering method is used. The actual value is not used.
- 50 <= TEXTQLTY <= 100: new approximation algorithm for Bezier curves. Greater values imply better quality but more points for the approximating polyline so performance-wise a lower value is recommended.
- TEXTQLTY = 50 is the default value
Okay, 0 to 49 essentially means “old method”, and 50 to 100 is where all the action is.
I have a separate article about choosing the best TEXTQLTY setting.
How To Use TEXTQLTY
You can change this variable by typing “TEXTQLTY” on the command line. You can also change it by navigating to Program Options > Plot > Publish > Text quality in the BricsCAD settings manager.
The variable TEXTQLTY does not take effect until you exit BricsCAD and come back to the drawing. 1 You have to change TEXTQLTY, save the drawing, exit BricsCAD, and reopen the drawing.
Also, you can see the job that TEXTQLTY is currently doing by either zooming in very close to a letter, or by exploding some text to polylines and examining the polylines1.
TEXTQLTY will not have any effect on SHX fonts, since these are already in a vector format and do not need to be converted.
1 See this post in the BricsCAD support forum.
Effect Of TEXTQLTY
Green grips mark the ends of the
line segments. As TEXTQLTY increases,
so does the count of line segments.
Font characters are composed of nice curves and lines. A CAD program like BricsCAD has the ability to turn each character into simple polygons with straight sides. The polygon is composed of small straight lines, but it should closely match the original curves of the font.
As part of converting font characters to vector geometry, BricsCAD traces the outline of each character with a polyline. What TEXTQLTY does is specify how closely the polyline should follow the curves of the character.
|TEXTQLTY||# of line|
in Arial Q
|40||71||The old V11 method|
|50||116||The new default in V12 forward.|
Number of line segments in Arial Q
for different values of TEXTQLTY.
Notice the leap between 95 and 100.
The higher the value of TEXTQLTY, the more tiny line segments will be used to outline each character. Notice in the animation how more and more line segments are used for higher values of TEXTQLTY.
The table shows how many line segments are used. I took the capital letter Q from Arial and exploded it to polylines for different values of TEXTQLTY, then counted the resulting line segments.
Effect Of TEXTQLTY On Small Text In PDFs
I am trying to find ways to improve the look of small text in PDF output from BricsCAD. Initially you might think that higher values of TEXTQLTY will lead to better quality in the PDF, but that turns out to not be the case.
What I did was take the Arial letter Q and place it in a drawing at 3/32" (2.38mm). I then printed the drawing to PDF for a range of different TEXTQLTY. This animation shows the result.
3/32" (2.38mm) Arial Q, printed to PDF, at different levels of TEXTQLTY.
The most notable thing about this comparison is that higher values of TEXTQLTY do not make small text in PDFs look smoother or better. In fact higher values may look worse. (Note that I am talking only about small text. I haven’t looked at how TEXTQLTY affects larger text.)
Compare BricsCAD To Others
In this section, I set up comparisons between BricsCAD’s output and that of other programs. The “ideal Q” shown below was rasterized at a larger size with a vector program.
Click a cell to see a larger and clearer animation.
BricsCAD default vs. the ideal
AutoCAD default vs. the ideal
BricsCAD default vs. AutoCAD default
BricsCAD TEXTQLTY 90 vs. AutoCAD default
Higher levels of TEXTQLTY mean more detailed outline to each character.
- The BricsCAD variable TEXTQLTY lets you dial in how many line segments will be used to trace each character.
- The default value of 50 is a good choice for drawings with large amounts of text, or small text.
- Increasing TEXTQLTY does not improve the outcome of small text output to PDF.
- You might want larger values of TEXTQLTY if you have relatively little text, printed at large size.