Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to check components in a TableView javafx #36

Open
matanbanin opened this issue Oct 14, 2015 · 2 comments
Open

How to check components in a TableView javafx #36

matanbanin opened this issue Oct 14, 2015 · 2 comments
Labels

Comments

@matanbanin
Copy link

Hi, i try to test a TableView, but i can only get the raw values from the table.
How can i get the gui components using automathon like the tableCell2Component in the Swing section.

Thank you very much!
Please continue on the great work!

@renatoathaydes
Copy link
Owner

Hi!

IF you can't do it right now, it's probably because TableView has some different way of keeping cells that I didn't account for, I will investigate this... if you know how to get what you want from the Node itself, let me know.

Regards.

@renatoathaydes
Copy link
Owner

I've had a look and it seems Automaton does already support selecting table headers and cells from a TableView.

I've added a test to prove that this works:

52c09f7

Isn't the Node you get by calling fxer.getAt( selector ) what you would expect?

Default cells usually have the type LabeledText, so I find it useful to filter with a complex selector:

Java:

LabeledText labelCell = fxer.getAt( matchingAll( "text:Jacob", "type:LabeledText" ) );

Groovy:

def labelCell = fxer[ matchingAll( 'text:Jacob', 'type:LabeledText' ) ]

See the docs for more details:

https://github.com/renatoathaydes/Automaton/blob/master/docs/getting-started-javafx.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants