Localizing the Designer
Наши примеры проектов и шаблоны отчётов помогут Вам разобраться в основах работы с нашими продуктами.The designer can offer several interface languages in its menu, loaded from Stimulsoft language XML files.
In React.
How it works. Each file registers a language in the menu, so users switch the designer's interface on demand.
In React.
import { Designer, Stimulsoft } from "stimulsoft-dashboards-js-react/designer";
function App() {
var report = new Stimulsoft.Report.StiReport();
report.loadFile("Dashboards/Dashboard.mrt");
// Add languages to the designer's language menu
Stimulsoft.Base.Localization.StiLocalization.addLocalizationFile("Localizations/de.xml");
Stimulsoft.Base.Localization.StiLocalization.addLocalizationFile("Localizations/ja.xml", false, "MyLabel");
// Load one at startup and set it as default
Stimulsoft.Base.Localization.StiLocalization.addLocalizationFile("Localizations/pt.xml", true);
Stimulsoft.Base.Localization.StiLocalization.cultureName = "Portuguese";
var options = new Stimulsoft.Designer.StiDesignerOptions();
options.appearance.fullScreenMode = true;
return <Designer options={options} report={report} />;
}addLocalizationFile(path)— add a language to the designer's menu; passtrueto load it at startup.cultureName— the default language selected before the designer opens.
How it works. Each file registers a language in the menu, so users switch the designer's interface on demand.