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

SpreadsheetView column fit incorrect with span column cells #1519

Open
TabFil opened this issue Sep 28, 2023 · 0 comments
Open

SpreadsheetView column fit incorrect with span column cells #1519

TabFil opened this issue Sep 28, 2023 · 0 comments

Comments

@TabFil
Copy link

TabFil commented Sep 28, 2023

Hello,

switching from ver 8 to ver 11 I found that if I put long text in a cell spanning over multiple columns, all the columns involved in the span get the width of the spanned cell.
Expected (ver 8):
image
Result (ver 11):
image

Here's the code used to generate the example (the code is the same the behaviour si different in ver 8 vs 11:

 GridBase grid = new GridBase(2, 3);
        ObservableList<ObservableList<SpreadsheetCell>> rows = FXCollections.observableArrayList();
        for (int row = 0; row < grid.getRowCount(); ++row) {
            final ObservableList<SpreadsheetCell> list = FXCollections.observableArrayList();
            for (int column = 0; column < grid.getColumnCount(); ++column)
                list.add(SpreadsheetCellType.STRING.createCell(row, column, 1, 1, "value"));
            rows.add(list);
        }
        grid.setRows(rows);
        grid.spanColumn(2, 0, 0);
        grid.setCellValue(0, 0, "value___________");
        SpreadsheetView spv = new SpreadsheetView(grid);

Thanks in advance for any help.
Best regards,
Filippo

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

No branches or pull requests

1 participant