Commit Graph

556 Commits

Author SHA1 Message Date
Roman Telezhynskyi
bcea1b69fa Breaking change. All intersections are now treaded as a loop.
--HG--
branch : develop
2019-08-07 12:25:22 +03:00
Roman Telezhynskyi
c2d194c23f Clazy warning.
--HG--
branch : develop
2019-08-06 16:39:14 +03:00
Roman Telezhynskyi
5aadcd067b Improve tiled PDF.
Don't add scissors on bottom row. Users use them as quick guide where to cut
before joining. Scissors on the bottom row force a user to lost information
about a sheet.

--HG--
branch : develop
2019-08-05 10:21:04 +03:00
Roman Telezhynskyi
3461281c40 Fix bug with nesting a descending group.
Another bug in the function. Wrong increment.

--HG--
branch : develop
2019-07-28 15:32:19 +03:00
Roman Telezhynskyi
5978df2629 Fix bug with nesting a descending group.
Together with "Nest quantity" and limited space Valentina removes all
duplicates except first for each next paper sheet.

--HG--
branch : develop
2019-07-27 09:02:41 +03:00
Roman Telezhynskyi
26397164e8 Clazy warning. Reverse candidate.
--HG--
branch : develop
2019-07-24 18:10:32 +03:00
Roman Telezhynskyi
1bd74c7b35 Fix bug in option Unite pages. Correcting offset.
--HG--
branch : develop
2019-07-24 18:07:17 +03:00
Roman Telezhynskyi
16a5adbbd4 Fix error: 'swap' is deprecated: Use QList<T>::swapItemsAt().
--HG--
branch : develop
2019-07-24 14:22:57 +03:00
Roman Telezhynskyi
4a4351b73d Fix error: 'width' is deprecated: Use QFontMetrics::horizontalAdvance.
--HG--
branch : develop
2019-07-24 13:42:22 +03:00
Roman Telezhynskyi
5c84c80039 Refactoring. Reduce modules dependency.
--HG--
branch : develop
2019-07-22 17:06:30 +03:00
Roman Telezhynskyi
d21da1944e Fix calculalting biggest piece edge.
--HG--
branch : develop
2019-07-22 16:15:28 +03:00
Roman Telezhynskyi
5e091a2a66 Backed out changeset: ddb5a308daee
--HG--
branch : develop
2019-07-22 16:42:37 +03:00
Roman Telezhynskyi
ed6e0afd17 Cppcheck warnings.
--HG--
branch : develop
2019-07-21 17:22:50 +03:00
Roman Telezhynskyi
44345085c2 New option --manualPriority.
Helps to disable following manual priority without need to change settings for
each piece.

--HG--
branch : develop
2019-07-21 16:26:21 +03:00
Roman Telezhynskyi
95b9c3ed19 New function VFuzzyOnAxis.
--HG--
branch : develop
2019-07-21 15:22:09 +03:00
Roman Telezhynskyi
1ab19c05a3 Refactoring. Move VFuzzyComparePoints to VGeometry static library.
--HG--
branch : develop
2019-07-21 15:04:08 +03:00
Roman Telezhynskyi
d4a308af5b Optimize combining.
--HG--
branch : develop
2019-07-21 14:42:47 +03:00
Roman Telezhynskyi
9f6bb49a22 Fix adding a piece to global contour.
In case of combine we must skip one edge. In case of rotation we must add right
number of edges.

--HG--
branch : develop
2019-07-21 10:40:41 +03:00
Roman Telezhynskyi
a01490b4f4 Fix searching edge index for mirrored piece.
--HG--
branch : develop
2019-07-21 10:35:32 +03:00
Roman Telezhynskyi
93901f6a15 Fix getting edge for mirrored piece.
--HG--
branch : develop
2019-07-21 10:34:32 +03:00
Roman Telezhynskyi
a03b8318d1 Show global contour direction.
--HG--
branch : develop
2019-07-21 10:33:25 +03:00
Roman Telezhynskyi
24ec03c319 Do not show connect for first and last points in global contour.
--HG--
branch : develop
2019-07-21 10:32:42 +03:00
Roman Telezhynskyi
8482f3dd28 Left the most robust way to find intersections.
--HG--
branch : develop
2019-07-21 10:30:26 +03:00
Roman Telezhynskyi
cc2aa8d1ba - Fix edge position for empty sheet. Make it close to paper sheet.
- Fix getting contour edge. It must be based on position from empty sheet edge
for "empty" contour.

--HG--
branch : develop
2019-07-21 10:23:17 +03:00
Roman Telezhynskyi
e18d328178 Do not use piece's path for nesting. Use only layout allowance path.
--HG--
branch : develop
2019-07-21 10:19:00 +03:00
Roman Telezhynskyi
928626d6be Change starting shift value. It must be small enough to cover shape of long
pieces.

--HG--
branch : develop
2019-07-21 10:10:41 +03:00
Roman Telezhynskyi
48bb83a80e Fuzzy comparison is not enough to test points on axis.
--HG--
branch : develop
2019-07-21 10:07:58 +03:00
Roman Telezhynskyi
e37afae597 Allow controlling priority selecting pieces in layout.
--HG--
branch : develop
2019-07-19 10:45:57 +03:00
Roman Telezhynskyi
8888437b07 Fix way we calculate shift for empty sheet. Make it adjustable only if less
than default.

--HG--
branch : develop
2019-07-18 17:40:41 +03:00
Roman Telezhynskyi
a986f765a6 Fix memory leak.
--HG--
branch : develop
2019-07-18 17:34:43 +03:00
Roman Telezhynskyi
0d7c406df4 Fix calculating efficiency.
Piece square must be based on seam allowance or main path instead of layout
allowance.

--HG--
branch : develop
2019-07-18 17:32:19 +03:00
Roman Telezhynskyi
2dff387e5e Try another approach to suppress warning -Warray-bounds.
--HG--
branch : develop
2019-07-05 11:06:03 +03:00
Roman Telezhynskyi
c01dd8c1dc Backed out changeset: bea8c53b301d
--HG--
branch : develop
2019-07-05 10:59:54 +03:00
Roman Telezhynskyi
c74d25cd31 Backed out changeset: d56740267493
--HG--
branch : develop
2019-07-05 10:59:41 +03:00
Roman Telezhynskyi
13650f20a4 Try to suppress error: array subscript is above array bounds
[-Werror=array-bounds].

--HG--
branch : develop
2019-07-04 15:28:44 +03:00
Roman Telezhynskyi
e8804c90bb New layout option --nestQuantity.
--HG--
branch : develop
2019-07-04 14:33:45 +03:00
Roman Telezhynskyi
7e1c096fa1 Try to suppress error: array subscript is above array bounds
[-Werror=array-bounds].

--HG--
branch : develop
2019-07-02 23:32:52 +03:00
Roman Telezhynskyi
f8dddca99f Fix build.
--HG--
branch : develop
2019-07-01 14:02:52 +03:00
Roman Telezhynskyi
762b0fc1d0 Fix build.
--HG--
branch : develop
2019-07-01 13:49:10 +03:00
Roman Telezhynskyi
4ab84bce38 Make full serialization/deserialization for class VLayoutPiece.
--HG--
branch : develop
2019-07-01 12:26:08 +03:00
Roman Telezhynskyi
0658d92688 New marcos Q_DISABLE_ASSIGN.
--HG--
branch : develop
2019-07-01 11:33:29 +03:00
Roman Telezhynskyi
0330869796 Serialization/deserialization for class VLayoutPiece.
--HG--
branch : develop
2019-07-01 11:02:09 +03:00
Roman Telezhynskyi
89f786d98a Refactoring. Moving enum class LayoutExportFormats.
--HG--
branch : develop
2019-07-01 09:57:49 +03:00
Roman Telezhynskyi
a2e71d6e1c Catch exceptions inside of QRunnable. ref #974.
--HG--
branch : develop
2019-06-24 12:14:10 +03:00
Roman Telezhynskyi
a4a6b18561 Cppcheck warning.
--HG--
branch : develop
2019-06-18 16:04:50 +03:00
Roman Telezhynskyi
f7c4bdf2a7 Improve handling layout errors.
Show Timeout error only if none errors appeared before.

--HG--
branch : develop
2019-06-18 15:14:52 +03:00
Roman Telezhynskyi
80d55659ab Refactoring.
--HG--
branch : develop
2019-06-18 15:10:08 +03:00
Roman Telezhynskyi
d16b0d5501 Remove obsolete debugging system.
--HG--
branch : develop
2019-06-18 14:53:00 +03:00
Roman Telezhynskyi
3ca666fba3 Pass original paper orientation. We cannot rely on paper size because it can be
stripped.

--HG--
branch : develop
2019-06-18 14:36:20 +03:00
Roman Telezhynskyi
b80103e088 Improve saving a layout result.
--HG--
branch : develop
2019-06-18 14:28:16 +03:00
Roman Telezhynskyi
d0cd313df0 Fix export passmarks for layout.
Because we did not search in united path we could not draw them and silently
skipped. Now user also will see a warning.

--HG--
branch : develop
2019-06-08 15:32:25 +03:00
Roman Telezhynskyi
a97c90378d Fix bug in VPiece::IsBufferAllowanceValid.
--HG--
branch : develop
2019-06-18 13:48:32 +03:00
Roman Telezhynskyi
12871f0708 Fix issue with artificial loop.
--HG--
branch : develop
2019-06-18 13:45:40 +03:00
Roman Telezhynskyi
d2396820c5 Fix bug with landscape oriention.
--HG--
branch : develop
2019-06-18 12:35:43 +03:00
Roman Telezhynskyi
5c55778d66 Since Q5.12 available support for C++17.
--HG--
branch : develop
2019-05-28 17:41:15 +03:00
Roman Telezhynskyi
d5a1f96bdd constFirst() introduced since Qt 5.6.
--HG--
branch : develop
2019-05-28 16:21:52 +03:00
Roman Telezhynskyi
c2091c6337 Cppcheck warning.
--HG--
branch : develop
2019-05-27 17:21:48 +03:00
Roman Telezhynskyi
6590742f09 Improve "Remove point on line".
Now it should handle circular shapes.

--HG--
branch : develop
2019-05-27 17:07:18 +03:00
Roman Telezhynskyi
d58b3f523d Methods to get a passmark base lines.
--HG--
branch : develop
2019-05-27 17:05:42 +03:00
Roman Telezhynskyi
a87f821327 Introduce mapped versions of methods. In some cases we will do mapping manually.
--HG--
branch : develop
2019-05-27 17:04:26 +03:00
Roman Telezhynskyi
6294dc0748 New struct VLayoutPassmark to store data about a passmark.
--HG--
branch : develop
2019-05-27 14:57:36 +03:00
Roman Telezhynskyi
bd611bf333 Refactor class VPlaceLabelItem.
Store more info about a placelabel.

--HG--
branch : develop
2019-05-27 14:54:44 +03:00
Roman Telezhynskyi
7dc420ad47 Refactor class VLayoutPiecePath.
Optimizing code style.

--HG--
branch : develop
2019-05-27 14:51:58 +03:00
Roman Telezhynskyi
3b51ccb31d Refactoring. Move drawing passmarks to separate class.
--HG--
branch : develop
2019-05-08 15:19:03 +03:00
Roman Telezhynskyi
f420812f5d Fixed build on Windows with Qt 5.6.
--HG--
branch : develop
2019-04-17 17:35:11 +03:00
Roman Telezhynskyi
52dfb912ee Resolved issue #965. Control passmark length with formula.
--HG--
branch : develop
2019-04-17 13:02:22 +03:00
Roman Telezhynskyi
aa1d30bdb8 Alternative approach to search intersection in layout.
--HG--
branch : develop
2019-04-10 15:54:18 +03:00
Roman Telezhynskyi
0987428a93 Increase required Qt version up to 5.4.
--HG--
branch : develop
2019-04-05 15:42:22 +03:00
Roman Telezhynskyi
c26d4d0942 Fixing issue with progress bar in console mode.
--HG--
branch : develop
2019-04-03 13:29:42 +03:00
Roman Telezhynskyi
7b72ea5bc1 Optimize layout algorithm after profiling.
--HG--
branch : feature
2019-04-02 15:30:31 +03:00
Roman Telezhynskyi
4adce13a4d Abort after timeout must have own signal.
--HG--
branch : feature
2019-04-02 15:29:33 +03:00
Roman Telezhynskyi
69df0922af Check timeout inside the layout generator.
--HG--
branch : feature
2019-03-30 11:17:54 +02:00
Roman Telezhynskyi
4565a47b91 Fix bug in VLayoutPieceData class.
--HG--
branch : feature
2019-03-30 11:15:14 +02:00
Roman Telezhynskyi
46bf68521e Nesting with timeout.
--HG--
branch : feature
2019-03-29 19:52:37 +02:00
Roman Telezhynskyi
47bcfd74ab Changes for dialog.
--HG--
branch : feature
2019-03-29 11:31:17 +02:00
Roman Telezhynskyi
91925c2618 Cppcheck warning.
--HG--
branch : develop
2019-03-27 11:45:25 +02:00
Roman Telezhynskyi
c2672b4b69 Shows global contour.
For debugging purposes.
* * *
Show nodes on global contour.

--HG--
branch : develop
2019-03-27 10:29:59 +02:00
Roman Telezhynskyi
635922faec Instead of squares compare depth position.
--HG--
branch : develop
2019-03-27 10:22:00 +02:00
Roman Telezhynskyi
39f24d2dcc When append whole piece don't miss piece edge.
This will potentially create less reserved space.

--HG--
branch : develop
2019-03-15 16:36:37 +02:00
Roman Telezhynskyi
762ee18026 Extend layout sheet paper size to cover coner cases.
--HG--
branch : develop
2019-03-15 15:33:30 +02:00
Roman Telezhynskyi
1393be669b Fix auto cropping.
--HG--
branch : develop
2019-03-12 19:45:27 +02:00
Roman Telezhynskyi
08415eb4ef Refactoring. Move best square result in separate struct.
--HG--
branch : develop
2019-03-27 09:31:02 +02:00
Roman Telezhynskyi
63ea3bf2f9 If user selects SaveLength option add fake contour edge.
* * *
Fixing issue with pieces on edge.

--HG--
branch : develop
2019-03-27 09:03:19 +02:00
Roman Telezhynskyi
ed23a4ee71 Refactoring. Define default values.
--HG--
branch : develop
2019-03-26 19:14:05 +02:00
Roman Telezhynskyi
e7bd65bde9 Refactoring. Move code in functions.
--HG--
branch : develop
2019-03-26 19:10:13 +02:00
Roman Telezhynskyi
1f462586cd Convert to implicitly shared object.
--HG--
branch : develop
2019-03-26 19:02:12 +02:00
Roman Telezhynskyi
81cda14c06 Refactoring. Pass position data as struct.
--HG--
branch : develop
2019-03-26 18:54:59 +02:00
Roman Telezhynskyi
93334c7f7d Show error when preparing pieces fails.
--HG--
branch : develop
2019-03-26 18:21:31 +02:00
Roman Telezhynskyi
6b6d124cbb Refactoring.
--HG--
branch : develop
2019-03-26 17:47:27 +02:00
Roman Telezhynskyi
335d4e2b81 Fix typo.
--HG--
branch : develop
2019-03-26 17:30:25 +02:00
Roman Telezhynskyi
c4d07125dc Refactoring define new type for id value.
--HG--
branch : develop
2019-03-26 17:15:03 +02:00
Roman Telezhynskyi
a479f3cb40 Improve checking allowance validity.
--HG--
branch : develop
2019-02-27 20:33:59 +02:00
Roman Telezhynskyi
77ae13ae18 New pedantic check. Check if allowance path is valid.
This check validate seam allowance path and layout allowance path.

--HG--
branch : develop
2019-02-23 18:43:06 +02:00
Roman Telezhynskyi
81bde9bb95 Fix issue with loop clearing.
--HG--
branch : develop
2019-02-20 09:59:59 +02:00
Roman Telezhynskyi
883d2c04f6 Resolved issue #937. Wrong symmetrical seam corners on pieces.
(grafted from 8c1b09cc7bc40d6d40e39d931d3e040b0323bd87)

--HG--
branch : develop
2019-02-13 16:32:38 +02:00
Roman Telezhynskyi
107af20c80 Clazy warnings.
--HG--
branch : develop
2019-02-13 12:24:26 +02:00
Roman Telezhynskyi
dc4fca7a76 Forgot to comment test data dump functions.
(grafted from 3f7b9889eedf7ae49f804cf6ace7cebec122fbec)

--HG--
branch : develop
2019-02-12 15:37:38 +02:00
Roman Telezhynskyi
63e402ba8a Resolved issue #937. Wrong symmetrical seam corners on pieces.
(grafted from f15fbf536959418dcd9a2f2caf7c0267ae46eaee)

--HG--
branch : develop
2019-02-12 14:51:21 +02:00
Roman Telezhynskyi
84c96c35dd Refactoring layout piece.
--HG--
branch : develop
2019-01-28 20:35:10 +02:00
Roman Telezhynskyi
6efc6f11c8 Fixed issue #924. Valentina produces wrong passmark for rollback case.
(grafted from 5ff3a91f41efebed4963d3377cb2f194983cc7f7)

--HG--
branch : develop
2019-01-09 17:46:02 +02:00