MCPcopy Create free account
hub / github.com/Akascape/CTkTable / get_selected_column

Method get_selected_column

CTkTable/ctktable.py:582–590  ·  view source on GitHub ↗

Return the index and data of the selected row

(self)

Source from the content-addressed store, hash-verified

580 return {"row_index": selected_row_index, "values": selected_row_data}
581
582 def get_selected_column(self):
583 """ Return the index and data of the selected row """
584 selected_column_index = None
585 for i in range(self.columns):
586 if self.frame[0, i].cget("fg_color") == self.hover_color:
587 selected_column_index = i
588 break
589 selected_column_data = self.get_column(selected_column_index) if selected_column_index is not None else None
590 return {"column_index": selected_column_index, "values": selected_column_data}
591
592 def configure(self, **kwargs):
593 """ configure table widget attributes"""

Callers

nothing calls this directly

Calls 2

get_columnMethod · 0.95
cgetMethod · 0.80

Tested by

no test coverage detected