GOOi, an Android-Oriented GUI Library
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
You're actually right, the second one is the normal way, not sure what I was thinking, let me check that out
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
Done! now the canvas logic is as usual:
EDIT: I didn't even notice the colors where wrong, this is GÖÖi scaled (x4), with and without nearest filter:
EDIT 2: Multitouch is not working on scaled canvases, in Android... I'm checking this.
EDIT 3: Done, now it sems to work fine in Desktop and Android, scaled or not try this .love, comment the lines according to the platform:
Code: Select all
function love.draw()
-- Do canvas stuff:
gr.setCanvas(canvas)
gr.clear()
gr.setColor(62, 131, 95)
gr.rectangle("fill", 0, 0, width, height)
gr.setColor(255, 255, 255)
gr.draw(imgBg, 0, 0)
gooi.draw()
gr.setCanvas()
gr.draw(canvas, 0, 0, 0, scale, scale)-- <--Scale your canvas
end
EDIT 2: Multitouch is not working on scaled canvases, in Android... I'm checking this.
EDIT 3: Done, now it sems to work fine in Desktop and Android, scaled or not try this .love, comment the lines according to the platform:
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
Version 0.0.1 is now officially released, there are vertical sliders now:
P.S. Süsse has not this version yet
P.S. Süsse has not this version yet
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
I've created a Wiki for GÖÖi (is still missing some details but it's good enough for now), hope you like it!
- ArchAngel075
- Party member
- Posts: 319
- Joined: Mon Jun 24, 2013 5:16 am
Re: GÖÖi, an Android-Oriented GUI Library
encountered an issue,
take the below code
copied directly from the wiki. I changed the style to be font size 48.
When using
it is applied to the label, but using
it is not applied to label.
**EDIT**
fix found :
changing gooi/gooi.lua line: 1815
from
to
Issue tracked @ https://github.com/tavuntu/gooi/issues/6
take the below code
Code: Select all
local defaultStyling = {
bgColor = {12, 183, 242, 170}, -- LOVE blue
fgColor = {255, 255, 255, 255}, -- Foreground color
tooltipFont = love.graphics.newFont(10), -- tooltips are smaller than the main font
radius = 3, -- radius for the outer shapes of components
innerRadius = 3, -- For the inner ones
showBorder = false, -- border for components
borderColor = {12, 183, 242, 255},
borderWidth = 2, -- in pixels
font = love.graphics.newFont(48),
mode3d = false, -- gives that subtle gradient on the given color
glass = false -- for a glass effect (horizon reflection)
}
local lab = gooi.newLabel({
text = "hello my name is bob",
x = 25,
y = 150,
w = 100,
h = 30,
align = "left", -- text alignment
icon = "imgs/exit.png",
})
lab:setStyle(defaultStyling)
When using
Code: Select all
gooi.setStyle(defaultStyling)
Code: Select all
lab:setStyle(defaultStyling)
**EDIT**
fix found :
changing gooi/gooi.lua line: 1815
from
Code: Select all
love.graphics.setFont(gooi.getFont())-- Specific or a common font.
Code: Select all
love.graphics.setFont(gooi.getFont(comp))-- Specific or a common font.
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
It's fixed now, thanks!
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
Here's the canvas demo (updated):
Last edited by alberto_lara on Wed Jan 11, 2017 10:24 pm, edited 1 time in total.
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
it's possible nowxopxe wrote:Is it possible / will it be possible to have vertical sliders?
Re: GÖÖi, an Android-Oriented GUI Library
Could you ever implement something like this?
Panel:getComponent(row, column)
Panel:getComponent(row, column)
- alberto_lara
- Party member
- Posts: 372
- Joined: Wed Oct 30, 2013 8:59 pm
Re: GÖÖi, an Android-Oriented GUI Library
Sure, why not, feel free to open a request issue
Who is online
Users browsing this forum: No registered users and 1 guest