7
mirror of https://gitlab.com/kicad/code/kicad.git synced 2025-02-22 20:42:53 +00:00
kicad/pcbnew/board_stackup_manager
John Beard 14cbce5d0f Pcbnew: fix bad layer maths in stackup dialog
F_Cu | B_Cu is not the same as LSET( F_Cu ) | LSET( B_Cu),
so you cannot do some_lset |= F_Cu | B_Cu (or rather you can, but
it is not what you expect).

F_Cu and B_Cu are just ints, so 0 | 2 == 2. This isn't the
same as setting *bit indices* 0 and 2. OR-ing with 2 is setting
bit index 1, which is F_Mask.

You can set them one by one with lset.set( F_Cu ) or OR with
LSET::ExternalCuMask() helper. But actually, we're trying to set all 'n'
copper layers, and LSET has AllCuMask and we can save all the hassle
in this function.

Thanks to @aris-kimi for finding the problematic code lines and
providing the foundation of this fix.

Fixes: https://gitlab.com/kicad/code/kicad/-/issues/19855
2025-02-06 13:00:33 +08:00
..
board_stackup_reporter.cpp Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
board_stackup_reporter.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
board_stackup.cpp API: expand board stackup serialization 2025-01-04 15:15:51 -05:00
board_stackup.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
dialog_dielectric_list_manager_base.cpp Hook up delete key in stackup materials list box 2024-02-03 16:39:56 +00:00
dialog_dielectric_list_manager_base.fbp Hook up delete key in stackup materials list box 2024-02-03 16:39:56 +00:00
dialog_dielectric_list_manager_base.h Hook up delete key in stackup materials list box 2024-02-03 16:39:56 +00:00
dialog_dielectric_list_manager.cpp Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
dialog_dielectric_list_manager.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
dielectric_material.cpp Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
dielectric_material.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
panel_board_finish_base.cpp Line styles for PCBNew shapes. 2021-12-24 12:36:59 +00:00
panel_board_finish_base.fbp Line styles for PCBNew shapes. 2021-12-24 12:36:59 +00:00
panel_board_finish_base.h Remove a couple of unused OnUpdateUI handlers. 2021-04-06 13:47:15 +01:00
panel_board_finish.cpp Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
panel_board_finish.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
panel_board_stackup_base.cpp Don't specify fonts in wxFormBuilder. It only leads to pain. 2023-01-18 12:28:07 +00:00
panel_board_stackup_base.fbp Don't specify fonts in wxFormBuilder. It only leads to pain. 2023-01-18 12:28:07 +00:00
panel_board_stackup_base.h Flat(er) look for paged dialogs. 2023-01-11 01:11:25 +00:00
panel_board_stackup.cpp Pcbnew: fix bad layer maths in stackup dialog 2025-02-06 13:00:33 +08:00
panel_board_stackup.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
stackup_predefined_prms.cpp Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00
stackup_predefined_prms.h Revise Copyright statement to align with TLF 2025-01-01 14:12:04 -08:00