def display(self): clearScreen() numArms = self.PageWidth #self.numArms() def printHSep(firstColBlank=True): if firstColBlank: print(' |', end='') else: print('---|', end='') if self.inSingleMode(): for i in range(numArms): if i == self.ixCursor: print('===|', end='') else: print('---|', end='') else: for i in range(numArms): if self.inGroup(i): if self.inGroup(i+1, i): print('====', end='') else: print('===|', end='') else: print('---|', end='') print('') def printAngle(dim, index): try: angle = self.getAngle(dim, index) if angle < 1: print('XXX|', end='') else: print('{0:^3}|'.format(angle), end='') except: print('---|', end='') print(' Light Arm View') printHSep(False) print('x: |', end='') for i in range(numArms): printAngle('x', i) print('') printHSep() print('y: |', end='') for i in range(numArms): printAngle('y', i) print('') printHSep() names = '' for i in range(self.VerticalGroups): if i == self.iyCursor: names += 'BGR' else: names += 'bgr' for channel in range(Arms.MaxChannels): print(names[channel] + ': |', end='') for i in range(numArms): try: print('{0:^3}|'.format(Arms.getChannel(i, channel)), end='') except: print('---|', end='') print('') printHSep(channel+1 != Arms.MaxChannels)
def modI(self, inc, channel): #print('ids:', self.selected()) for id in self.selected(): try: v = Arms.getChannel(id, channel) except IndexError: return Arms.setChannel(id, channel, Arms.fitChannelRange(v + inc))