Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
いくつかのラジオボタンを備えたグループボックスがあります。どれがチェックされているかを知るにはどうすればよいですか。
インデックスとループの組み合わせを使用して、この問題を回避することができました。
indexOfChecked = [self.ButtonGroup.buttons()[x].isChecked() for x in range(len(self.ButtonGroup.buttons()))].index(True)