Copy link to clipboard
Copied
This is a question about textfield mouse scrolling
I have multiple lines of text in a textfield of constant size.
If the number of lines of text exceeds the range of the text field
I can not scroll above the text title, but only I can scroll in the empty space next to the text title
Can you please tell me how to make the text scrollable above the title?
Thank you so much
completed => Music Played List
sm => Music List
n => Muic List Array Number
indexNo => Music Played Title Array Number
playedList => textField (Dynamic)
completedList();
var tHeight: Number;
function completedList(): void {
if (completed.length == 0) return;
var tx: String;
var addTx: String;
tHeight = playedList.textHeight;
var t2: Number = tHeight / 2;
var lines: uint = Math.floor((playedList.height - t2) / tHeight);
for (var i: uint = 0; i < completed.length; i++) {
tx = (i < 9) ? String(" " + (i + 1)) : String(i + 1);
tx = (i == 0) ? String(" " + (i + 1)) : tx;
addTx = tx + " - " + completed[i] + "\n";
playedList.appendText(addTx);
if (playedList.numLines > lines) {
playedList.scrollV++;
}
}
if (playedList.numLines > lines) {
playedList.border = true;
playedList.borderColor = 0x003366;
}
playedList.addEventListener(MouseEvent.CLICK, selectTextFieldLine);
this.addChild(playedList);
}
function selectTextFieldLine(e: MouseEvent): void {
var index: uint = playedList.getLineIndexAtPoint(e.localX, e.localY - (tHeight / 2 / 2));
if (index >= (playedList.numLines - 1)) return;
if ((index != -1) && (indexNo[index] != n)) {
n = indexNo[index];
musicPlay(sm[n]);
}
}
Copy link to clipboard
Copied
by default, you should able to scroll the text when your mouse is anywhere within the confines of the textfield. anything else and you'll need to encode that yourself.
Copy link to clipboard
Copied
When the same file is compiled in Flash cs 5.5,
it is possible to scroll on the text,
but I wonder if it is not possible in the Animate CC
Copy link to clipboard
Copied
scrolling, by using the mouse anywhere within the textfield, works for me with animate v23.0.1
Copy link to clipboard
Copied
Unfortunately, animate v23.0.1 does not support Korean language.
Copy link to clipboard
Copied
when compiled
Copy link to clipboard
Copied
you're embedding a korean font and it's not exporting?
Copy link to clipboard
Copied
problem solved
thank you so much
Copy link to clipboard
Copied
Copy link to clipboard
Copied
There was a problem with setChildIndex
I am using animate v22.0.8 version
But sometimes when compiling the same file, scrolling is enabled or disabled within the textfield.
If it is an animate setting problem, I wonder how to set it up
One more thing I would like to ask
I wonder why there is a big difference in text readability between swf files and exe files.
Copy link to clipboard
Copied
readability should be no different for text that uses an embedded font. if the font's not embedded, differences are expected on different hosts depending on the host fonts.