Skip to content

Instantly share code, notes, and snippets.

View tmyt's full-sized avatar
🏠
Working from home

Yutaka TSUMORI tmyt

🏠
Working from home
View GitHub Profile

Keybase proof

I hereby claim:

  • I am tmyt on github.
  • I am tmyt (https://keybase.io/tmyt) on keybase.
  • I have a public key ASDrYgG745Fo0Jc8nbDEM29N7xtuF59ftsYAQ1CiUf7vJAo

To claim this, I am signing this object:

    • 下着
    • シャツ
    • ズボン
  • ハンドタオル
  • 電話
    • iPhone
      • MagSafe Wallet
      • MagSafe Battery
  • Surface Duo 2
@tmyt
tmyt / 1.cpp
Last active September 8, 2022 15:30
tweet_char_weight
#include<cstdio>
#include<iostream>
#include<vector>
struct WeightRange{
int start;
int end;
int weight;
WeightRange(int start_, int end_, int weight_) {
start = start_;
const Options = "max_results=100&expansions=author_id&user.fields=name,profile_image_url";
addEventListener("scheduled", event => {
event.waitUntil(handleScheduled(event.request))
})
async function handleScheduled(request) {
await fetchTweets("user-screen-name-here");
}
@tmyt
tmyt / XInput.cs
Last active February 2, 2021 20:00
using System.Runtime.InteropServices;
namespace Interop
{
static class XInput
{
public const int XUserMaxCount = 4;
/**
* <summary>Sets the reporting state of XInput.</summary>
@tmyt
tmyt / UnityHost.cs
Last active September 26, 2019 09:15
public class UnityHost : HwndHost
{
private const uint STARTF_USEPOSITION = 0x0004;
private const uint STARTF_USESIZE = 0x0002;
private Process _childProcess;
private HandleRef _childHandleRef;
public string AppPath { get; set; }
public HandleRef Child => _childHandleRef;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
namespace detect_coreclr_dll
{
class Program
{
using System.Runtime.InteropServices;
using System.Text;
/*
* C#からWindows 10 16299以降で利用できるicuuc.dllを呼び出す定義
*/
namespace icusample.Interop
{
using UBreakIterator = System.IntPtr;
@tmyt
tmyt / generic.xaml
Created May 21, 2018 16:27
windows phone 8.1 - system theme
<?xml version="1.0" encoding="utf-8"?>
<!--
//
// Copyright (c) Microsoft Corporation. All Rights Reserved.
//
-->
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="using:Windows.UI.Xaml.Controls" xmlns:primitives="using:Windows.UI.Xaml.Controls.Primitives"
xmlns:animation="using:Windows.UI.Xaml.Media.Animation" xmlns:maps="using:Windows.UI.Xaml.Controls.Maps">
<!--
#!/bin/bash
# Make symbolic link
userprofile=$(cmd.exe /C set | grep -i '^userprofile=' | cut -d '=' -f 2 | tr '\\' '/' | tr -d ':' | tr -d '[:cntrl:]')
ln -s /mnt/${userprofile,} ~/Profile
ln -s ~/Profile/Documents ~/Documents
ln -s ~/Profile/Downloads ~/Downloads
ln -s ~/Profile/Desktop ~/Desktop
# configure bash