electron-trubar v1.0.9
Electron TruBar (electron-trubar)
The fastest and easiest way to customize any electron app window through the main process.
Installing it
npm install electron-trubar --saveWhat it includes
backgroundColor - String | Color/Hex
textColor - String | Color/Hex
seamColor - String | Color/Hex
seam - Boolean | Seamless/Seam
title - String | Title/Text
height - Number | Integer/Float
trafficLightX - Number | Integer/Float
trafficLightY - Number | Integer/Float
Definitions
backgroundColor - Controls the background color of the titlebar.
textColor - Controls the foreground color of the titlebar.
seamColor - Controls the seam color of the titlebar.
seam - Controls whether the seam is shown on the titlebar.
title - Controls the title for of the titlebar.
height - Controls the height of the titlebar.
trafficLightX - Controls the X Axis position of the traffic lights.
trafficLightY - Controls the Y Axis position of the traffic lights.
Example
npm install electron-trubar --savemain.js
const { app, BrowserWindow } = require("electron");
const TruBar = require("electron-trubar");
app.on("ready", function() {
const mainWindow = new BrowserWindow({ ... });
TruBar(mainWindow, {
backgroundColor: "#333",
textColor: "#fff",
seam: true,
seamColor: "#eee",
height: 20,
trafficLightX: 6.5,
trafficLightY: 6.5,
title: "My app"
});
});Output
White

Red

Black

License
MIT