Homebrew [Release] Homebrew Launcher with grid layout

Arseface_TM

Board Game Dev
Member
Joined
Sep 16, 2015
Messages
331
Trophies
0
Age
32
XP
306
Country
United States
When using the title launcher I'm able to browse to unused parts of the grid, and I managed to freeze the launcher by going out of bounds.
 

filfat

CTO @ Nordcom Group Inc.
Member
Joined
Nov 24, 2012
Messages
1,261
Trophies
1
Location
Gothenburg, Sweden
Website
www.sweetsideofsweden.com
XP
1,749
Country
Sweden
I've just attached beta 44, which includes the following GitHub commits:
  • Folders and themes now draw in grids instead of the ugly button lists. They will show default icons with the first letter of the folder/theme on top, or if folder.smdh or theme.smdh is placed inside the folder/theme directory then the image inside this smdh will be used as the icon for the grid. This change also removes the 8 folder/theme limit, as the folder/theme grids inherit the paging ability of the other grids so can show as many themes/folders as are on the device.
  • In addition, the “Reboot” icon now changes its text to “Rebooting…” when it has been activated so the user will know the device is in the process of rebooting.
  • Finally, I have created a spinning progress wheel. This isn’t used anywhere yet but is included in this commit.

You could always use Travis-ci.org to automatically compile and release a binary (like I do over at https://github.com/filfat-Studios-AB/3ds.js)
see https://github.com/filfat-Studios-AB/3ds.js/blob/master/.travis.yml and https://github.com/filfat-Studios-AB/3ds.js/blob/master/.travis-deps.sh

You will however need to google around a bit to get GH_TOKEN and api_key encrypted correctly :)
 

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
When using the title launcher I'm able to browse to unused parts of the grid, and I managed to freeze the launcher by going out of bounds.
Yep, that bug is on the todo list to be fixed :)

You could always use Travis-ci.org to automatically compile and release a binary (like I do over at https://github.com/filfat-Studios-AB/3ds.js)
see https://github.com/filfat-Studios-AB/3ds.js/blob/master/.travis.yml and https://github.com/filfat-Studios-AB/3ds.js/blob/master/.travis-deps.sh

You will however need to google around a bit to get GH_TOKEN and api_key encrypted correctly :)
Thanks, but that sounds really complicated. Probably easier just to attach it to the first post ;)
 

filfat

CTO @ Nordcom Group Inc.
Member
Joined
Nov 24, 2012
Messages
1,261
Trophies
1
Location
Gothenburg, Sweden
Website
www.sweetsideofsweden.com
XP
1,749
Country
Sweden
Yep, that bug is on the todo list to be fixed :)


Thanks, but that sounds really complicated. Probably easier just to attach it to the first post ;)
I could always do it for you if you add me as an collaborator, though you will still have to login with your github account on travis-ci.org and enable the repo :)
 

GoYoshi

Member
Newcomer
Joined
Aug 24, 2015
Messages
23
Trophies
0
Age
26
XP
117
Country
Gambia, The
What if you could create a custom border around the icons? For example that the background consists of wood like in this 3DS theme:

animal_crossing_3ds_theme.0.jpg

Sometimes I like these playful graphics :)
 
  • Like
Reactions: JJTapia19

JJTapia19

I fight for my friends.
Member
Joined
May 31, 2015
Messages
2,171
Trophies
1
Age
32
XP
2,438
Country
Puerto Rico
@mashers I've noticed that if the theme foldes name is too long for example Kindom Hearts Pattern Theme when you select it on the theme selector screen it just puts the default theme instead of the selected one. I fixed it by renaming the Theme to KH Theme. Now all the needed info it's displayed on the smdh anyways but it might cause confusion if someone donwloads an old theme with a long name.
 

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
What about adding an option to add an outline or a shadow to the top screen text to be more flexible with backgrounds?!
That would be an ideal future addition. Until proper TTF fonts are working it's unlikely to happen though, since the current font engine uses bitmap versions of TTF fonts.

What if you could create a custom border around the icons? For example that the background consists of wood like in this 3DS theme:

animal_crossing_3ds_theme.0.jpg

Sometimes I like these playful graphics :)
FANTASTIC idea!!!!! I'll add this feature. The image can be loaded from a png inside the theme folder. Thank you!

@mashers I've noticed that if the theme foldes name is too long for example Kindom Hearts Pattern Theme when you select it on the theme selector screen it just puts the default theme instead of the selected one. I fixed it by renaming the Theme to KH Theme. Now all the needed info it's displayed on the smdh anyways but it might cause confusion if someone donwloads an old theme with a long name.
Hey buddy, was the original title longer than 64 characters by any chance? The config code is hard coded to allow values no longer than that which might explain why it wouldn't store the value of a theme with a name longer than that.
 
  • Like
Reactions: GoYoshi

JJTapia19

I fight for my friends.
Member
Joined
May 31, 2015
Messages
2,171
Trophies
1
Age
32
XP
2,438
Country
Puerto Rico
Hey buddy, was the original title longer than 64 characters by any chance? The config code is hard coded to allow values no longer than that which might explain why it wouldn't store the value of a theme with a name longer than that.
No it wasn't that long. Please try it out to see is you can reproduce it.
Name one of your themes like mine was. "JJTapia19's Kingdom Hearts pattern Theme" then go to your theme selector and try to choose it. It only applies the default theme for some reason. Renaming it shorter seems like a workaround to fix it.:)
 

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
No it wasn't that long please try it out to see is you can reproduce it.
Name one of your themes like mine was. "JJTapia19's Kingdom Hearts pattern Theme" then go to your theme selector and try to choose it. It only applies the default theme for some reason. Renaming it shorter seems like a workaround to fix it.:)
Hmm ok, I'll try to reproduce the problem. I'll add an issue to the todo list and test it out. Thanks for posting the name of the theme :)
 
  • Like
Reactions: JJTapia19

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
Ok, I've just realised what's happening. The title of the theme is being truncated to fit on the screen, and the truncated text is what is then used to determine the path to the theme to be loaded. It even gets written to hbl.cfg in its truncated form. There's actually no reason to truncate the text when showing themes and folders as there's no text beneath them, so I'll just make it display the whole string without truncating it and this should solve the problem.
 
  • Like
Reactions: JJTapia19

Gocario

GBAFail'd
Member
Joined
Sep 5, 2015
Messages
640
Trophies
0
Location
Bourg Palette
XP
804
Country
France
That would be an ideal future addition. Until proper TTF fonts are working it's unlikely to happen though, since the current font engine uses bitmap versions of TTF fonts.

In PHBank, to draw a simple shadow, I use somthing like this:
Code:
drawText(text, x+1, y+1, colorShadow);
drawText(text, x, y, colorText);
 
  • Like
Reactions: Deleted-236924

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
In PHBank, to draw a simple shadow, I use somthing like this:
Code:
drawText(text, x+1, y+1, colorShadow);
drawText(text, x, y, colorText);
What language is that? And what is the text API?

Edit - never mind, I just realised what you mean, you're just drawing the text twice. Nice idea!
 

Gocario

GBAFail'd
Member
Joined
Sep 5, 2015
Messages
640
Trophies
0
Location
Bourg Palette
XP
804
Country
France
What language is that? And what is the text API?
I don't use that code, it's just a kind of example.

Something like that in your code:
Code:
MADrawText(GFX_BOTTOM, GFX_LEFT, 110+1, (320/2)-(len/2)+1, emptyFolderText, &MAFontRobotoRegular16,lightShadow->r, lightShadow->g, lightShadow->b);
MADrawText(GFX_BOTTOM, GFX_LEFT, 110, (320/2)-(len/2), emptyFolderText, &MAFontRobotoRegular16, light->r, light->g, light->b);

Edit: Yeah, just writing the text twice.
 

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
I don't use that code, it's just a kind of example.

Code:
MADrawText(GFX_BOTTOM, GFX_LEFT, 110+1, (320/2)-(len/2)+1, emptyFolderText, &MAFontRobotoRegular16,lightShadow->r, lightShadow->g, lightShadow->b);
MADrawText(GFX_BOTTOM, GFX_LEFT, 110, (320/2)-(len/2), emptyFolderText, &MAFontRobotoRegular16, light->r, light->g, light->b);
Yeah, I realised what you meant as soon as I posted ;) I would probably modify MADrawText() and MADrawTextWrap() to take parameters for the shadow colour, transparency and offset. That way any text drawing can be easily changed to include the shadow.
 

Gocario

GBAFail'd
Member
Joined
Sep 5, 2015
Messages
640
Trophies
0
Location
Bourg Palette
XP
804
Country
France
Yeah, I realised what you meant as soon as I posted ;) I would probably modify MADrawText() and MADrawTextWrap() to take parameters for the shadow colour, transparency and offset. That way any text drawing can be easily changed to include the shadow.

I am using this from here with @xerpi's sftdlib.
Code:
void sftd_draw_text_pkm(const u16 x, const u16 y, const char* text, ... )
{
    char buffer[256];
    va_list args;
    va_start(args, text);
    vsnprintf(buffer, 256, text, args);
    sftd_draw_text(PHBank::font(), x+1, y+1, RGBA8(0x00, 0x00, 0x00, 0xAF), 12, buffer);
    sftd_draw_text(PHBank::font(), x, y, RGBA8(0xFF, 0xFF, 0xFF, 0xFF), 12, buffer);
    va_end(args);
}

Edit: You understood the idea, everything is fine then. :3
 
Last edited by Gocario,

mashers

Stubborn ape
OP
Member
Joined
Jun 10, 2015
Messages
3,837
Trophies
0
Age
40
Location
Kongo Jungle
XP
5,084
Country
Ok, I've just realised what's happening. The title of the theme is being truncated to fit on the screen, and the truncated text is what is then used to determine the path to the theme to be loaded. It even gets written to hbl.cfg in its truncated form. There's actually no reason to truncate the text when showing themes and folders as there's no text beneath them, so I'll just make it display the whole string without truncating it and this should solve the problem.
@JJTapia19
Yep, that sorted it. I put a flag in the menu entry to draw the full text. This flag gets checked when drawing the text on the top screen, and if its set then the text wraps to the next line and doesn't get truncated. Now the full text gets written to the hbl.cfg and the theme loads correctly. I'll upload a commit and a new binary shortly.
 

JJTapia19

I fight for my friends.
Member
Joined
May 31, 2015
Messages
2,171
Trophies
1
Age
32
XP
2,438
Country
Puerto Rico
@JJTapia19
Yep, that sorted it. I put a flag in the menu entry to draw the full text. This flag gets checked when drawing the text on the top screen, and if its set then the text wraps to the next line and doesn't get truncated. Now the full text gets written to the hbl.cfg and the theme loads correctly. I'll upload a commit and a new binary shortly.
Thanks! You are the best.
 
  • Like
Reactions: Deleted-236924

fmkid

Just another GBATemp's random guy
Member
Joined
Apr 23, 2015
Messages
1,911
Trophies
0
XP
1,424
Country
Colombia
@mashers: Still finding a lot of issues/bugs (on b44) with some screens, D-Pad navigation and with rows selection:

- Problem with selecting empty items/icons persists (cursor out of boundaries)... Apparently, HBL freeze/crash issue solves deactivating "D-Pad navigation on corner icons" option, then should be some problem directly related with that.
- Check sign on "Folders option" screen always stays on "3ds" icon, in despite of selecting another folder.
- About folders too: Re-selecting a open folder is possible again, and this is unnecesary.
- Changing between 2 and 3 rows view (in both ways) produces some unexpected visual effects on "Settings" screen, like icons dissapearing or out of their normal boundaries.
- And a very minimal bug: On "Help" and "Settings" screens, "les" word is shown on top screen selecting some icons.

I really hope you fix that soon (on a next release)... If you can as fast as possible, I (and someone, probably) will be very grateful with you! Thanks!
 
Last edited by fmkid,
  • Like
Reactions: JJTapia19

filfat

CTO @ Nordcom Group Inc.
Member
Joined
Nov 24, 2012
Messages
1,261
Trophies
1
Location
Gothenburg, Sweden
Website
www.sweetsideofsweden.com
XP
1,749
Country
Sweden
In PHBank, to draw a simple shadow, I use somthing like this:
Code:
drawText(text, x+1, y+1, colorShadow);
drawText(text, x, y, colorText);
Simple? Yes. But it would require twice the power (since we're drawing the font twice).
Actually Minecraft (Java) is a really good example of this, you lose about 35-40% if the chat is full (on a normal sized screen).

Though it's a good option till one of use stop being lazy and implement real shadowing (will have to do it sooner or later for 3DS_UI) :P
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
  • Psionic Roshambo @ Psionic Roshambo:
    Float like a butterfly burns when I pee lol
    +1
  • BigOnYa @ BigOnYa:
    So does that mean your date was not good? It burns now?
    +1
  • K3Nv2 @ K3Nv2:
    Got two new stds in one night
    +1
  • BigOnYa @ BigOnYa:
    Giggity
    +1
  • The Catboy @ The Catboy:
    I don't bite! Minus the times when I did bite
  • The Catboy @ The Catboy:
    Like 5 minutes ago
  • K3Nv2 @ K3Nv2:
    Billie needs her lunch
  • K3Nv2 @ K3Nv2:
    Ffs papa brought back the cheeseburger pizza it's like the only decent pie they had since the 80s
  • BigOnYa @ BigOnYa:
    I'm not a fan of papa johns, but that does sound good. We hardly order out pizza, I like making my own, but when we do its donatoes
  • K3Nv2 @ K3Nv2:
    I get them like once every two months anymore
  • K3Nv2 @ K3Nv2:
    Just because it's half a mile from where I live
  • BigOnYa @ BigOnYa:
    Request next time you order, that Shaq deliver it to you
  • K3Nv2 @ K3Nv2:
    I want him to buy me a chain also
  • K3Nv2 @ K3Nv2:
    Open it right next to the one we have
    +1
  • BakerMan @ BakerMan:
    guys should i make a new thread and just count the amount of posts until kyle, luke or leo joins the thread for fun?
  • BakerMan @ BakerMan:
    kyle's fine, just waiting for that wario joke

    luke and leo though, they yap until the thread's enjoyability is about halved
  • K3Nv2 @ K3Nv2:
    Leo is Luke's alterego when he gets hard
  • BigOnYa @ BigOnYa:
    Luke is gone, he got banned. And I'm surprised Leo hasn't yet
  • K3Nv2 @ K3Nv2:
    Subway was actually pretty decent tonight
  • BigOnYa @ BigOnYa:
    Wut you get, a seafood and psi salad sub
  • K3Nv2 @ K3Nv2:
    Psi had my footlong meatball special
    +1
  • PandaPandel @ PandaPandel:
    i want a meatball sandwich
    now
  • K3Nv2 @ K3Nv2:
    Gay
  • BigOnYa @ BigOnYa:
    Bout time you came out and admitted it
  • K3Nv2 @ K3Nv2:
    Bigonya talks to himself often
    +1
    K3Nv2 @ K3Nv2: Bigonya talks to himself often +1