Return (filled frame, options) for testing. Options is a list of searchengine booleanvar, label pairs. A gridded frame from make_frame is filled with a Checkbutton for each pair, bound to the var, with the corresponding label.
(self)
| 134 | return frame, label |
| 135 | |
| 136 | def create_option_buttons(self): |
| 137 | '''Return (filled frame, options) for testing. |
| 138 | |
| 139 | Options is a list of searchengine booleanvar, label pairs. |
| 140 | A gridded frame from make_frame is filled with a Checkbutton |
| 141 | for each pair, bound to the var, with the corresponding label. |
| 142 | ''' |
| 143 | frame = self.make_frame("Options")[0] |
| 144 | engine = self.engine |
| 145 | options = [(engine.revar, "Regular expression"), |
| 146 | (engine.casevar, "Match case"), |
| 147 | (engine.wordvar, "Whole word")] |
| 148 | if self.needwrapbutton: |
| 149 | options.append((engine.wrapvar, "Wrap around")) |
| 150 | for var, label in options: |
| 151 | btn = Checkbutton(frame, variable=var, text=label) |
| 152 | btn.pack(side="left", fill="both") |
| 153 | return frame, options |
| 154 | |
| 155 | def create_other_buttons(self): |
| 156 | '''Return (frame, others) for testing. |
no test coverage detected