This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Test code with footprint, cause the coordinates of {4000,3000} is used | |
//to give a proper position on footprint editor. | |
//Create text. | |
api('createShape', {"shapeType": "TEXT",jsonCache:{text:"HELLO", height:50, layerid:1, "line-width":12, x: 4200, y:3000}}); | |
//Create pad. Very practical. tested on footprint. | |
api('createShape', {"shapeType": "PAD", jsonCache:{ | |
number:1, | |
shape:"ELLIPSE", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <windows.h> | |
#include <iostream> | |
int main() | |
{ | |
CONSOLE_SCREEN_BUFFER_INFO info; | |
HANDLE hdl = GetStdHandle(STD_OUTPUT_HANDLE); | |
GetConsoleScreenBufferInfo(hdl, &info); | |
WORD wBackgroundColor = info.wAttributes & (BACKGROUND_RED | BACKGROUND_GREEN | BACKGROUND_BLUE | BACKGROUND_INTENSITY ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <psapi.h> | |
#include <windows.h> | |
#ifdef _WIN32 | |
int checkIsWinTerm() | |
{ | |
HWND hConsoleWnd = GetConsoleWindow(); | |
DWORD dwConsolePid; | |
GetWindowThreadProcessId(hConsoleWnd, &dwConsolePid); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Update note: Linux kernel commit feb627e8d6f69c9a319fe279710959efb3eba873 | |
breaks this patch and will need to be reverted in order for this to work on | |
kernels starting with 5.16. | |
From 28e67537895c4b46b9721f19609ee4f2ccb8c132 Mon Sep 17 00:00:00 2001 | |
From: pi <secret@hidden.mail> | |
Date: Sat, 7 Nov 2020 18:41:42 +0100 | |
Subject: [PATCH] Add 'hide-hypervisor' QMP command | |
CAUTION: Extremely hacky stuff below. Use at own risk of bugs, breakage and |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Build an client that doesn't follow redirect | |
val okhttpNoRedirect = okhttp.newBuilder() | |
.followRedirects(false) | |
.build() | |
if (!verifyUserCredentials()) { | |
state._loginState.value = LoginState.NoSessionData | |
return | |
} | |
state._loginState.value = LoginState.LoggingIn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## | |
## This file is part of the libsigrokdecode project. | |
## | |
## Copyright (C) 2012-2013 Uwe Hermann <uwe@hermann-uwe.de> | |
## Copyright (C) 2019 Stephan Thiele <stephan.thiele@mailbox.org> | |
## Copyright (C) 2023 DreamSourceLab <support@dreamsourcelab.com> | |
## | |
## This program is free software; you can redistribute it and/or modify | |
## it under the terms of the GNU General Public License as published by | |
## the Free Software Foundation; either version 2 of the License, or |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct header { | |
u8 initial, format, version; | |
u8 literal[6]; | |
u32 intdata; | |
float floatdata; | |
u8 lintsize, insnsize, numbersize, intsize, | |
ptrsize; | |
}; | |
struct undump { |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <std/core.pat> | |
struct fc_pattern_index_entry_channel { | |
u8 pattern_id; | |
u8 transpose; | |
u8 sound_transpose; | |
}; | |
struct fc_pattern_index_entry { |