I am trying to create a NotePad screen in my application. Once notes are created they are locked and unable to be edited, however new pages can be added to a note.
I thought that using the TextFlow would be a great control for this. What I would like to do is the following:
**Note Taker Name**
**Date of Note**
Line of Note Text
Line of Note Text
Line of Note Text
Line of Note Text
------------------------------------------
**Note Taker Name**
**Date of Note**
Line of Note Text
Line of Note Text
Line of Note Text
Line of Note Text
I have attempted it this way:
String s1 = "line of text";
textFlow.getChildren().add(new Text(s1));
textFlow.getChildren().add(new Text(System.lineSeparator()));
textFlow.getChildren().add(new Separator(Orientation.HORIZONTAL));
textFlow.getChildren().add(new Text(System.lineSeparator()));
textFlow.getChildren().add(new Text(s1));
scrollPane.setFitToWidth(true);
This provides me pretty much what I want, except the separator is just a tiny line. I would like the line to cross the entire TextFlow and I wasn't really sure how to go about that.
Thanks.