Switch Layout Editor - Create/Edit Themes and Games

Hello everyone, exelix and I are finally releasing the Switch Layout Editor. Please note that this is still in beta.

Brief Description:

The Switch Layout Editor enables you to edit and preview BFLYT and BFLAN files which are used in the Switch interfaces and games.
With this tool you can easily create and edit themes.


Main Features:

  • Layout loading, editing and saving
  • Rendering the bounding boxes of the components
  • SZS editing
  • Drag and drop
  • Simultaneous file editing
  • Import/Export JSON patch (Compatible with Switch themes)
How to use:

You can check the Wiki on the Github page for a more in depth tutorial.

Extract the zip file and open "Switch Layout Editor.exe". You can now open a SZS, BFLYT or BFLAN file.
BFLYT files are commonly found in SZS archives, when opening a SZS file you can double click on the files in the list to edit them (if they're supported).

If you're making a theme:
Once you're done editing, you can either:
- Save your changes to the SZS and use it. (illegal to share publicly)
- Export your theme as a JSON patch that you can use with the Switch Theme Injector to create a nxtheme (legal to share)

Discord Server / Support:
You can make an issue on github if you encounter a problem or you can join the discord.
This discord server is used for all my projects.


Release:

Updates:

- Adding and removing texture references in a bflyt file
- Editing materials (partial)
- Fix crashes or corrupted files for big endian bflyts (for Wii U titles)
Download here.

- Animations editor (.bflan files)
- Group (grp panes) editing for bflyt files
- Fix for some crashes and some minor improvements
Download here.

- You can now update the SwitchLayoutEditor directly from within the tool. No need to check Github anymore, just click on the Update button.
- Support for usd1 panes + custom usd1 panes.
- Search box in the SZS editor.
Download here.
Hotfix for a bug causing a black screen. Download here

Screenshots:
MainMenu.png

Layout Example:
Example.png

Support:
You can join the Qcean discord server for any help related to themes.

Credits:
  • FuryBaguette - Development
  • exelix - Base of the editor & Continuous development
  • Abood - Sarc Tool
  • Syroot - BinaryData
MainMenu.png
 
Last edited by FuryBaguette,

exelix11

Developer
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
any plan to add default layout/values derived from the stock common.szs so users doesnt need to dump their own SZS file?
I'm pretty sure that would be gray zone or simply illegal for the same reason you can't just distribute common.szs :V
Still dumping files now it's much easier, the nxthemes installer app will do everything automatically
 
  • Like
Reactions: FuryBaguette

orangpelupa

Well-Known Member
Member
Joined
Aug 7, 2009
Messages
388
Trophies
1
XP
1,183
Country
Indonesia
I'm pretty sure that would be gray zone or simply illegal for the same reason you can't just distribute common.szs :V
Still dumping files now it's much easier, the nxthemes installer app will do everything automatically

Then how about make a new default layout that's not using values from stock layout ?

2 layouts: lockscreen and homescreen. Would be a nice start
 

HoTsHoTz79

GIC-Developer
Member
Joined
May 9, 2018
Messages
322
Trophies
0
Age
39
XP
964
Country
Canada
@exelix11 Thank you earlier for your help ... I created a new layout ... both the tools are excellent

Just one suggestion for the Qcena's Switch Theme Injector... when testing changes it can save some time if the following can be added to the tool;

A new button that automatically Builds the NXTheme and does Remote Install (keep the IP saved for next time)

Currently clicking the Build NXTheme prompts you to enter theme name and author, which i just type random letter to test only
Then Clicking on Remote Install i have to enter the IP address again

(P.S looking forward to the new release cuz of reboot to payload commit)

Here's my new "One Game Left Side" layout (aka OGLS)

ojeihB7.jpg
 
Last edited by HoTsHoTz79,

exelix11

Developer
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
Then how about make a new default layout that's not using values from stock layout ?

2 layouts: lockscreen and homescreen. Would be a nice start
Making a new layout still means using copyrighted data from the bflyt as we must keep most parts of the file for the home menu to work, in fact custom layouts edit just a very minor part of the binary file, that's why they can be easily made into a json.
Unfortunately there's no way of previewing the correct layout and outputting working files without having to rely on the layouts. (And converting a whole bflyt to json is still not legal as it's the same data just with a different encoding)
 

PKNess

Well-Known Member
Newcomer
Joined
Mar 11, 2015
Messages
70
Trophies
0
XP
199
Country
i made a layout, but even when in the layout is stated the size and all, the icons in the home menu show up with the default size, am i missing something???

this is a pastebin of the json file, idk if someone might want to see what's wrong... https://pastebin.com/ZbvzD5cS
 
Last edited by PKNess,

exelix11

Developer
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
i made a layout, but even when in the layout is stated the size and all, the icons in the home menu show up with the default size, am i missing something???

this is a pastebin of the json file, idk if someone might want to see what's wrong... https://pastebin.com/ZbvzD5cS
Apparently you can't edit the size in rdtbase, you have to edit it in the game icon file, idk why
 

XorTroll

Switching between my 2DS and my Switch
Developer
Joined
Dec 28, 2017
Messages
642
Trophies
1
Location
Nowhere
Website
github.com
XP
4,230
Country
Spain
@exelix11 Thank you earlier for your help ... I created a new layout ... both the tools are excellent

Just one suggestion for the Qcena's Switch Theme Injector... when testing changes it can save some time if the following can be added to the tool;

A new button that automatically Builds the NXTheme and does Remote Install (keep the IP saved for next time)

Currently clicking the Build NXTheme prompts you to enter theme name and author, which i just type random letter to test only
Then Clicking on Remote Install i have to enter the IP address again

(P.S looking forward to the new release cuz of reboot to payload commit)

Here's my new "One Game Left Side" layout (aka OGLS)

ojeihB7.jpg
Hehe, it's always nice to see that every layout screen has Goldleaf installed :)
 
  • Like
Reactions: HoTsHoTz79

FuryBaguette

Well-Known Member
OP
Newcomer
Joined
Jan 6, 2019
Messages
57
Trophies
0
Age
27
XP
541
Country
France
i made a layout, but even when in the layout is stated the size and all, the icons in the home menu show up with the default size, am i missing something???

this is a pastebin of the json file, idk if someone might want to see what's wrong... https://pastebin.com/ZbvzD5cS

You can do this by changing the Scale not the Size. You can do this directly on the root pane of the game icons iirc.
 

Tinnetju

Well-Known Member
Newcomer
Joined
Jul 31, 2018
Messages
66
Trophies
0
Age
43
XP
249
Country
Netherlands
@exelix11 Thank you earlier for your help ... I created a new layout ... both the tools are excellent

Just one suggestion for the Qcena's Switch Theme Injector... when testing changes it can save some time if the following can be added to the tool;

A new button that automatically Builds the NXTheme and does Remote Install (keep the IP saved for next time)

Currently clicking the Build NXTheme prompts you to enter theme name and author, which i just type random letter to test only
Then Clicking on Remote Install i have to enter the IP address again

(P.S looking forward to the new release cuz of reboot to payload commit)

Here's my new "One Game Left Side" layout (aka OGLS)

Jesus that layout is gorgeous. Thanks for sharing
 
  • Like
Reactions: HoTsHoTz79

KitsumiTheFox

Well-Known Member
Newcomer
Joined
Jan 9, 2016
Messages
85
Trophies
0
Age
23
Location
Utah
XP
590
Country
United States
So, shameless plug here, but I've also made a web version for those that don't wanna download anything,
I'll link it only as long as @FuryBaguette is okay with me doing so, as I don't wanna steal his thread or anything.
I'm sorry for mentioning this here, but I thought this would probably end up being the best place.
 

ReroShaggy

Member
Newcomer
Joined
Aug 5, 2017
Messages
20
Trophies
0
Age
113
XP
86
Country
United States
I'm excited to work more with this. I have spent a couple hours on it, it unfortunately at the moment is too confusing as to what names correspond to what. Some stock menu layouts have boxes all over the place outside of viewing area, nested, not very clear what purpose they serve and when.... It's getting there. I hope someday to see a preview render window so we can see faster what changes are being made with more clarity. Thanks.
 
  • Like
Reactions: FuryBaguette

KitsumiTheFox

Well-Known Member
Newcomer
Joined
Jan 9, 2016
Messages
85
Trophies
0
Age
23
Location
Utah
XP
590
Country
United States
I'm excited to work more with this. I have spent a couple hours on it, it unfortunately at the moment is too confusing as to what names correspond to what. Some stock menu layouts have boxes all over the place outside of viewing area, nested, not very clear what purpose they serve and when.... It's getting there. I hope someday to see a preview render window so we can see faster what changes are being made with more clarity. Thanks.
Have you seen my web version?
 
  • Like
Reactions: ReroShaggy

ReroShaggy

Member
Newcomer
Joined
Aug 5, 2017
Messages
20
Trophies
0
Age
113
XP
86
Country
United States
I have just now and yours seems like it's coming along nicely as well. I like the titled icons though can't read a lot of them but im sure that's going to get fixed. I appreciate all your efforts. I assume, for both, in order to see a rendered view of all the elements as it would be seen in final packaged .nxtheme, it would require integration with some sort of bflan/.bntx viewer. I hope either directions are considering this as it would help greatly in associating names of elements with visuals, without requiring a compile, push (payload), view, edit, repeat...process. just going to take a lot of trial and error.
If I have a burning question for the moment is, is there a way in the code to specify which icon you want the selection box (on the switch) to move to when a specific directions pressed? Or does the switch kind of guess which icon to select? Tried a few layouts and some icons became unselectable because the switch refused to go to it. Sure on-screen clicking is an option but i'm the kind of guy who guys for complete instead of workable.
 
Last edited by ReroShaggy,

exelix11

Developer
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
I have just now and yours seems like it's coming along nicely as well. I like the titled icons though can't read a lot of them but im sure that's going to get fixed. I appreciate all your efforts. I assume, for both, in order to see a rendered view of all the elements as it would be seen in final packaged .nxtheme, it would require integration with some sort of bflan/.bntx viewer. I hope either directions are considering this as it would help greatly in associating names of elements with visuals, without requiring a compile, push (payload), view, edit, repeat...process. just going to take a lot of trial and error.
If I have a burning question for the moment is, is there a way in the code to specify which icon you want the selection box (on the switch) to move to when a specific directions pressed? Or does the switch kind of guess which icon to select? Tried a few layouts and some icons became unselectable because the switch refused to go to it. Sure on-screen clicking is an option but i'm the kind of guy who guys for complete instead of workable.
An accurate renderer is very hard, initially we were considering doing it but unfortunately there's just too much work to do, maybe basic image rendering will come at some point, but there are still many unknown formats and the rendered boxes don't always match the actual layout.
About the cursor there are specific BND type panes that can block it from going to certain places, you may want to try moving those around but afaik it's not handled in the layout.
 
  • Like
Reactions: ReroShaggy

ReroShaggy

Member
Newcomer
Joined
Aug 5, 2017
Messages
20
Trophies
0
Age
113
XP
86
Country
United States
I get it, just throwing out my thoughts. Probably even easier to just have a box in the editor that explains contextual information about the particular element. Information like "this box appears in this situation and is also referenced in this bflyt for this purpose." Which I'm sure will eventually be learned. I forget which bflyt i checked out but in it, couldn't figure out what any element in it had to do in the ui or it's relation to other things. I'm an artist, i don't often get into the code of things so i just need some time.
 

ReroShaggy

Member
Newcomer
Joined
Aug 5, 2017
Messages
20
Trophies
0
Age
113
XP
86
Country
United States
what is the accurate unit of measure used in these layouts? So i'm a graphic designer. I designed something, found it's place pixel wise in the image, and have gone into the editor to place elements. whether I pick origin top/center/left/right doesn't matter none of the number in the x/y coincide to 1280 720. Editing Residentmenu.szs N_Root says its 100 by 100 which is weird for a size. If N_game for instance to the top left corner, with it's parent set to center, it shows -646;350;0 for position. Shouldn't it be either half of 720x1280, or if orientation set to left top...0;0;0?

Reference to my layout:
examp.png
 
Last edited by ReroShaggy,

KitsumiTheFox

Well-Known Member
Newcomer
Joined
Jan 9, 2016
Messages
85
Trophies
0
Age
23
Location
Utah
XP
590
Country
United States
Afaik:
The origin property controls the 0,0 point of the child, so Origin means offset position by child size, and parent origin means offset position by parent size. Also, the child inherits the position and all other properties from it's parent.
So say parent is at 100,100 and then the child is at 10,10. The child's actual position would be 110,110 (assuming both the parent's parentorigin is 0,0, the parent's origin is 0,0, the child's parentorigin is 0,0 and the child's origin is 0,0)
Sorry if that's a little confusing. Hope it helps!
QQA6XL3.gif
 
Last edited by KitsumiTheFox,
  • Like
Reactions: exelix11

ReroShaggy

Member
Newcomer
Joined
Aug 5, 2017
Messages
20
Trophies
0
Age
113
XP
86
Country
United States
Afaik:
The origin property controls the 0,0 point of the child, so Origin means offset position by child size, and parent origin means offset position by parent size. Also, the child inherits the position and all other properties from it's parent.
So say parent is at 100,100 and then the child is at 10,10. The child's actual position would be 110,110 (assuming both the parent's parentorigin is 0,0, the parent's origin is 0,0, the child's parentorigin is 0,0 and the child's origin is 0,0)
Sorry if that's a little confusing. Hope it helps!

I understand what your saying but in the PC Switch Layout editor i'm having issues with that.

--------------------- MERGED ---------------------------

I have made some progress. Since I am so far along I will share whats going on. Designed based off of Capcom VS Snk 2. I give you my CVSVNX Layout/theme. Still need to tweak some things. All buttons can be selected with D-pad, except the bottom row of icons (settings, album...) is interfering. This will have setup for all users, they will appear along the sides and 3 along top of player select. I need to figure out how to remove the grey/black ring around the user icons. I am in the process of adding higher res character images. I also need to figure out how to remove user icon names form the icon as seen with this Metaknight user icon. Despite picking the exact values for the battery and time icon color...it shows up pink IDK why. Need to rotate allgames icon. Lastly size and position tweaks of all buttons.
CVSVNX Reroshaggy.jpg
 

Attachments

  • CVSVNX Reroshaggy.jpg
    CVSVNX Reroshaggy.jpg
    401.5 KB · Views: 170
  • CVSVNK Reroshaggy b.jpg
    CVSVNK Reroshaggy b.jpg
    404 KB · Views: 196
  • CVSVNK Reroshaggy b.jpg
    CVSVNK Reroshaggy b.jpg
    404 KB · Views: 154
Last edited by ReroShaggy,
  • Like
Reactions: exelix11

exelix11

Developer
Developer
Joined
Feb 25, 2015
Messages
915
Trophies
1
Location
C:\users\exelix11\
XP
3,062
Country
Italy
Afaik:
The origin property controls the 0,0 point of the child, so Origin means offset position by child size, and parent origin means offset position by parent size. Also, the child inherits the position and all other properties from it's parent.
So say parent is at 100,100 and then the child is at 10,10. The child's actual position would be 110,110 (assuming both the parent's parentorigin is 0,0, the parent's origin is 0,0, the child's parentorigin is 0,0 and the child's origin is 0,0)
Sorry if that's a little confusing. Hope it helps!
QQA6XL3.gif
@ReroShaggy ^Yeah that's pretty much it. But you have also to consider prt panes: when near a pane name you see [prt1] it means that it actually displays another bflyt from that szs, to know which one select it and press q, it should pop up the hex editor and at the bottom it should contain the filename. Editing stuff like rotation and size in the original files rather than in the prt panes may have different effects on the final result and even the cursor behaviour, I'd say always try editing the values in the original panes first. (I'm still unsure about the behavior of size and scale for prt panes that's why they are rendered just as rectangles).
About the user name it should be just a text pane you can move away, it should be in the layout referenced by the prt pane. For the border of the i think i know how to remove it and i'm implementing it in the nxtheme format and the layout editor soon enough. For the icons color i'm not sure, that happens because the material has certain properties set, i had the same issue while implementing custom album icons, the solution for me was altering the image properties but that's not possibe with nxthemes yet (and it's not part of the layout).
Anyway that layout looks really good
 
  • Like
Reactions: ReroShaggy

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Sonic Angel Knight @ Sonic Angel Knight: Or, I also heard that if you use flash memory, it can act as more "RAM" at least windows tell me...