Windows

Windowsで仮想ディスクを暗号化

USBメモリは便利な反面、紛失や盗難による情報漏洩リスクがあります。
仮想ハードディスク(VHD)を作成し、
BitLockerで暗号化することでリスクを低減できるかもしれません。
USBメモリにVHDを作成し、暗号化する手順を解説します。

続きを読む

新型Surface ProとLaptopが発表

Microsoft社が新型のSurface ProとSurface Laptopを発表しました。

従来機から見た大きな変更点として
これまで主にSurface Xシリーズに搭載していたARMアーキテクチャCPUを
搭載していることがあげられます。
以前から噂のあったQualcomm社のSnapdragon Xという名称のSoCを搭載しています。

新型Surface Pro と Surface Laptop どちらも
Snapdragon X Plus と Snapdragon X Eliteから選択できるようで
Elite とある方が上位モデルのようです。

Microsoftはこれらの機種を「Copilot+ PC」と謳っており、
クラウド上ではなく、デバイス上でAIを利用した機能を実行できるとしています。

AIアシスタントのCopilotが最新のGPT-4oに対応する事や、
新機能であるRecallの発表もありました。

CPUの変更によってバッテリーの持続時間が伸びているであろう事や、
発熱が抑えられているであろう事、
Microsoftが推しているAI機能についても面白そうという期待はありますが、
昨今の為替事情もあり、最も安価な構成でも販売価格が20万円を超えるという点でなかなか手を出しづらいなと思います。

水曜担当:Tanaka



Windows機からiSCSIターゲットに接続する

前回の記事の続きです。

Windows機からiSCSIターゲットに接続する方法の紹介です。
OSはWindwos11です。

続きを読む

Streamlining Electron.js App with Tray Icons

In the realm of desktop application development, Electron.js stands out as a robust framework for building cross-platform apps using web technologies. Among its many features, integrating tray icons can significantly enhance user experience by providing quick access to essential functionalities. Today, let’s explore how we can implement tray icons in our Electron.js application, from setup to implementation.

Setting Up A Electron.js Project

First things first, let’s set up a basic Electron.js project:

1. Initialize a new Node.js project

mkdir project_name && cd project_name
npm init -y

2. Install Electron.js

npm install electron

3. Create project files

project_name/
├── icon.png
├── index.html
├── index.js
├── node_modules
├── package.json
└── package-lock.json

– `index.html` for the application’s UI.

– `index.js` for Electron main process code.

– An icon file (`icon.png`) for the tray icon.

– add `start` command in package.json like this.

{
  "name": "project_name",
  "version": "1.0.0",
  "description": "",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1",
    "start": "electron ."
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "dependencies": {
    "electron": "^29.0.1"
  }
}

Implementing Tray Icon Functionality

Next, let’s dive into implementing the tray icon functionality in `index.js` file:

const { app, Tray, BrowserWindow } = require('electron');
const path = require('path');

let tray = null;
let mainWindow = null;

app.on('ready', () => {
  tray = new Tray(path.join(__dirname, 'icon.png'));

  mainWindow = new BrowserWindow({
    width: 800,
    height: 600,
    show: false,
    webPreferences: {
      nodeIntegration: true
    }
  });

  mainWindow.loadFile('index.html');

  tray.on('click', () => {
    mainWindow.isVisible() ? mainWindow.hide() : mainWindow.show();
  });
});

Running Your Electron.js Application

To run Electron.js application, execute the following command in the terminal:

npm start

This command will start Electron application, and we should see the tray icon appear in our system tray. Clicking on the tray icon should toggle the visibility of the application window.

Conclusion

Integrating tray icons into Electron.js application is a straightforward process that can greatly improve user experience. Whether it’s for displaying notifications, providing quick access to features, or simply adding a professional touch to our app, tray icons are a valuable addition to any desktop application.

With Electron.js, implementing tray icons becomes seamless, allowing us to focus on crafting an exceptional user experience for our desktop application. So why not enhance our Electron.js app with a sleek tray icon for innovative ideas?

Hope you enjoy that.

By Asahi



netshコマンドを利用した簡単なポートフォワードの設定方法

Dockerで建てたローカルネットワーク内の仮想サーバーにポート番号を指定せずに
URLでアクセスしたいことがありましたので、その方法を調べました。

続きを読む


アプリ関連ニュース

お問い合わせはこちら

お問い合わせ・ご相談はお電話、またはお問い合わせフォームよりお受け付けいたしております。

tel. 06-6454-8833(平日 10:00~17:00)

お問い合わせフォーム