mirror of
https://github.com/RandomityGuy/MBHaxe.git
synced 2026-04-27 05:01:38 +00:00
text selection color fix
This commit is contained in:
parent
64c1cbdfe2
commit
72b490766b
3 changed files with 7 additions and 1 deletions
|
|
@ -56,6 +56,9 @@ class EnterNameDlg extends GuiControl {
|
||||||
this.addChild(dlg);
|
this.addChild(dlg);
|
||||||
|
|
||||||
var enterNameEdit = new GuiTextInput(domcasual32);
|
var enterNameEdit = new GuiTextInput(domcasual32);
|
||||||
|
enterNameEdit.text.textColor = 0;
|
||||||
|
enterNameEdit.text.selectionColor.setColor(0xFFFFFFFF);
|
||||||
|
enterNameEdit.text.selectionTile = h2d.Tile.fromColor(0x808080, 0, hxd.Math.ceil(enterNameEdit.text.font.lineHeight));
|
||||||
enterNameEdit.position = new Vector(28, 130);
|
enterNameEdit.position = new Vector(28, 130);
|
||||||
enterNameEdit.extent = new Vector(363, 38);
|
enterNameEdit.extent = new Vector(363, 38);
|
||||||
enterNameEdit.text.text = Settings.highscoreName;
|
enterNameEdit.text.text = Settings.highscoreName;
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ class GuiTextInput extends GuiControl {
|
||||||
public function new(font:h2d.Font) {
|
public function new(font:h2d.Font) {
|
||||||
super();
|
super();
|
||||||
this.text = new TextInput(font);
|
this.text = new TextInput(font);
|
||||||
this.text.textColor = 0;
|
// this.text.textColor = 0;
|
||||||
this.text.onChange = () -> {
|
this.text.onChange = () -> {
|
||||||
if (onTextChange != null) {
|
if (onTextChange != null) {
|
||||||
onTextChange(this.text.text);
|
onTextChange(this.text.text);
|
||||||
|
|
|
||||||
|
|
@ -129,6 +129,9 @@ class SearchGui extends GuiImage {
|
||||||
this.addChild(searchTitle);
|
this.addChild(searchTitle);
|
||||||
|
|
||||||
var searchEdit = new GuiTextInput(domcasual24);
|
var searchEdit = new GuiTextInput(domcasual24);
|
||||||
|
searchEdit.text.textColor = 0;
|
||||||
|
searchEdit.text.selectionColor.setColor(0xFFFFFFFF);
|
||||||
|
searchEdit.text.selectionTile = h2d.Tile.fromColor(0x808080, 0, hxd.Math.ceil(searchEdit.text.font.lineHeight));
|
||||||
searchEdit.position = new Vector(91, 19);
|
searchEdit.position = new Vector(91, 19);
|
||||||
searchEdit.extent = new Vector(373, 29);
|
searchEdit.extent = new Vector(373, 29);
|
||||||
searchEdit.onTextChange = (txt) -> {
|
searchEdit.onTextChange = (txt) -> {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue