commit 97bc3b239943108eb4164c87eedadd27eae8e282
parent ccb3c4916b9532081247fc06e9bde7dd8878b870
Author: Adam M <[email protected]>
Date: Sat, 27 Oct 2018 16:51:14 -0500
update UI of ILoveCookies
Diffstat:
3 files changed, 27 insertions(+), 28 deletions(-)
diff --git a/res/ComputerscareILoveCookiesPanel.svg b/res/ComputerscareILoveCookiesPanel.svg
@@ -34,9 +34,9 @@
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
- inkscape:zoom="16"
- inkscape:cx="23.567673"
- inkscape:cy="361.95901"
+ inkscape:zoom="4.0000001"
+ inkscape:cx="86.288455"
+ inkscape:cy="164.40634"
inkscape:document-units="mm"
inkscape:current-layer="g1669"
showgrid="false"
@@ -148,22 +148,22 @@
inkscape:connector-curvature="0" />
<g
aria-label="rst"
- transform="matrix(1.9119826,-0.34464307,0.50786191,1.8921039,-31.234095,-147.94682)"
+ transform="matrix(1.9119826,-0.34464307,0.50786191,1.8921039,-36.824295,-191.79951)"
style="font-style:normal;font-weight:normal;font-size:1.90312397px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.01258837"
id="text864">
<path
- d="m -41.275716,202.9985 c -0.02809,-0.0143 -0.05823,-0.0258 -0.09042,-0.0344 -0.03141,-0.009 -0.06577,-0.0154 -0.10308,-0.0195 -0.132321,-0.0146 -0.228975,0.007 -0.289963,0.0641 -0.06027,0.0567 -0.08086,0.14576 -0.06177,0.26708 l 0.08886,0.56511 -0.235378,-0.026 -0.168693,-1.07274 0.235378,0.026 0.0415,0.11733 c 0.03893,-0.0598 0.08009,-0.0516 0.154062,-0.0742 0.07386,-0.0233 0.167187,-0.0287 0.27999,-0.0162 0.01617,0.002 0.03416,0.005 0.05395,0.009 0.01967,0.003 0.04168,0.008 0.06602,0.0144 z"
+ d="m -41.222698,203.11196 c -0.0243,-0.0201 -0.05121,-0.0379 -0.08076,-0.0533 -0.0287,-0.0156 -0.06084,-0.0294 -0.09636,-0.0415 -0.125965,-0.0431 -0.225004,-0.043 -0.296963,-5.9e-4 -0.07117,0.0422 -0.110664,0.12465 -0.118454,0.24721 l -0.03634,0.5709 -0.224066,-0.0766 0.06898,-1.08373 0.224066,0.0766 0.01495,0.12355 c 0.05102,-0.0499 0.0894,-0.0329 0.166524,-0.0389 0.07716,-0.007 0.169424,0.008 0.276797,0.0452 0.01535,0.005 0.03225,0.0123 0.0507,0.0205 0.01854,0.007 0.03894,0.0169 0.0613,0.0284 z"
style="stroke-width:0.01482364"
id="path870"
inkscape:connector-curvature="0"
sodipodi:nodetypes="ccccccccccccccc" />
<path
- d="m -40.410807,203.11285 v 0.16169 q -0.07248,-0.0372 -0.15054,-0.0557 -0.07806,-0.0186 -0.161691,-0.0186 -0.127309,0 -0.191428,0.039 -0.06319,0.039 -0.06319,0.11709 0,0.0595 0.04553,0.0939 0.04553,0.0334 0.183064,0.0641 l 0.05854,0.013 q 0.182135,0.039 0.258334,0.11058 0.07713,0.0706 0.07713,0.19793 0,0.14497 -0.115228,0.22953 -0.114299,0.0846 -0.315019,0.0846 -0.08363,0 -0.174701,-0.0167 -0.09014,-0.0158 -0.190498,-0.0483 v -0.17656 q 0.09479,0.0493 0.186781,0.0743 0.092,0.0242 0.182135,0.0242 0.120804,0 0.185852,-0.0409 0.06505,-0.0418 0.06505,-0.11709 0,-0.0697 -0.04739,-0.10686 -0.04646,-0.0372 -0.205366,-0.0716 l -0.05947,-0.0139 q -0.158903,-0.0335 -0.229527,-0.10222 -0.07062,-0.0697 -0.07062,-0.1905 0,-0.14682 0.104077,-0.22674 0.104077,-0.0799 0.295505,-0.0799 0.09478,0 0.178418,0.0139 0.08363,0.0139 0.154257,0.0418 z"
- style="stroke-width:0.01258837"
+ d="m -40.401321,202.83793 0.0011,0.14697 q -0.06978,-0.0343 -0.144779,-0.0517 -0.075,-0.0174 -0.155216,-0.018 -0.122114,-0.001 -0.183335,0.0341 -0.06033,0.035 -0.05979,0.10599 3.7e-4,0.054 0.04433,0.0857 0.04391,0.0307 0.17603,0.0595 l 0.05623,0.0122 q 0.174966,0.0367 0.248551,0.10231 0.07447,0.0647 0.07535,0.18045 9.74e-4,0.13177 -0.10892,0.20783 -0.10904,0.0761 -0.30156,0.0747 -0.0802,-4e-4 -0.167681,-0.0164 -0.08656,-0.0149 -0.183052,-0.0452 l -0.0012,-0.16049 q 0.09126,0.0455 0.179669,0.0689 0.08841,0.0226 0.174861,0.0232 0.115868,8.1e-4 0.177973,-0.0359 0.0621,-0.0375 0.06158,-0.10597 -4.76e-4,-0.0634 -0.0462,-0.0975 -0.04482,-0.0341 -0.197475,-0.0665 l -0.05714,-0.013 q -0.152644,-0.0315 -0.220863,-0.0945 -0.06822,-0.0639 -0.06906,-0.17366 -0.001,-0.13345 0.09824,-0.20537 0.09927,-0.0719 0.282876,-0.0706 0.09091,7.5e-4 0.171226,0.0139 0.08031,0.0132 0.148246,0.0391 z"
+ style="stroke-width:0.01175369"
id="path872"
inkscape:connector-curvature="0" />
<path
- d="m -39.571383,202.62755 -0.03453,0.33682 0.483556,0.002 -0.03123,0.14077 -0.467876,0.008 -0.06611,0.644 c -0.0099,0.0967 -0.0042,0.15873 0.01728,0.18596 0.02211,0.0272 0.0709,0.0403 0.146369,0.0394 l 0.18607,-0.003 -0.01679,0.16312 -0.18607,0.003 c -0.139777,0.002 -0.233377,-0.0247 -0.280802,-0.0801 -0.04736,-0.0558 -0.06343,-0.15786 -0.0482,-0.30618 l 0.06611,-0.64399 -0.132895,0.002 0.01555,-0.15148 0.132895,-0.002 0.03453,-0.33681 z"
+ d="m -39.839506,202.58274 -0.03466,0.33779 0.477995,0.0428 -0.03109,0.13976 -0.462511,-0.0314 -0.06636,0.64583 c -0.0099,0.097 -0.0044,0.1602 0.01679,0.18955 0.02181,0.0294 0.07002,0.0467 0.144625,0.0522 l 0.183936,0.0126 -0.01685,0.16358 -0.183936,-0.0127 c -0.138173,-0.01 -0.230656,-0.0447 -0.277449,-0.10469 -0.04673,-0.0604 -0.06245,-0.16502 -0.04717,-0.31376 l 0.06636,-0.64582 -0.13137,-0.009 0.01561,-0.15191 0.131371,0.009 0.03466,-0.33777 z"
style="stroke-width:0.0138234"
id="path874"
inkscape:connector-curvature="0"
@@ -171,22 +171,22 @@
</g>
<g
aria-label="clk"
- transform="matrix(2.3525877,-0.10292753,0.2449229,1.9213172,44.999093,-144.91179)"
+ transform="matrix(2.3525877,-0.10292753,0.2449229,1.9213172,39.209243,-190.33066)"
style="font-style:normal;font-weight:normal;font-size:1.90312397px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.01258837"
id="text868">
<path
- d="m -47.023791,202.8756 0.02953,0.23933 c -0.06229,-0.0399 -0.123696,-0.0697 -0.184208,-0.0892 -0.05988,-0.0203 -0.119243,-0.0305 -0.178089,-0.0305 -0.13166,0 -0.227374,0.0529 -0.287143,0.15862 -0.05989,0.10481 -0.0781,0.2523 -0.05464,0.44245 0.02345,0.19016 0.07812,0.33811 0.163998,0.44386 0.08575,0.10481 0.194455,0.15721 0.326112,0.15721 0.05884,0 0.115746,-0.01 0.170717,-0.0291 0.05558,-0.0205 0.08125,0.026 0.133717,-0.0139 l 0.05753,0.16011 c -0.05251,0.0335 -0.108257,0.0585 -0.167252,0.0751 -0.05826,0.0167 -0.12159,0.025 -0.189991,0.025 -0.186089,0 -0.343029,-0.0737 -0.470822,-0.22124 -0.127791,-0.14748 -0.207137,-0.34644 -0.238039,-0.59689 -0.03136,-0.25416 -8.57e-4,-0.45405 0.09151,-0.59967 0.0931,-0.14563 0.235998,-0.21844 0.428707,-0.21844 0.06252,0 0.124597,0.008 0.18623,0.025 0.06153,0.0157 0.12224,0.0398 0.182141,0.0723 z"
- style="stroke-width:0.0167841"
+ d="m -47.14865,203.94633 0.07098,0.19958 c -0.0692,-0.0333 -0.135769,-0.0581 -0.199658,-0.0743 -0.0634,-0.0169 -0.124526,-0.0254 -0.183372,-0.0254 -0.13166,0 -0.218211,0.0441 -0.259669,0.13228 -0.04174,0.0874 -0.0344,0.2104 0.022,0.36898 0.05639,0.15858 0.136684,0.28197 0.240879,0.37015 0.103904,0.0874 0.221685,0.1311 0.353342,0.1311 0.05884,0 0.114014,-0.008 0.165676,-0.0243 0.05203,-0.0171 0.08575,0.0217 0.13131,-0.0116 l 0.08526,0.13352 c -0.04671,0.0279 -0.09812,0.0488 -0.154244,0.0626 -0.05537,0.0139 -0.11726,0.0208 -0.185661,0.0208 -0.186089,0 -0.355794,-0.0614 -0.509142,-0.1845 -0.153336,-0.12299 -0.267144,-0.28891 -0.341426,-0.49777 -0.07538,-0.21195 -0.0795,-0.37865 -0.01236,-0.50009 0.06788,-0.12144 0.198163,-0.18217 0.390872,-0.18217 0.06252,0 0.125982,0.007 0.19056,0.0208 0.06425,0.0131 0.129133,0.0332 0.194664,0.0603 z"
+ style="stroke-width:0.01532727"
id="path877"
inkscape:connector-curvature="0"
sodipodi:nodetypes="cccscccsccccscscsccc" />
<path
- d="m -46.874682,202.76379 0.142911,-0.0353 0.477431,1.633 -0.142911,0.0353 z"
+ d="m -46.874682,203.57895 0.142911,-0.0353 0.477431,1.633 -0.142911,0.0353 z"
style="stroke-width:0.01266381"
id="path879"
inkscape:connector-curvature="0" />
<path
- d="m -45.316254,202.73781 h 0.105823 l -0.30408,0.97435 0.684115,-0.51209 0.06147,0.0849 0.0099,0.0299 -0.587562,0.44072 0.393944,0.6319 -0.370906,-0.0255 -0.220701,-0.55448 -0.180998,0.57995 h -0.176676 z"
+ d="m -45.316254,203.55297 h 0.105823 l -0.30408,0.97435 0.684115,-0.51209 0.06147,0.0849 0.0099,0.0299 -0.587562,0.44072 0.393944,0.6319 -0.370906,-0.0255 -0.220701,-0.55448 -0.180998,0.57995 h -0.176676 z"
style="stroke-width:0.01363125"
id="path881"
inkscape:connector-curvature="0"
@@ -206,7 +206,7 @@
style="stroke-width:0.07000434" /></text>
<g
aria-label="out"
- transform="matrix(1.0468606,0.36920082,-0.20179075,0.85789222,80.30979,86.979184)"
+ transform="matrix(0.961494,-0.26224736,0.34559745,0.86694168,-28.446637,78.572455)"
style="font-style:normal;font-weight:normal;font-size:3.52777767px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.07000434"
id="text888">
<path
@@ -248,7 +248,7 @@
</g>
<g
aria-label="I Love Cookies"
- transform="matrix(1.0079983,-0.0441007,0.12576363,0.9865629,0,0)"
+ transform="matrix(0.88134036,-0.06480396,0.2054298,1.6115106,-10.378218,-125.02066)"
style="font-style:normal;font-weight:normal;font-size:4.94244957px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.03269225"
id="text901">
<path
@@ -296,13 +296,13 @@
inkscape:connector-curvature="0"
sodipodi:nodetypes="cccccccccccc" />
<path
- d="m -13.4376,201.37704 h 0.582962 l 0,2.7029 H -13.4376 Z m 0,-1.0522 h 0.582962 l 0.132292,0.59537 -0.715254,-0.0331 z"
+ d="m -13.4376,201.37704 h 0.582962 v 2.7029 H -13.4376 Z m 0,-1.0522 h 0.582962 l 0.132292,0.59537 -0.715254,-0.0331 z"
style="stroke-width:0.03745848"
id="path922"
inkscape:connector-curvature="0"
sodipodi:nodetypes="cccccccccc" />
<path
- d="m -8.6028135,202.61748 0,0.2172 h -2.6803615 c 0.02535,0.30568 0.145741,0.53896 0.361184,0.69985 0.217554,0.15928 0.519596,0.23892 0.906126,0.23892 0.223892,0 0.440391,-0.0209 0.649497,-0.0627 0.2112179,-0.0418 0.4203237,-0.10455 0.6273175,-0.18824 v 0.41991 c -0.2091057,0.0676 -0.4234922,0.11906 -0.6431595,0.15445 -0.2196665,0.0354 -0.4425018,0.0531 -0.668506,0.0531 -0.566065,0 -1.014904,-0.12549 -1.346517,-0.37648 -0.329501,-0.25098 -0.494251,-0.59045 -0.494251,-1.01841 0,-0.44244 0.156302,-0.79318 0.468906,-1.05221 0.314715,-0.26063 0.738207,-0.39095 1.270477,-0.39095 0.4773537,0 0.8543785,0.11745 1.1310746,0.35234 0.2788086,0.23329 0.4182129,0.55104 0.4182129,0.95326 z m -0.8310103,-0.24608 c -0.0042,-0.24294 0.1540791,-0.32105 -0.021256,-0.46585 -0.1731991,-0.14479 -0.403427,-0.21719 -0.6906837,-0.21719 -0.325276,0 -0.586131,0.07 -0.782564,0.20995 -0.194321,0.13997 0.0079,0.2213 -0.02164,0.4755 z"
+ d="m -8.6028135,202.61748 v 0.2172 h -2.6803615 c 0.02535,0.30568 0.145741,0.53896 0.361184,0.69985 0.217554,0.15928 0.519596,0.23892 0.906126,0.23892 0.223892,0 0.440391,-0.0209 0.649497,-0.0627 0.2112179,-0.0418 0.4203237,-0.10455 0.6273175,-0.18824 v 0.41991 c -0.2091057,0.0676 -0.4234922,0.11906 -0.6431595,0.15445 -0.2196665,0.0354 -0.4425018,0.0531 -0.668506,0.0531 -0.566065,0 -1.014904,-0.12549 -1.346517,-0.37648 -0.329501,-0.25098 -0.494251,-0.59045 -0.494251,-1.01841 0,-0.44244 0.156302,-0.79318 0.468906,-1.05221 0.314715,-0.26063 0.738207,-0.39095 1.270477,-0.39095 0.4773537,0 0.8543785,0.11745 1.1310746,0.35234 0.2788086,0.23329 0.4182129,0.55104 0.4182129,0.95326 z m -0.8310103,-0.24608 c -0.0042,-0.24294 0.1540791,-0.32105 -0.021256,-0.46585 -0.1731991,-0.14479 -0.403427,-0.21719 -0.6906832,-0.21719 -0.325276,0 -0.586131,0.07 -0.782564,0.20995 -0.194321,0.13997 0.0079,0.2213 -0.02164,0.4755 z"
style="stroke-width:0.03745848"
id="path924"
inkscape:connector-curvature="0"
@@ -330,7 +330,7 @@
id="text1443"
transform="matrix(0.95613575,-0.12921776,0.08046973,0.8264771,-20.759577,36.918454)">
<path
- d="m -39.130096,191.22162 0,5.17798 h 1.488281 c 0.103353,0 0.177422,0.0207 0.222209,0.062 0.04479,0.0379 0.06718,0.0895 0.06718,0.15503 0,0.062 -0.02239,0.11368 -0.06718,0.15503 -0.04479,0.0413 -0.118856,0.062 -0.222209,0.062 h -3.410645 c -0.103353,0 -0.177422,-0.0207 -0.222208,-0.062 -0.04479,-0.0413 -0.06718,-0.093 -0.06718,-0.15503 0,-0.0655 0.02239,-0.11714 0.06718,-0.15503 0.04479,-0.0413 0.118856,-0.062 0.222208,-0.062 l 1.315915,-0.007 0.172367,-5.17104 h -1.488282 c -0.103353,0 -0.177422,-0.0189 -0.222208,-0.0568 -0.04479,-0.0413 -0.06718,-0.0947 -0.06718,-0.16019 0,-0.0655 0.02239,-0.11714 0.06718,-0.15503 0.04479,-0.0413 0.118856,-0.062 0.222208,-0.062 l 3.410645,0 c 0.103353,0 0.177422,0.0207 0.222209,0.062 0.04479,0.0379 0.06718,0.0895 0.06718,0.15503 0,0.0655 -0.02239,0.11886 -0.06718,0.16019 -0.04479,0.0379 -0.118856,0.0568 -0.222209,0.0568 z"
+ d="m -39.130096,191.22162 v 5.17798 h 1.488281 c 0.103353,0 0.177422,0.0207 0.222209,0.062 0.04479,0.0379 0.06718,0.0895 0.06718,0.15503 0,0.062 -0.02239,0.11368 -0.06718,0.15503 -0.04479,0.0413 -0.118856,0.062 -0.222209,0.062 h -3.410645 c -0.103353,0 -0.177422,-0.0207 -0.222208,-0.062 -0.04479,-0.0413 -0.06718,-0.093 -0.06718,-0.15503 0,-0.0655 0.02239,-0.11714 0.06718,-0.15503 0.04479,-0.0413 0.118856,-0.062 0.222208,-0.062 l 1.315915,-0.007 0.172367,-5.17104 h -1.488282 c -0.103353,0 -0.177422,-0.0189 -0.222208,-0.0568 -0.04479,-0.0413 -0.06718,-0.0947 -0.06718,-0.16019 0,-0.0655 0.02239,-0.11714 0.06718,-0.15503 0.04479,-0.0413 0.118856,-0.062 0.222208,-0.062 h 3.410645 c 0.103353,0 0.177422,0.0207 0.222209,0.062 0.04479,0.0379 0.06718,0.0895 0.06718,0.15503 0,0.0655 -0.02239,0.11886 -0.06718,0.16019 -0.04479,0.0379 -0.118856,0.0568 -0.222209,0.0568 z"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333397px;font-family:'Courier New';-inkscape-font-specification:'Courier New, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.00864983"
id="path1445"
inkscape:connector-curvature="0"
diff --git a/src/ComputerscareILoveCookies.cpp b/src/ComputerscareILoveCookies.cpp
@@ -350,7 +350,7 @@ struct ComputerscareILoveCookiesWidget : ModuleWidget {
double knobPosX;
double knobPosY;
double knobXStart = 2;
- double knobYStart = 8;
+ double knobYStart = 16;
double knobRowWidth = 13;
double knobColumnHeight = 10;
ComputerscareILoveCookiesWidget(ComputerscareILoveCookies *module) : ModuleWidget(module) {
@@ -383,10 +383,10 @@ struct ComputerscareILoveCookiesWidget : ModuleWidget {
}
//global clock input
- addInput(Port::create<InPort>(mm2px(Vec(2 , 57)), Port::INPUT, module, ComputerscareILoveCookies::GLOBAL_CLOCK_INPUT));
+ addInput(Port::create<InPort>(mm2px(Vec(2 , 0)), Port::INPUT, module, ComputerscareILoveCookies::GLOBAL_CLOCK_INPUT));
//global reset input
- addInput(Port::create<InPort>(mm2px(Vec(12 , 57)), Port::INPUT, module, ComputerscareILoveCookies::GLOBAL_RESET_INPUT));
+ addInput(Port::create<InPort>(mm2px(Vec(12 , 0)), Port::INPUT, module, ComputerscareILoveCookies::GLOBAL_RESET_INPUT));
for(int i = 0; i < numFields; i++) {
//first-step output
@@ -412,7 +412,7 @@ struct ComputerscareILoveCookiesWidget : ModuleWidget {
//active step display
NumberDisplayWidget3cookie *display = new NumberDisplayWidget3cookie();
- display->box.pos = mm2px(Vec(24,verticalStart - 9.2 +verticalSpacing*i));
+ display->box.pos = mm2px(Vec(23,verticalStart - 9.2 +verticalSpacing*i));
display->box.size = Vec(50, 20);
display->outlineColor = outlineColorMap[i];
if(&module->numSteps[i]) {
@@ -423,7 +423,6 @@ struct ComputerscareILoveCookiesWidget : ModuleWidget {
}
addChild(display);
}
-
}
MyTextFieldCookie* textField;
};
diff --git a/src/ComputerscarePatchSequencer.cpp b/src/ComputerscarePatchSequencer.cpp
@@ -379,16 +379,16 @@ struct ComputerscarePatchSequencerWidget : ModuleWidget {
addChild(bigOne);
- double xpos = 35 + column_spacing * j + 6.3 + rand()%8-4;
- double ypos = top_row + row_spacing * i + 8.3 + rand()%8-4;
+ double xpos = 35 + column_spacing * j + 6.3 + rand() % 8 - 4;
+ double ypos = top_row + row_spacing * i + 8.3 + rand() % 8 - 4;
// red light indicates the state of the matrix that is the active step
- addChild(ModuleLightWidget::create<ComputerscareSmallLight<ComputerscareRedLight>>(Vec(xpos, ypos), module, ComputerscarePatchSequencer::SWITCH_LIGHTS + i + j * 10+100));
- addChild(ModuleLightWidget::create<ComputerscareSmallLight<ComputerscareRedLight>>(Vec(xpos+rdx, ypos+rdy), module, ComputerscarePatchSequencer::SWITCH_LIGHTS + i + j * 10+100));
+ addChild(ModuleLightWidget::create<ComputerscareSmallLight<ComputerscareRedLight>>(Vec(xpos, ypos), module, ComputerscarePatchSequencer::SWITCH_LIGHTS + i + j * 10 + 100));
+ addChild(ModuleLightWidget::create<ComputerscareSmallLight<ComputerscareRedLight>>(Vec(xpos + rdx, ypos + rdy), module, ComputerscarePatchSequencer::SWITCH_LIGHTS + i + j * 10 + 100));
}
addInput(Port::create<InPort>(Vec(3, i * row_spacing + top_row), Port::INPUT, module, ComputerscarePatchSequencer::INPUT_JACKS + i));
- if(i%2) {
+ if(i % 2) {
addOutput(Port::create<PointingUpPentagonPort>(Vec(33 + i * column_spacing , top_row + 10 * row_spacing), Port::OUTPUT, module, ComputerscarePatchSequencer::OUTPUTS + i));
}
else {