Custom components
Quote from feri on January 24, 2026, 9:57 amI created custom component subcircuits.
For example, I created the outputs.xml file like this:
<!DOCTYPE SimulIDE> <itemlib> <itemset category="Outputs" type="Subcircuit" folder="arduino"> <item name="FlashingGate"/> </itemset> </itemlib>It works in the English version, but if I change the language, it creates an "Outputs" category at the bottom of the list. To make it work for Italian, I need to set category="Uscite." Is there a way to add it to the existing category regardless of the language?
Greetings
I created custom component subcircuits.
For example, I created the outputs.xml file like this:
<!DOCTYPE SimulIDE>
<itemlib>
<itemset category="Outputs" type="Subcircuit" folder="arduino">
<item name="FlashingGate"/>
</itemset>
</itemlib>
It works in the English version, but if I change the language, it creates an "Outputs" category at the bottom of the list. To make it work for Italian, I need to set category="Uscite." Is there a way to add it to the existing category regardless of the language?
Greetings
Quote from arcachofo on January 24, 2026, 12:55 pmIs there a way to add it to the existing category regardless of the language?
No, but I will have a look and try to solve it.
Is there a way to add it to the existing category regardless of the language?
No, but I will have a look and try to solve it.
Quote from feri on February 14, 2026, 11:17 amI thought about doing it this way:
void ComponentSelector::LoadCompSetAt( QDir compSetDir ) { m_compSetDir = compSetDir; // By Simulide Arduino start QSettings settings( QStandardPaths::standardLocations( QStandardPaths::DataLocation).first()+"/simulide.ini", QSettings::IniFormat, 0l ); QString locale = QLocale::system().name(); if( settings.contains( "language" ) ) locale = settings.value( "language" ).toString(); if (locale == "it") compSetDir.setNameFilters( QStringList( "*_it.xml" ) ); else compSetDir.setNameFilters( QStringList( "*_en.xml" ) ); // By Simulide Arduino end QStringList xmlList = compSetDir.entryList( QDir::Files ); //if( xmlList.isEmpty() ) return; // No comp sets to loadI only use two languages and the number of files to edit is not excessive but with many languages the necessary files become many.
Greetings
I thought about doing it this way:
void ComponentSelector::LoadCompSetAt( QDir compSetDir )
{
m_compSetDir = compSetDir;
// By Simulide Arduino start
QSettings settings( QStandardPaths::standardLocations( QStandardPaths::DataLocation).first()+"/simulide.ini", QSettings::IniFormat, 0l );
QString locale = QLocale::system().name();
if( settings.contains( "language" ) ) locale = settings.value( "language" ).toString();
if (locale == "it") compSetDir.setNameFilters( QStringList( "*_it.xml" ) );
else compSetDir.setNameFilters( QStringList( "*_en.xml" ) );
// By Simulide Arduino end
QStringList xmlList = compSetDir.entryList( QDir::Files );
//if( xmlList.isEmpty() ) return; // No comp sets to load
I only use two languages and the number of files to edit is not excessive but with many languages the necessary files become many.
Greetings
Quote from arcachofo on February 17, 2026, 6:23 pmI had a look at this and categories are already working regardless of the language.
For example all subcircuits that come in "data" folder go to the proper folder in any language I choose.
I had a look at this and categories are already working regardless of the language.
For example all subcircuits that come in "data" folder go to the proper folder in any language I choose.
