Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-25983] Windows : Ti.UI.TextArea is not wrapped when there is long text, it just show in single line

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2018-09-27T09:27:58.000+0000
Affected Version/sRelease 7.1.0
Fix Version/sRelease 7.5.0
ComponentsWindows
Labelsn/a
ReporterAminul Islam
AssigneeKota Iguchi
Created2018-04-23T17:54:17.000+0000
Updated2018-10-03T04:16:11.000+0000

Description

Hello ! Ti.UI.createTextArea is not wrapped when there is long text, it just show in single line in windows phone. But it wrapped in android. Teste code :
Ti.UI.setBackgroundColor('white');

var controlsHeight = 38 * Ti.App.MultiplyFactor;

var win = Ti.UI.createWindow({

backgroundColor : 'white',
exitOnClose : true,
fullscreen : false

});



var textArea = Ti.UI.createTextArea({

width : Ti.UI.FILL,
backgroundColor : 'white',
color : 'black',
left : 40,
right : 40,
hintText : 'this is a long hint that is not wrapping in windows version. Not sure what is the problem. All text show in single line instead of multi line. please check'

});

textArea.value = 'this is a long hint that is not wrapping in windows version. Not sure what is the problem. All text show in single line instead of multi line. please check';

win.add(textArea);

win.open();

Test Environment:
Operating System
  Name                        = Microsoft Windows 10 Pro
  Version                     = 10.0.16299
  Architecture                = 32bit
  # CPUs                      = 4
  Memory                      = 17091956736
Node.js
  Node.js Version             = 8.9.1
  npm Version                 = 5.5.1
Titanium CLI
  CLI Version                 = 5.0.14
Titanium SDK
  SDK Version                 = 7.1.0.GA
  SDK Path                    = C:\ProgramData\Titanium\mobilesdk\win32\7.1.0.GA
  Target Platform             = windows
Please take a look on attached screenshot.

Attachments

FileDateSize
image-1.png2018-04-23T17:53:48.000+0000189851
Untitled.png2018-04-23T17:53:52.000+0000786522

Comments

  1. Kota Iguchi 2018-04-24

    I am able to reproduce this even on Windows 10 desktop. This is happening because TextArea is not resized when there's is no height specified. In this case TextArea should assume height=Ti.UI.SIZE specified (according to [UI Composite Layout Behavior Spec](https://docs.appcelerator.com/platform/latest/#!/guide/UI_Composite_Layout_Behavior_Spec-section-src-4196675_UICompositeLayoutBehaviorSpec-Autosizebehaviors)) but on Windows it does not resize its size. Started looking into it.
  2. Kota Iguchi 2018-04-24

    https://github.com/appcelerator/titanium_mobile_windows/pull/1230
  3. Josh Longton 2018-07-20

    *FR Passed*
  4. Kota Iguchi 2018-09-12

    Re-opening, the sample code in the PR is not quite right because it only specifies hintText. We should take care of value property too.
  5. Kota Iguchi 2018-09-12

    https://github.com/appcelerator/titanium_mobile_windows/pull/1284
  6. Keerthi Mahalingam 2018-09-20

    FR passed.Waiting for CR and merge.

JSON Source