forked from FOSS/BangleApps
dragboard v0.05
parent
1bc9329014
commit
78ec6d34b4
|
@ -2,3 +2,4 @@
|
|||
0.02: Added some missing code.
|
||||
0.03: Made the code shorter and somewhat more readable by writing some functions. Also made it work as a library where it returns the text once finished. The keyboard is now made to exit correctly when the 'back' event is called. The keyboard now uses theme colors correctly, although it still looks best with dark theme. The numbers row is now solidly green - except for highlights.
|
||||
0.04: Now displays the opened text string at launch.
|
||||
0.05: Now scrolls text when string gets longer than screen width.
|
||||
|
|
|
@ -0,0 +1,4 @@
|
|||
0.01: New App!
|
||||
0.02: Added some missing code.
|
||||
0.03: Made the code shorter and somewhat more readable by writing some functions. Also made it work as a library where it returns the text once finished. The keyboard is now made to exit correctly when the 'back' event is called. The keyboard now uses theme colors correctly, although it still looks best with dark theme. The numbers row is now solidly green - except for highlights.
|
||||
0.04: Now displays the opened text string at launch.
|
|
@ -49,11 +49,12 @@ exports.input = function(options) {
|
|||
g.setColor(BGCOLOR);
|
||||
g.fillRect(0,4+20,176,13+20);
|
||||
g.setColor(0.2,0,0);
|
||||
g.fillRect(3,4+20,5+text.length*6,13+20);
|
||||
var rectLen = text.length<27? text.length*6:27*6;
|
||||
g.fillRect(3,4+20,5+rectLen,13+20);
|
||||
g.setColor(0.7,0,0);
|
||||
g.fillRect(text.length*6+5,4+20,10+text.length*6,13+20);
|
||||
g.fillRect(rectLen+5,4+20,rectLen+10,13+20);
|
||||
g.setColor(1,1,1);
|
||||
g.drawString(text, 5, 5+20);
|
||||
g.drawString(text.length<=27? text.substr(-27, 27) : '<- '+text.substr(-24,24), 5, 5+20);
|
||||
}
|
||||
|
||||
drawAbcRow();
|
||||
|
@ -213,7 +214,7 @@ exports.input = function(options) {
|
|||
|
||||
|
||||
// Make a space or backspace by swiping right or left on screen above green rectangle
|
||||
else {
|
||||
else if (event.y > 20+4) {
|
||||
if (event.b == 0) {
|
||||
g.setColor(HLCOLOR);
|
||||
if (event.x < g.getWidth()/2) {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{ "id": "dragboard",
|
||||
"name": "Dragboard",
|
||||
"version":"0.04",
|
||||
"version":"0.05",
|
||||
"description": "A library for text input via swiping keyboard",
|
||||
"icon": "app.png",
|
||||
"type":"textinput",
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
{ "id": "dragboard",
|
||||
"name": "Dragboard",
|
||||
"version":"0.04",
|
||||
"description": "A library for text input via swiping keyboard",
|
||||
"icon": "app.png",
|
||||
"type":"textinput",
|
||||
"tags": "keyboard",
|
||||
"supports" : ["BANGLEJS2"],
|
||||
"screenshots": [{"url":"screenshot.png"}],
|
||||
"readme": "README.md",
|
||||
"storage": [
|
||||
{"name":"textinput","url":"lib.js"}
|
||||
]
|
||||
}
|
Loading…
Reference in New Issue