docs(chart): firstSliceAng вне CT_Pie3DChart по стандарту, а не из-за пробела docx4j
PR checks / web (pull_request) Successful in 31s
PR checks / java (pull_request) Successful in 1m19s
Main: tests, deploy, autotests / java (push) Successful in 55s
Main: tests, deploy, autotests / web (push) Successful in 39s
Main: tests, deploy, autotests / images-app (push) Successful in 39s
Main: tests, deploy, autotests / images-web (push) Successful in 1m4s
Main: tests, deploy, autotests / deploy (push) Successful in 1m27s
Main: tests, deploy, autotests / autotests (push) Successful in 44s
Main: tests, deploy, autotests / rollback (push) Has been skipped
PR checks / web (pull_request) Successful in 31s
PR checks / java (pull_request) Successful in 1m19s
Main: tests, deploy, autotests / java (push) Successful in 55s
Main: tests, deploy, autotests / web (push) Successful in 39s
Main: tests, deploy, autotests / images-app (push) Successful in 39s
Main: tests, deploy, autotests / images-web (push) Successful in 1m4s
Main: tests, deploy, autotests / deploy (push) Successful in 1m27s
Main: tests, deploy, autotests / autotests (push) Successful in 44s
Main: tests, deploy, autotests / rollback (push) Has been skipped
Комментарии у поля ChartSpec.firstSliceAng и в PiePainter.paint приписывали невозможность чтения firstSliceAng для PIE3D отсутствию геттера в JAXB-модели docx4j 17.3.2. По ECMA-376 элемент §21.2.2.68 определён только для CT_PieChart/CT_DoughnutChart; CT_Pie3DChart (§21.2.2.140, модель §A.5.1) его не содержит — JAXB-класс верен стандарту. Поворот 3D-пирога — c:view3D/rotY (readView3D/paint3d). Поведение не менялось.
This commit was merged in pull request #41.
This commit is contained in:
@@ -130,8 +130,10 @@ final class ChartSpec {
|
||||
double perspective = 30;
|
||||
boolean rightAngledAxes = true;
|
||||
// Спека-параметры DrawingML, исполнение Word; дефолты — ECMA-376/Word.
|
||||
// firstSliceAng для PIE3D не читается: в JAXB-модели docx4j 17.3.2
|
||||
// у CTPie3DChart геттера CTFirstSliceAng нет.
|
||||
// firstSliceAng (§21.2.2.68) определён только для CT_PieChart/CT_DoughnutChart;
|
||||
// CT_Pie3DChart (§21.2.2.140, модель §A.5.1) его не содержит — JAXB-класс
|
||||
// docx4j верен стандарту. Поворот 3D-пирога — через c:view3D/rotY (readView3D),
|
||||
// поэтому для PIE3D поле остаётся 0.
|
||||
double firstSliceAng = 0;
|
||||
double holeSize = 50;
|
||||
double gapWidth = 150;
|
||||
|
||||
@@ -73,8 +73,10 @@ final class PiePainter {
|
||||
double holeRatio = spec.type == ChartSpec.Type.DOUGHNUT ? spec.holeSize / 100.0 : 0.0;
|
||||
|
||||
List<Slice> slices = new ArrayList<>();
|
||||
// c:firstSliceAng — стартовый угол первого сектора (ECMA-376, default 0;
|
||||
// для PIE3D в JAXB-модели docx4j 17.3.2 геттера нет, остаётся 0)
|
||||
// c:firstSliceAng — стартовый угол первого сектора (§21.2.2.68, default 0);
|
||||
// элемент присутствует только в pieChart/doughnutChart (CT_Pie3DChart по
|
||||
// стандарту его не содержит), поворот 3D-пирога задаёт c:view3D/rotY
|
||||
// (см. paint3d).
|
||||
double angle = spec.firstSliceAng;
|
||||
for (int i = 0; i < s.values.size(); i++) {
|
||||
Double v = s.values.get(i);
|
||||
|
||||
Reference in New Issue
Block a user