mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-10-08 13:04:13 +02:00
Fix DXF export of circles, arcs and the title block at the right (#1339)
Circles and arcs: drawArcEllipse() split each curve into quarters and fitted a circular ARC through a point half way between the curve and its chord, so every circle came out as a flattened diamond. A circle or an arc of one is now one exact CIRCLE or ARC. R10 has no ELLIPSE entity, so a true ellipse is a polyline through the curve, one point every 5 degrees. The export also used a different scale on each axis, which made round things oval; it now uses one, the largest that fits the sheet. Title block at the right: the DXF laid the horizontal template out in the narrow vertical strip, squashing it into the top corner. It is now laid out horizontally and turned a quarter, as draw() turns the painter. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -91,15 +91,18 @@ void TitleBlockTemplateRenderer::render(QPainter *provided_painter,
|
||||
@param titleblock_width
|
||||
@param file_path
|
||||
@param color
|
||||
@param dxf_transform : see TitleBlockTemplate::renderDxf()
|
||||
*/
|
||||
void TitleBlockTemplateRenderer::renderDxf(QRectF &title_block_rect,
|
||||
int titleblock_width,
|
||||
QString &file_path,
|
||||
int color) {
|
||||
int color,
|
||||
const QTransform &dxf_transform) {
|
||||
if (!m_titleblock_template) return;
|
||||
m_titleblock_template -> renderDxf(title_block_rect,
|
||||
m_context,
|
||||
titleblock_width,
|
||||
file_path, color);
|
||||
file_path, color,
|
||||
dxf_transform);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user