how to add a new line button to numeric keyboard. TextFormField with phones list - flutter

I need to make a long TextFormField to insert a lot of phones(for example maxLines:10). Each line is a single phone. Have no idea how to make my keyboard with numbers and break (next line) button only.
TextInputType.number and TextInputType.phone cannot make a new line.
What to do?

why don't you display the lines as a list view/column and add a row each time you will enter the next number - so instead of one field with wrapped lines use multiple input fields

Related

How can I add line numbers to TextField on Flutter?

I am trying to add line numbers to text field on Flutter, like on any text editors. I have text that overflows to next line, so I want to show where lines start and end.
First way that came to my mind was to separate the screen into two columns, one for line numbers on left and one for right for the textfield. However, due to screen size differences, I can't know when a line will overflow.
Is there any more formal way to do it?
First, initialize a List of TextField and an currentLine integer variables. TextField must contain properties named textInputAction and onEditingComplete. So each time you press enter, it is considered as finished with current TextField, creating a new TextField and add it into List of TextField and will move the focus to the new TextField. Line numbers will be coming from inputDecoration of each TextField and the value will be from currentLine variable. curentLine++ also ran inside onEditingComplete.
Check out this article about LineMetrics.
As you can see, this gives you a list of metadata concerning your rendered text lines. Using the line numbers and the hardBreak attribute together, you can compute the line numbers to display in the left hand column.
you can use TextSelection()
TextSelection selection = TextSelection(baseOffset: 0, extentOffset: text.length);
List<TextBox> boxes = textPainter.getBoxesForSelection(selection);
int numberOfLines = boxes.length;
get numberOfLines in your Text, count, and show for each line.

How to remove blank row in Jasper reports

This question is in continuation : How to hide textField in report generated in specified format?
depending on some conditions when all rows are blank how to remove those ?
in my case one column hiding because (print non repeated rows), and two columns are hidden becase of given condition (pdf.exclude) so now row is blank.
I want to remove this blank row. Can you suggest ?
I hope you must be using Textfield, and navigate to properties then select Textfiled tab and check blnk when null checkbox, If you want to remove the line itself from common tab tick remove line when blank.
that's about it

How to add multiple lines in tab strip of sap UI5?

I am trying to add new or second line in tab-strip.
Once the space is exhausted in first line ,I want another line to display tabs.
Can I get a sample code?
Note : Tabs are generated dynamically on click of button.
The sap.m.IconTabBar only supports a single row of IconTabBarFilters and uses horizontal scroll when there is not room to display them all in one line.
In order to achieve your goal you need to define several IconTabBars and determine the number of IconTabBarFilters you want in each row. Once a IconTabBar is "full", add the next IconTabFilter to the next row's IconTabBar (and make it visible).

To get the content of first two lines from UITextView without using next line object

I need to get the two lines of content from uitextview, but without using nextline.. I entered the text continuously on uitextview without press enter the line goes to second line automatically. when I print those text it is showing single line. But the content is two or more than two lines. How I can get that content from UITextView.
You need to count (roughly) number of characters that can be entered in a single line.
Then using modulo and division you can find number of lines the text consumed.

UITextFields firstResponder problem

hello all i am working with multiple uitextfields.i have a problem in cursor placing while changing firstResponder. i would like to do "Cursor placement in 2nd field once we entered the 3rd character in the 1st field." but the cursor stays in 3rd place.here i am restricting my first text field length to 3.
This SO answer should help you. You set up notifications to be issued when the first text field state changes, firing a method that checks the text field's length. If firstTextField.text.length is equal to three characters, call [secondTextField becomeFirstResponder].