Skip to content

Instantly share code, notes, and snippets.

@roflsunriz
roflsunriz / auto_cursor.pyw
Created February 5, 2025 13:03
auto_cursor.pyw : Cursorを常駐させておくGUIプログラム
import os
import time
import psutil
import win32gui
import win32con
from subprocess import Popen
import tkinter as tk
from tkinter import ttk, messagebox
import winreg
import sys
@roflsunriz
roflsunriz / WSAInstallAPK.pyw
Last active February 5, 2025 13:02
WSAInstallAPK.py : GUI Program that performs installing APK for WSA (Windows Android Subsystem)
import tkinter as tk
from tkinter import scrolledtext, filedialog
import subprocess
import threading
import os
import json
# 言語用の辞書の定義
LANGUAGES = {
"ja": {
@roflsunriz
roflsunriz / OpenWebUI.pyw
Last active February 20, 2025 13:43
OpenWebUI.py : Open-WebUIサーバーを127.0.0.1:8081で自動的に開始し、文字列が現れるのを待った後Firefoxでページを開く。
import subprocess
import time
import psutil
import threading
import os
try:
import tkinter as tk
from tkinter import ttk
except ImportError:
subprocess.check_call(["pip", "install", "tk"])
@roflsunriz
roflsunriz / taskkill_wizard_gui.pyw
Last active February 5, 2025 13:01
taskkill_wizard_gui : タスクキルをGUIで出来るウィザード
import tkinter as tk
from tkinter import ttk, scrolledtext, messagebox
import psutil
import os
import win32gui
import win32process
import win32con
import win32api
from PIL import Image, ImageTk
import io
@roflsunriz
roflsunriz / japaneseEra.py
Last active January 12, 2025 00:33
japaneseEra : 和暦(年号・元号)西暦変換プログラム
class JapaneseEra:
ERA_STARTS = {
"飛鳥": 592,
"白雉": 650,
"天武": 672,
"朱鳥": 686,
"大宝": 701,
"慶雲": 704,
"和銅": 708,
"霊亀": 715,
@roflsunriz
roflsunriz / DaikinACCostCalculator.py
Last active January 12, 2025 00:34
DaikinACCostCalculator : エアコン電気代計算プログラム ダイキンEシリーズエアコンの地域ごとモデルごとのランニングコストを計算します。
class DaikinACCostCalculator:
def __init__(self):
# 既存の電力会社データを継承
self.electricity_companies = {
'東京電力': {
'base_fee': 935.25,
'rates': [
{'limit': 120, 'rate': 29.80},
{'limit': 300, 'rate': 36.40},
{'limit': float('inf'), 'rate': 40.49}
@roflsunriz
roflsunriz / HeatingCostCalculator.py
Last active January 12, 2025 00:34
HeatingCostCalculator : 暖房費計算プログラム 全国の暖房費を暖房器具ごとに1ヶ月のランニングコストを計算します。
class HeatingCostCalculator:
def __init__(self):
# 電力会社ごとの料金データを更新
self.electricity_companies = {
'東京電力': {
'base_fee': 935.25,
'rates': [
{'limit': 120, 'rate': 29.80},
{'limit': 300, 'rate': 36.40},
{'limit': float('inf'), 'rate': 40.49}
@roflsunriz
roflsunriz / dAnime-nicoComment.user.js
Last active February 22, 2025 21:54
dAnime NicoComment Renderer : dアニメでニコニコ動画のコメントをレンダリングするプログラム
// ==UserScript==
// @name dAnime NicoComment Renderer
// @namespace https://gist.github.com/roflsunriz/0aa936cf4c42d932e6b64185c83a4ecb
// @author roflsunriz
// @version 8.8
// @description dアニメでニコニコ動画のコメントを表示するのじゃ!
// @match *://animestore.docomo.ne.jp/*
// @connect www.nicovideo.jp
// @connect nicovideo.jp
// @connect *.nicovideo.jp
@roflsunriz
roflsunriz / image-collector.user.js
Last active January 23, 2025 01:47
Image Collector : Webページにある画像を収集するユーザースクリプト
// ==UserScript==
// @name Image Collector
// @namespace https://gist.github.com/roflsunriz/80f7a2fd21db0ea9a6aa5565cedb4c55
// @version 10.2
// @description 画像を収集して表示・ダウンロードするのじゃ!
// @author roflsunriz
// @match *://*/*
// @grant GM_download
// @grant GM_registerMenuCommand
// @grant GM_setValue
@roflsunriz
roflsunriz / imgur_direct_link_copier.user.js
Last active January 16, 2025 08:53
Imgur.com Direct Link Copier : Imgurのアルバムページ (e.g. https://imgur.com/a/AbCdeFgh) でダイレクトリンクをコピー