Skip to content

Commit

Permalink
Add new icon
Browse files Browse the repository at this point in the history
  • Loading branch information
jcf94 committed Jan 1, 2019
1 parent 9faa150 commit 524a102
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 55 deletions.
102 changes: 52 additions & 50 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,51 +1,53 @@
# VizGraph

A simple tool for Using [Graphviz](https://graphviz.gitlab.io/). Based on [Viz.js](https://github.com/mdaines/viz.js) & [Electron](https://github.com/electron/electron).

---

CircleCI Building: [![CircleCI](https://circleci.com/gh/jcf94/vizgraph.svg?style=svg)](https://circleci.com/gh/jcf94/vizgraph)

---

Sample usage from [Graphviz Gallery](https://graphviz.gitlab.io/gallery/):

![](doc/img/exp1.png)

![](doc/img/exp2.png)

---

This project is on its **beta release** now.

# Usage

The major framework is based on Electron, so it should be worked on **All Platforms** that support Node.js( Exp. Windows, Mac and Linux).

## For Developers

First, make sure you have a proper [Node.js Environment](https://nodejs.org/en/download/):

```bash
node -v
npm -v
```

Then start it easily.

```bash
git clone https://github.com/jcf94/vizgraph.git
cd vizgraph
npm install
npm start
```

Enjoy it.

Use [electron-builder](https://github.com/electron-userland/electron-builder) to pack release for platforms you like.

## For Users

Get the latest [release](https://github.com/jcf94/vizgraph/releases).

# VizGraph

![](src/img/ico.png)

A simple tool for Using [Graphviz](https://graphviz.gitlab.io/). Based on [Viz.js](https://github.com/mdaines/viz.js) & [Electron](https://github.com/electron/electron).

---

CircleCI Building: [![CircleCI](https://circleci.com/gh/jcf94/vizgraph.svg?style=svg)](https://circleci.com/gh/jcf94/vizgraph)

---

Sample usage from [Graphviz Gallery](https://graphviz.gitlab.io/gallery/):

![](doc/img/exp1.png)

![](doc/img/exp2.png)

---

This project is on its **beta release** now.

# Usage

The major framework is based on Electron, so it should be worked on **All Platforms** that support Node.js( Exp. Windows, Mac and Linux).

## For Developers

First, make sure you have a proper [Node.js Environment](https://nodejs.org/en/download/):

```bash
node -v
npm -v
```

Then start it easily.

```bash
git clone https://github.com/jcf94/vizgraph.git
cd vizgraph
npm install
npm start
```

Enjoy it.

Use [electron-builder](https://github.com/electron-userland/electron-builder) to pack release for platforms you like.

## For Users

Get the latest [release](https://github.com/jcf94/vizgraph/releases).

Now we have portable packages for Windows(.exe) and Most Linux Repositories(.AppImage).
2 changes: 1 addition & 1 deletion main.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ ipcMain.on('proxy_create_new_dot', (event, message) => {

function createWindow() {
// Create the browser window.
mainWindow = new BrowserWindow({width: mainWindow_width, height: mainWindow_height, icon: 'src/img/app.ico'});
mainWindow = new BrowserWindow({width: mainWindow_width, height: mainWindow_height, icon: 'src/img/ico.png'});

// and load the index.html of the app.
mainWindow.loadURL(url.format({
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@
"build": {
"appId": "com.jcf94.vizgraph",
"productName": "vizgraph",
"extraFiles": ["template/*"],
"extraFiles": ["template/*", "src/img/ico.png"],
"icon": "src/img/ico.ico",
"win": {
"target": {
"target": "portable",
Expand All @@ -42,8 +43,7 @@
"x64"
]
},
"publisherName": "Jcf94",
"icon": "src/img/app.ico"
"publisherName": "Jcf94"
},
"linux": {
"target": {
Expand Down
Binary file added src/img/ico.ico
Binary file not shown.
Binary file added src/img/ico.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 3 additions & 1 deletion src/script/graph.js
Original file line number Diff line number Diff line change
Expand Up @@ -638,10 +638,12 @@ let menutemplate = [
}
];

const nativeImage = remote.nativeImage;

let open_about_dialog = () => {
dialog.showMessageBox(mainWindow, {
title: 'About VizGraph',
type: 'info',
icon: nativeImage.createFromPath('src/img/ico.png'),
message: 'VizGraph',
detail: 'A simple tool for Using Graphviz.\nPowered by Viz.js & Electron.\n\n' +
'App version: Beta ' + app_version
Expand Down

0 comments on commit 524a102

Please sign in to comment.