Ah, thanks, it was a mixture of both
outline: none
which took away the orange, and also
border: none
which took away the grey border it left behind after that.
So now I have the code that creates me a
> |
[ie a flashing cursor at a bold prompt to type against]
using the code from guzmere with a couple of alterations:
This is the "CSS" object added into the code:
<object name="CSS">
<inherit name="editor_object" />
<custom><![CDATA[
<script>document.getElementById('txtCommandDiv').innerHTML = ' <b>> </b><input type="text" x-webkit-speech="" id="txtCommand" onkeydown="return commandKey(event);" style="width: 50%; height: 14pt; font-size: 12pt; font-weight: bold; outline: none; border: none;" autofocus><a id="endWaitLink" onclick="endWait();" class="cmdlink" style="display: none"> press a key</a>';</script>
<style type = "text/css">
a.cmdlink {
color: black;
}
</style>
]]></custom>
</object>
And this is the startscript added to Game:
<start type="script"><![CDATA[
msg ("{CSS.custom}")
]]>
</start>
Those two together work perfectly for me (pefectly except it still flashes up a "type here" box right at the very start while it's loading the start script, but I can live with that!).
And as Pernix says, if you load it up from a saved game, it goes back to the original orange box from before, which is a shame, although that can be mainly fixed by putting the "msg ("{CSS.custom}")" bit into the turn script as well as the start script.
Last possible problem is that if you lose focus on the place where you're typing, you have to know to click back on the ">" to get the cursor back, and not just click back anywhere on the page which is what you'd more naturally do, which is less obvious to do if you can't see a box to click in. That's a problem a bit, because with my game, it has a "wait" right at the start, and pressing a key for "wait" loses focus on the text box for some reason, so it appears at the start of the game that you can't type anything, which is not very helpful.
So I changed it now to:
<object name="CSS">
<inherit name="editor_object" />
<custom><![CDATA[
<script>document.getElementById('txtCommandDiv').innerHTML = ' <b>> </b><input type="text" x-webkit-speech="" id="txtCommand" onkeydown="return commandKey(event);" style="width: 50%; height: 14pt; font-size: 12pt; font-weight: bold; outline: none; border-color: #eeeeee; border-width: 1; border-style: solid;" autofocus><a id="endWaitLink" onclick="endWait();" class="cmdlink" style="display: none"> press a key</a>';</script>
<style type = "text/css">
a.cmdlink {
color: black;
}
</style>
]]></custom>
</object>
to put a very light grey border there for that. Which is a bit less pretty but probably more useable.
psy