Quantum $frak {gl}_infty$, infinite $q$-Schur algebras and their representations

合集下载

invisibility_of_element用法

invisibility_of_element用法

invisibility_of_element用法元素是网页中不可或缺的重要组成部分,但有时候我们需要将某些元素隐藏起来,比如用于实现动态效果、提高网页性能或者仅仅是为了美观。

本文将介绍几种元素隐藏的使用方法。

一、使用display属性display属性是CSS中控制元素显示方式的属性,它有以下几个值:1. none:将元素隐藏起来,不会占据任何空间。

2. block:将元素显示为块级元素。

3. inline:将元素显示为行内元素。

4. inline-block:将元素显示为行内块级元素。

使用display属性将元素隐藏起来的方法如下:```display: none;```二、使用visibility属性visibility属性是CSS中控制元素可见性的属性,它有以下两个值:1. visible:元素可见。

2. hidden:元素不可见,但仍会占据空间。

使用visibility属性将元素隐藏起来的方法如下:```visibility: hidden;```三、使用opacity属性opacity属性是CSS中控制元素透明度的属性,它的值从0到1之间,其中0表示完全透明,1表示不透明。

使用opacity属性将元素隐藏起来的方法如下:```opacity: 0;```四、使用position属性position属性是CSS中控制元素定位方式的属性,它有以下几个值:1. static:元素按照文档流位置放置。

2. relative:元素相对于其正常位置进行定位。

3. absolute:元素相对于其最近的非static祖先元素进行定位。

4. fixed:元素相对于浏览器窗口进行定位。

使用position属性将元素隐藏起来的方法如下:```position: absolute;left: -9999px;```五、使用z-index属性z-index属性是CSS中控制元素层级的属性,它的值越大,元素显示在越上层。

latex如何添加圆圈数字?

latex如何添加圆圈数字?
⒈⒉⒊ ⒋ ⒌ ⒍ ⒎ ⒏⒐ ⒑ 1F100 2488 2489 248A 248B 248C 248D 248E 248F 2490 2491
⒒⒓⒔ ⒕ ⒖ ⒗ ⒘ ⒙⒚ ⒛ 2492 2493 2494 2495 2496 2497 2498 2499 249A 249B
2492 2493 2494 2495 2496 2497 2498 2499 249A 249B
在主流的 TEX 引擎下,pifont 宏包都可以使用。
Unicode
数字 0–50 的带圈版本都分配了对应的 Unicode 码位,因而在现代 TEX 引擎(X⁠E⁠TEX 和 Lua​TEX,若无特殊说明以下仅讨论这两者)中,配合合适的字体,理论上可以直接输 入这些符号。具体见下表:
①②③④⑤ ⑥ ⑦ ⑧ ⑨ ⑩ 24EA 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469
\TESTi \TESTii \TESTiii
当然,其他样式的带圈数字并没有提供快捷的输入方式。
在 ctex 宏集中使用
以上的案例都是在标准文档类 article 中搭配 fontspec 宏包完成的。如果切换成 ctex 宏集,则需要额外做一些调整。
对于中文文档,我们通常需要为中西文(「西文」主要指 Latin script)分别设置字体。上面已经提到过,带圈数字分散在了几个 Unicode 区块中。xeCJK 将其中的 Enclosed CJK Letters and Months 和 Enclosed Ideographic Supplement 设置为了 CJK 字符类,使用中文字体;其余则为 Default 字符类,使用西文字体。
3280 3281 3282 3283 3284 3285 3286 3287 3288 3289

PyQt5QTextBrowser刷新、上限、查找

PyQt5QTextBrowser刷新、上限、查找

PyQt5QTextBrowser刷新、上限、查找使⽤PyQt5做UI,我⼀直使⽤QTextBrowser作为LOG的输出界⾯。

不知道对不对。

感觉QTextBrowser是⽂本浏览器,就像txt⼀样是查看⽂本的。

字⾯意思吧,好吧,我英⽂不好QTextBrowser刷新上代码def text_browser_show(self, mes):save_str = r"[{}]◆{}".format(datetime.now().strftime('%H:%M:%S.%f')[:-3], mes)with open(LogName, 'a') as src_f:print(save_str, file=src_f)self.textBrowser.append(save_str)my_cursor = self.textBrowser.textCursor()self.textBrowser.moveCursor(my_cursor.End)# sleep(0.05) # 0:00:01.156QtWidgets.QApplication.processEvents(QtCore.QEventLoop.AllEvents)解析with open(LogName, 'a') as src_f:print(save_str, file=src_f)这个代码是⽤于向⽂件中写log的,本意是在想浏览器输出log的同时也将log写⼊⽂件中,如果不需要可忽略self.textBrowser.append(save_str)这段代码就是将mes添加到浏览器中,但是需注意浏览器的光标位置。

append()属于QTextEdit槽函数(也不知道为什么QTextBrowser可以调⽤QTextEdit的槽函数,有可能他们都继承⾄PySide2.QtWidgets.QWidget)append(text)参数类型:text - str注意:The new paragraph appended will have the same character format and block format as the current paragraph, determined by the position of the cursor.将带有⽂本的新段落追加到⽂本编辑的末尾光标影响append()的插⼊位置,所以我们加⼊⽂本后需要将光标移动到指定位置,这⾥移动到⽂末(第⼀次没有⽂本,所以不需要移动)。

BUUCTF逆向1-10题wp

BUUCTF逆向1-10题wp

BUUCTF逆向1-10题wpeasyre载⼊ IDA 就能看到 flagflag{this_Is_a_EaSyRe}reverse1IDA 载⼊,shift+F12 打开字符串窗⼝,找到可能与 flag 有关的字符串双击进⼊按 x 查看引⽤,双击进⼊可以看到其所在的函数的⼀个流程图F5 查看伪代码可以发现,它对我们输⼊的 str1 与程序⾥的 str2 做⽐较,str2 是{hello_world},⽽在开始前会将 str2 中的字母 o 替换为数字 0,于是得到flagflag{hell0_w0rld}reverse2IDA 载⼊,找到 main 函数,F5 查看伪代码可以看到程序将我们输⼊的 s2 与 &flag 进⾏⽐较,查看 &flag&flag 为 "hacking_for_fun}",再往上看有⼀段对 &flag 变换的操作是将其中的 i 和 r 换成 1,于是得到 flagflag{hack1ng_fo1_fun}内涵的软件载⼊ IDA 找到 main0 就能看见 flagflag{49d3c93df25caad81232130f3d2ebfad}新年快乐⽤ exeinfo 查看⼀下发现加了 upx 壳脱壳后载⼊ IDA 找到主函数,F5 查看伪代码,发现它将输⼊内容与 HappyNewYear! 对⽐,得到 flag 了flag{HappyNewYear!}helloword载⼊ IDA 查看 main 函数可以发现⽤户输⼊ __b,并且规定 __b 的长度为 33,然后与⾃⾝的前⼀位异或,再与 global 进⾏⽐较查看 global 的值输⼊的内容进⾏⼀顿异或之后得到 f\nk\fw&O.@\x11x\rZ;U\x11p\x19F\x1Fv"M,其中第⼀个 f 是没有被处理的双击前⾯的 aFKW0XZUPFVMDGH 跳转过去写脚本拿到 flag(脚本来源:套神博客)tmp = ['f', 0x0A, 'k', 0x0C, 'w', '&', 'O', '.', '@', 0x11, 'x', 0x0D, 'Z', ';', 'U', 0x11, 'p', 0x19, 'F', 0x1F, 'v','"', 'M', '#', 'D', 0x0E, 'g', 6, 'h', 0x0F, 'G', '2', 'O']flag = 'f'for i in range(1, len(tmp)):if (isinstance(tmp[i], str)):if (isinstance(tmp[i - 1], str)):flag += chr(ord(tmp[i]) ^ ord(tmp[i - 1]))#如果都是字符串else:#tmp[i]为字符串,tmp[i-1]不是字符串flag += chr(ord(tmp[i]) ^ tmp[i- 1])else:#tmp[i]和tmp[i-1]都不是字符串flag += chr(tmp[i] ^ ord(tmp[i - 1]))print(flag)flag{QianQiuWanDai_YiTongJiangHu}hellowordAndroidkiller 打开,就可以看到 flag 了flag{7631a988259a00816deda84afb29430a}reverse3这题在 bugku 做过,之前写过 wp,传送门:不⼀样的flag拖⼊ IDA,查看 main 函数int __cdecl __noreturn main(int argc, const char **argv, const char **envp){char v3[29]; // [esp+17h] [ebp-35h] BYREFint v4; // [esp+34h] [ebp-18h]int v5; // [esp+38h] [ebp-14h] BYREFint i; // [esp+3Ch] [ebp-10h]_BYTE v7[12]; // [esp+40h] [ebp-Ch] BYREF__main();v4 = 0;strcpy(v3, "*11110100001010000101111#");while ( 1 ){puts("you can choose one action to execute");puts("1 up");puts("2 down");puts("3 left");printf("4 right\n:");scanf("%d", &v5);if ( v5 == 2 ){++*(_DWORD *)&v3[25];}else if ( v5 > 2 ){if ( v5 == 3 ){--v4;}else{if ( v5 != 4 )LABEL_13:exit(1);++v4;{if ( v5 != 1 )goto LABEL_13;--*(_DWORD *)&v3[25];}for ( i = 0; i <= 1; ++i ){if ( *(int *)&v3[4 * i + 25] < 0 || *(int *)&v3[4 * i + 25] > 4 )exit(1);}if ( v7[5 * *(_DWORD *)&v3[25] - 41 + v4] == '1' )exit(1);if ( v7[5 * *(_DWORD *)&v3[25] - 41 + v4] == '#' ){puts("\nok, the order you enter is the flag!");exit(0);}}}看到有⼀串字符串"*11110100001010000101111#",然后有上下左右四个⽅向,再往下看可以发现程序碰到 1 退出,碰到 # 输出 flag,应该是⼀个迷宫,再查看那串字符串的长度正好是 25得到 222441144222flag{222441144222}SimpleRevIDA 载⼊找到主函数输⼊ d 进⼊游戏,跟进函数 Decry()unsigned __int64 Decry(){char v1; // [rsp+Fh] [rbp-51h]int v2; // [rsp+10h] [rbp-50h]int v3; // [rsp+14h] [rbp-4Ch]int i; // [rsp+18h] [rbp-48h]int v5; // [rsp+1Ch] [rbp-44h]char src[8]; // [rsp+20h] [rbp-40h] BYREF__int64 v7; // [rsp+28h] [rbp-38h]int v8; // [rsp+30h] [rbp-30h]__int64 v9[2]; // [rsp+40h] [rbp-20h] BYREFint v10; // [rsp+50h] [rbp-10h]unsigned __int64 v11; // [rsp+58h] [rbp-8h]v11 = __readfsqword(0x28u);*(_QWORD *)src = 'SLCDN';v7 = 0LL;v8 = 0;v9[0] = 'wodah';v9[1] = 0LL;v10 = 0;text = (char *)join(key3, v9);strcpy(key, key1);strcat(key, src);v2 = 0;v3 = 0;getchar();v5 = strlen(key);for ( i = 0; i < v5; ++i ){if ( key[v3 % v5] > 64 && key[v3 % v5] <= 90 )key[i] = key[v3 % v5] + 32;++v3;}printf("Please input your flag:");while ( 1 ){v1 = getchar();if ( v1 == '\n' )break;if ( v1 == ' ' ){++v2;if ( v1 <= '`' || v1 > 'z' ){if ( v1 > '@' && v1 <= 'Z' ){str2[v2] = (v1 - 39 - key[v3 % v5] + 97) % 26 + 97;++v3;}}else{str2[v2] = (v1 - 39 - key[v3 % v5] + 97) % 26 + 97;++v3;}if ( !(v3 % v5) )putchar(32);++v2;}}if ( !strcmp(text, str2) )puts("Congratulation!\n");elseputs("Try again!\n");return __readfsqword(0x28u) ^ v11;}先看这⼀部分其中 text=key3+v9,key3 为 kills,v9 为 wodah,因为是⼩端序存储,所以 text 为 killshadowkey 为 key1+src,key1 为 ADSFK,src 为SLCDN,所以 key 为 ADSFKNDCLS然后看加密过程可以看到上图先将 key 每⼀位 +32,也就是变成了⼩写然后⽤户输⼊,对输⼊内容进⾏操作后储存在 str2 ⾥,最后将 str2 与 text 作⽐较,相同则为 flag于是可以逆向得到脚本#include <bits/stdc++.h>using namespace std;char text[11] = "killshadow";char key[11] = "adsfkndcls";char flag[11] = {0};char str[11] = {0};int main() {for (int i = 0; i < 10; i++)for (int j = 0; j < 128; j++) {if (j < 'A' || j > 'z' || j > 'Z' && j < 'a') continue;if ((j - 39 - key[i] + 97) % 26 + 97 == text[i]) {str[i] = (j - 39 - key[i] + 97) % 26 + 97;flag[i] = j;printf("%s ", flag);printf("%s\n", str);break; //这⾥很重要,原因下⾯说}}printf("flag{%s}\n", flag);return 0;}其实我个⼈认为这题是有问题的,题⽬没有规定输⼊内容必须为⼤写字母,我们上⽂提到的代码之所以能得到正确的 flag 是因为那句关键的break,但是如果将 break 去掉就会出现如下情况可以看到出现了多解的情况,有⼩写字母的 flag 也有⼤⼩写字母混合的 flag,⼗分费解,不知道是不是题⽬本⾝的锅,如有师傅知道原因还请在评论区留⾔交流⼀下flag{KLDQCUDFZO}。

优雅地使用Clion开发双核STM32H747

优雅地使用Clion开发双核STM32H747

优雅地使⽤Clion开发双核STM32H747使⽤ Clion 开发 STM32H747 时,遇到 CubeMX 不能⽣成 CMakeLists ⽂件,导致 Clion ⽆法识别⼯程。

⼀番查找后,在github找到相应的 CMakeLists.txt ⽂件:⽆需做任何修改,添加到根⽬录即可正常编译,Clion可正常识别双核⼯程(见下图)。

更新@2020.12.18:⼀种(据说)更简洁的⽅式,未经验证。

完整版的 CMakeLists.txt 奉上,直接复制粘贴即可。

# CMakeLists.txt for dual-core STM32H7xx MCUs and CLion IDE## DISCLAIMER: Experimental version, based on undocumented assumptions how STM32CubeMX works# DISCLAIMER: THIS FILE IS PROVIDED UNDER "The Unlicense" LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTY OF ANY KIND## Requirements:# Toolchain binaries have to be in system path# STM32CubeMX field "Project Manager | Code Generator | Target IDE" must be set to "STM32CubeIDE"## Tested under environment:# Windows 10# GCC toolchain for ARM Cortex-M V2019q4# STM32CubeMX V6.1.0# STM32CubeH7 Firmware Package V1.8.0# CLion 2020.3# NUCLEO-H745ZI-Q MCU board## How To Use:# 1. Set up CLion according to https:///help/clion/2020.3/embedded-overview.html#build-system# 2. Create a project using STM32CubeMX for dual-core STM32H7xx MCU, set "Target IDE" as STM32CubeIDE, and click GENERATE CODE # 3. Place this file into the project root folder# 4. Set relevant project name as 'project' clause 1st argument# 5. Open the project root folder as CLion project "File | Open..."## Written by ilia.motornyi[%]#cmake_minimum_required(VERSION 3.17)# Cross compilers and toolsset(CMAKE_SYSTEM_NAME Generic)set(CMAKE_SYSTEM_VERSION 1)set(CMAKE_C_COMPILER arm-none-eabi-gcc)set(CMAKE_CXX_COMPILER arm-none-eabi-g++)set(CMAKE_ASM_COMPILER arm-none-eabi-gcc)set(CMAKE_AR arm-none-eabi-ar)set(CMAKE_OBJCOPY arm-none-eabi-objcopy)set(CMAKE_OBJDUMP arm-none-eabi-objdump)set(SIZE arm-none-eabi-size)set(CMAKE_TRY_COMPILE_TARGET_TYPE STATIC_LIBRARY)# Project settings.project(h7-single-cmake #[[TODO set reasonable project name]] C CXX ASM)# Common compile settings# Language standardset(CMAKE_CXX_STANDARD 17)set(CMAKE_C_STANDARD 11)# Generic compiler settingsadd_compile_options(-mthumb -mthumb-interwork)add_compile_options(-ffunction-sections -fdata-sections -fno-common -fmessage-length=0)add_link_options(-mthumb -mthumb-interwork)add_link_options(-Wl,-gc-sections,--print-memory-usage)# Build typesif ("${CMAKE_BUILD_TYPE}" STREQUAL "Release")message(STATUS "Maximum optimization for speed")add_compile_options(-Ofast)elseif ("${CMAKE_BUILD_TYPE}" STREQUAL "RelWithDebInfo")message(STATUS "Maximum optimization for speed, debug info included")add_compile_options(-Ofast -g)elseif ("${CMAKE_BUILD_TYPE}" STREQUAL "MinSizeRel")message(STATUS "Maximum optimization for size")add_compile_options(-Os)else ()message(STATUS "Minimal optimization, debug info included")add_compile_definitions(DEBUG)add_compile_options(-Og -g3)endif ()# Enable hardware FPUadd_compile_options(-mfloat-abi=hard -mfpu=fpv4-sp-d16)add_link_options(-mfloat-abi=hard -mfpu=fpv4-sp-d16)add_compile_definitions(ARM_MATH_CM4;ARM_MATH_MATRIX_CHECK;ARM_MATH_ROUNDING)# Uncomment to mitigate c++17 register variable warnings#add_compile_options($<$<COMPILE_LANGUAGE:CXX>:-Wno-register>)# End of common part# Detect linker scripts. Priorities: *_USER.ld, if not found *_FLASH.ld, if not found first *.ldforeach (KRNL CM4 CM7)file(GLOB LINKER_SCRIPTS "${KRNL}/*_USER.ld")if (NOT LINKER_SCRIPTS)file(GLOB LINKER_SCRIPTS "${KRNL}/*_FLASH.ld")if (NOT LINKER_SCRIPTS)file(GLOB LINKER_SCRIPTS "${KRNL}/*.ld")endif ()endif ()list(GET LINKER_SCRIPTS 0 LINKER_SCRIPT_${KRNL})message(STATUS "Detected Linker Script for ${KRNL}: ${LINKER_SCRIPT_${KRNL}}")endforeach ()# Kernel-specific sources# Cortex-M4file(GLOB_RECURSE CM4_SRC "CM4/*.*" "Common/*.*")add_executable(${PROJECT_NAME}_CM4.elf ${LINKER_SCRIPT_CM4} ${CM4_SRC})# Cortex-M7file(GLOB_RECURSE CM7_SRC "CM7/*.*" "Common/*.*")add_executable(${PROJECT_NAME}_CM7.elf ${LINKER_SCRIPT_CM7} ${CM7_SRC})# Kernel-specific build settingstarget_compile_options(${PROJECT_NAME}_CM4.elf PRIVATE -mcpu=cortex-m4)target_compile_options(${PROJECT_NAME}_CM7.elf PRIVATE -mcpu=cortex-m7)target_link_options(${PROJECT_NAME}_CM4.elf PRIVATE -Wl,-Map=${PROJECT_BINARY_DIR}/${PROJECT_NAME}_CM4.map -mcpu=cortex-m4 -T ${LINKER_SCRIPT_CM4}) target_link_options(${PROJECT_NAME}_CM7.elf PRIVATE -Wl,-Map=${PROJECT_BINARY_DIR}/${PROJECT_NAME}_CM7.map -mcpu=cortex-m7 -T ${LINKER_SCRIPT_CM7}) # Custom commands to build .hex filesforeach (KRNL CM4 CM7)set(HEX_NAME ${PROJECT_NAME}_${KRNL}.hex)set(HEX_FILE ${PROJECT_BINARY_DIR}/${HEX_NAME})add_custom_command(TARGET ${PROJECT_NAME}_${KRNL}.elf POST_BUILDCOMMAND ${CMAKE_OBJCOPY} -Oihex $<TARGET_FILE:${PROJECT_NAME}_${KRNL}.elf> ${HEX_FILE}BYPRODUCTS ${HEX_FILE}COMMENT "Building ${HEX_NAME}")endforeach ()# Read kernel-specific header paths, defines, and sources from ".mxproject"file(STRINGS .mxproject LINES)foreach (LINE ${LINES})if (LINE MATCHES "\\[Cortex(M4|M7):(PreviousUsedCubeIDEFiles|PreviousLibFiles)\\]") #Detect relevant groupset(CUBE_PRJ_GROUP "C${CMAKE_MATCH_1}")elseif (LINE MATCHES "^\\[.*\\]$") #Detect non-relevant groupsunset(CUBE_PRJ_GROUP)elseif (CUBE_PRJ_GROUP)if (LINE MATCHES "^\\s*CDefines=\\s*(.*)") #Detect definestarget_compile_definitions(${PROJECT_NAME}_${CUBE_PRJ_GROUP}.elf PRIVATE ${CMAKE_MATCH_1})elseif (LINE MATCHES "^\\s*HeaderPath=\\s*(.*)\\s*") #Detect header pathsstring(REGEX MATCHALL "[^;]+" INCL_LIST "${CMAKE_MATCH_1}")target_include_directories(${PROJECT_NAME}_${CUBE_PRJ_GROUP}.elf PRIVATE ${INCL_LIST})elseif (LINE MATCHES "^\\s*LibFiles=\\s*(.*)\\s*") #Detect library sourcesstring(REGEX MATCHALL "[^;]+" SRC_LIST "${CMAKE_MATCH_1}")foreach (SRC_FILE ${SRC_LIST})if (EXISTS "${CMAKE_SOURCE_DIR}/${SRC_FILE}")target_sources(${PROJECT_NAME}_${CUBE_PRJ_GROUP}.elf PRIVATE ${SRC_FILE})endif ()endforeach ()endif ()endif ()endforeach ()。

【无限滚动加载数据】—infinite-scroll插件的使用

【无限滚动加载数据】—infinite-scroll插件的使用

【⽆限滚动加载数据】—infinite-scroll插件的使⽤⽹上对于infinite-scroll插件使⽤的例⼦不多。

但由于它的出现,⿎吹了瀑布流形式的页⾯展⽰⽅式,所以不得不了解了解这种新的分页⽅式。

上有对infinite-scroll的详细描述,但⼀般⼈即使看未必看得懂,看得懂未必就调试成功。

所以借今晚有点时间,把跑通的例⼦供⼤家借鉴。

⼀.⽆限滚动概念⾸先,它是基于Jquery的,另外还要明⽩⽆限滚动的概念:⽆限滚动的实现原理就是当你在⽹页上的滚动条滚动到离⽹页底部⼀定长度的时候,触发某ajax函数(infinite-scroll内已经封装好),往后台加载⽂件或者数据,⼜或者从外部引⼊静态html形式⽂件。

⼆.探讨infinite-scroll1.从⽹页头引⼊两个js⽂件,注意必须先放jquery的[javascript]1. <script src="css/infinite-scroll/jquery-1.6.4.js"></script>2. <script src="css/infinite-scroll/jquery.infinitescroll.js"></script>2.之后在⽹页头⾃⼰写⼀个js脚本[javascript]1. <script>2. $(document).ready(function (){3. $("#container").infinitescroll({4. navSelector: "#navigation", //页⾯分页元素--本页的导航,意思就是⼀个可以触发ajax函数的模块5. nextSelector: "#navigation a", //下⼀页的导航6. itemSelector: ".scroll " , //此处我⽤了类选择器,选择的是你要加载的那⼀个块(每次载⼊的数据放的地⽅)7. animate: true, //加载时候时候需要动画,默认是false8. maxPage: 3, //最⼤的页数,也就是滚动多少次停。

键盘幽灵程序源代码

键盘幽灵程序源代码对于全局钩⼦的使⽤常见的说法是把钩⼦函数放到.dll⽂件中,包括版的⼀篇VC5.0的⽂章以及《计算机世界》2000.10.19B11技巧版“⽤VC++ 编写钩⼦程序”。

但在BO2K中,击键记录线程调⽤⽇志钩⼦明显不是从dll ⽂件来的,实际上BO2K Server 端已经不需要dll程序配合了。

我把BO2K中击键记录的⽇志钩⼦函数单独提出来,构造了⼀个只有24k ⼤的键盘幽灵GetKey.exe,在win9x 下以隐藏⽅式运⾏,⽤户的所有击键记录在与可执⾏⽂件相同⽬录下的隐藏⽂件keyfile.txt 中,按Ctrl+x中⽌键盘幽灵程序的运⾏。

如果想在Win2k下运⾏,需要去掉源代码中关于win9x隐藏进程的部分,重新编译: /download/GetKey.zip ⽐较奇怪的是⽤户在win9x下运⾏后,Dos 窗⼝内的击键⽆法记录。

Win2k中运⾏cmd.exe则可以记录。

朋友的⼀种解释是win9x下 中的击键不是以消息形式发送,是更底层的实现。

下⾯仿照《计算机世界》2000.10.19B11技巧版“⽤VC++编写钩⼦程序” 的格式给出键盘幽灵的编写⽅法: 1、在VC++6.0中利⽤MFC APPWizard(EXE)⽣成⼀个不使⽤⽂档/视图⽀持的单⽂档应⽤GetKey。

打开MainFrm.cpp⽂件。

加⼊全局变量和函数的说明。

HHOOK g_hHook = NULL; //全局钩⼦函数句柄HANDLE g_hCapFile = NULL; //⽂本⽂件句柄 HWND g_hGetKeyWindow = NULL; //主程序窗体句柄HWND g_hLastFocus = NULL; //活动窗体句柄 int nScanValue[1]; //⽤来保存前两次被按键的nScan值 //---------only win9x hide process---------------------------------------------// HMODULE g_hModuleOfKernel = NULL; //kernel32.dll的句柄typedef DWORD (WINAPI *REGSERVICEPROC)(DWORD dwProcessId, DWORD dwServiceType);REGSERVICEPROC pRegisterServiceProcess; //-----------------------------------------------------------------------------// //这个⽇志钩⼦函数基本来⾃BO2K. LRESULT CALLBACK KeyboardProc(int nCode,WPARAM wParam,LPARAM lParam) {if(nCode〈0) return CallNextHookEx(g_hHook,nCode,wParam,lParam); if(nCode==HC_ACTION) { //HC_ACTION表明lParam指向⼀消息结构EVENTMSG *pEvt=(EVENTMSG *)lParam; if(pEvt-〉message==WM_KEYDOWN) { //判断是否是击键消息 DWORD dwCount,dwBytes;char svBuffer[256]; int vKey,nScan; vKey=LOBYTE(pEvt-〉paramL); nScan=HIBYTE(pEvt-〉paramL); nScan〈〈=16;// Check to see if focus has changed HWND hFocus=GetActiveWindow(); if(g_hLastFocus!=hFocus) { //如果本次击键发⽣窗⼝同上次击键发⽣窗⼝同则保存窗⼝标题到⽂件中; char svTitle[256]; int nCount; nCount=GetWindowText(hFocus,svTitle,256); if(nCount〉0) { char svBuffer[512];wsprintf(svBuffer,"\r\n-----[ %s ]-----\r\n",svTitle); WriteFile(g_hCapFile,svBuffer,lstrlen(svBuffer),&dwBytes,NULL); } g_hLastFocus=hFocus; }// Write out key dwCount=GetKeyNameText(nScan,svBuffer,256); if(dwCount) { //如果所击键在虚拟键表之中 if(vKey==VK_SPACE) {svBuffer[0]=' '; svBuffer[1]='\0'; dwCount=1; } if(dwCount==1) { //如果是普通键则将其对应的ascii码存⼊⽂件 BYTE kbuf[256]; WORD ch; int chcount; GetKeyboardState(kbuf); // if u press CTRL,the nScan is 1900554.and ALT is 367000,Del is 5439488.if ((nScanValue[1] == 1900544) && (vKey == 88)) { //如果按Ctrl+x则主程序退出,可改变⽐较值来更换热键,如vKey == 89则变为Ctrl+y。

Python+`decimal`模块中的特殊值处理:Infinity与NaN

Python `decimal`模块中的特殊值处理:Infinity与NaN在Python的decimal模块中,处理无限大(Infinity)和非数字(NaN,即“Not a Number”)的情况是通过特殊的Decimal实例来表示的。

这些特殊值在需要进行浮点数运算但又可能遇到未定义或极端情况时非常有用。

无限大(Infinity)无限大可以通过Decimal类的Infinity属性来表示。

这个值可以是正无穷大或负无穷大,分别通过Decimal('Infinity')和Decimal('-Infinity')来创建。

无限大值在比较和运算中表现得就像它们在数学中一样。

例如,任何正数加上正无穷大都等于正无穷大,任何负数减去正无穷大都等于负无穷大,而任何数与无穷大进行除法(非零除数)的结果都是无穷大(或零,如果除数是无穷大且同号)。

非数字(NaN)非数字(NaN)可以通过Decimal类的NaN属性或特殊构造方法(尽管Decimal.NaN更常见)来表示。

NaN是一个特殊值,用于表示未定义或不可表示的结果。

在IEEE浮点数标准中,NaN用于表示某些无效运算的结果,如0.0除以0.0。

在decimal模块中,NaN同样用于这种目的。

NaN与任何值(包括它自身)的比较都会返回False,这反映了NaN的“非比较性”属性。

使用示例from decimal import Decimal, Infinity, NaN# 无限大pos_inf = Decimal('Infinity')neg_inf = Decimal('-Infinity')print(pos_inf + 10) # 输出:Infinityprint(neg_inf - 10) # 输出:-Infinityprint(pos_inf > 100) # 输出:Trueprint(neg_inf < 0) # 输出:True# 非数字nan = Decimal('NaN')print(nan == nan) # 输出:False,因为NaN不等于自身print(nan + 10) # 输出:NaN,因为NaN参与的运算结果仍为NaN 注意事项●在使用NaN时,需要特别小心,因为它与任何值的比较(包括它自身)都会返回False。

超简单无缝滚动漂浮广告代码属性

超简单⽆缝滚动漂浮⼴告代码属性实现功能:1、⽆缝滚动(左右上下)2、漂浮⼴告(包括在屏幕漂浮⼏次消失)两个事件onmouseover="this.stop()" ⿏标划过停⽌滚动onmouseout="this.start()" ⿏标离开继续滚动<marquee width="920" onmouseover="this.stop()" onmouseout="this.start()" scrollamount="20" behavior="scroll" align="absbottom"> @foreach (var item in Model.NewsItems_WebNotice){<u><a href="@Url.RouteUrl("NewsItem", new { SeName = item.SeName })">@Html.StrTruncation(item.Title, 10)</a></u>}</marquee>Marquee 属性列表:align设定<marquee>标签内容的对齐⽅式absbottom:绝对底部对齐(与g、p等字母的最下端对齐)absmiddle:绝对中央对齐baseline:底线对齐bottom:底部对齐(默认)left:左对齐middle:中间对齐right:右对齐texttop:顶线对齐top:顶部对齐behavior设定滚动的⽅式:alternate:表⽰在两端之间来回滚动。

scroll:表⽰由⼀端滚动到另⼀端,会重复。

slide:表⽰由⼀端滚动到另⼀端,不会重复scrollamount="5":设置滚动的速度direction设定活动字幕的滚动⽅向代码如下:<marquee direction="down">设定活动字幕的滚动⽅向direction="down":向下</marquee><marquee direction="left">设定活动字幕的滚动⽅向direction="left":向左</marquee><marquee direction="right">设定活动字幕的滚动⽅向direction="right":向右</marquee><marquee direction="up">设定活动字幕的滚动⽅向direction="up":向上</marquee>hspace设定活动字幕⾥所在的位置距离⽗容器⽔平边框的距离This controls the horizontal(⽔平)space around thedisplay box.代码如下:<table width="500"border="1" align="center" cellpadding="0"cellspacing="0"><tr><td><marquee hspace="100"bgcolor="#CCCCCC">hspace="100"</marquee></td></tr></table>loop设定滚动的次数,当loop=-1表⽰⼀直滚动下去,默认为-1Marquee标记⽤于在可⽤浏览区域中滚动⽂本。

QT界面美化之flag应用

QT界面美化之flag应用2015-02-11 第一版微信jpzy01整理- 设置程序界面风格在main函数中QApplication::setStyle("windows");QApplication::setStyle("windowsxp");QApplication::setStyle("motif");QApplication::setStyle("cde");QApplication::setStyle("macintosh");QApplication::setStyle("plastique");风格可以是"windows", "motif", "cde", "plastique", "windowsxp", "macintosh" - 设置窗口样式setWindowFlags(flags)flags:Qt::WindowContextHelpButtonHintQt::FramelessWindowHint // 去掉标题栏Qt::CustomizeWindowHintQt::WindowTitleHint // 只有标题栏,没有窗口控制按钮Qt::WindowSystemMenuHintQt::WindowCloseButtonHintQt::WindowMaximizeButtonHintQt::WindowMinimizeButtonHintQt::SubWindowQt::DesktopQt::SplashScreenQt::ToolTipQt::Tool// 没有标题栏图标、没有任何按钮,只有标题Qt::CustomizeWindowHint | Qt::WindowTitleHint用法一:clientMainWindow::clientMainWindow(QWidget *parent) :QMainWindow(parent, Qt::WindowCloseButtonHint){...}用法二:clientMainWindow::clientMainWindow(QWidget *parent) :QMainWindow(parent ){...this-<setWindowFlags(Qt::WindowCloseButtonHint);...}- 窗口在屏幕居中显示#include方法一:w.move((QApplication::desktop()-<width() - w.width()) / 2,(QApplication::desktop()-<height() - w.height()) / 2);方法二:QDesktopWidget *desktop = QApplication::desktop(); // = qApp-<desktop() 也可以w.move((desktop-<width() - this-<width()) / 2, (desktop-<height() - this-<height()) / 2);注:w 为Qt窗口对象(如QMainWindow、QDialog等)- 修改UI程序在桌面的起始位置在程序中加入如下代码即可:w.move(x, y); // 屏幕左上角为(0, 0),x、y为相对于(0, 0)的偏移值// w为Qt窗口对象(可以是QMainWindow、QDialog等)- 去掉标题栏左侧的图标1. 创建透明图标使用PhotoShop创建一个透明的图标参考设置:大小:1 X 1 px名称:logo.png2. 添加图标到工程1) 在工程目录下创建“res”目录,将logo.png拷贝到此目录2) 在工程中添加一个资源文件,命名为“icon.qrc”3) 在icon.qrc中添加一个前缀(此处为“res”),在该前缀下添加一个文件,把logo.png添加进来4) 为logo.png设置别名(此处把别名设为与文件名相同,即“logo.png”)注意:在工程中调用时使用的是别名。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
QUANTUM gl∞ , INFINITE q -SCHUR ALGEBRAS AND THEIR REPRESENTATIONS
arXiv:0708.2525v1 [math.QA] 19 Aug 2007
JIE DU AND QIANG FU Abstract. In this paper, we investigate the structure and representations of the quantum group U(∞) = Uυ (gl∞ ). We will present a realization for U(∞), following Beilinson–Lusztig–MacPherson (BLM) [1], and show that the natural algebra homomorphism ζr from U(∞) to the infinite q -Schur algebra S (∞, r ) is not surjective for any r 1. We will give a BLM type realization for the image U(∞, r ) := ζr (U(∞)) and discuss its presentation in terms of generators and relations. We further b † (∞) so that ζr can be extended to an algebra epimorphism construct a certain completion algebra K e b† ζ r : K (∞) → S (∞, r ). Finally we will investigate the representation theory of U(∞), especially the polynomial representations of U(∞).
1
பைடு நூலகம் 2
JIE DU AND QIANG FU
K(∞) contains a subalgebra V(∞) which is isomorphic to U(∞). Second, there is a algebra homomorphism ξr : V(∞) → K(∞, r ) with image V(∞, r ). The elementary structure of V(∞, r ) is investigated in §5, and a presentation for V(∞, r ) will be given in §6. In §7, we will establish † isomorphisms S (∞, r ) ∼ = K (∞, r ) and between V(∞, r ) and the homomorphic image U(∞, r ) of the natural homomorphism ζr : U(∞) → S (∞, r ). Thus, we conclude that ζr is not surjective ˙ (∞), we derive an for any r 1. In §8, by identifying K(∞) with the modified quantum group U algebra epimorphism ζ˙r : K(∞) → K(∞, r ) and hence, extend the map ζr to an epimorphism from K (∞) to S (∞, r ). In the last three sections, we investigate the representation theory of U(∞). The highest weight representations of U(∞) is studied in §9, and the polynomial representations of U(∞) is in §11 as an application of the representation theory of S (∞, r ) investigated in §10. Throughout the paper, we will encounter several (associative) algebras A over a commutative ring R without the identity element, but with many orthogonal idempotents ei , i ∈ I, such that A = ⊕i,i′ ∈I ei Aei′ and, for all i, i′ ∈ I , ei Aei′ are free over R. Clearly, the index set I must be an infinite set, since if I was a finite set, then i∈I ei would be the identity element of A. Choose an R-basis B = {aj }j ∈J such that ei B ei′ = {ei aj ei′ }j ∈J \{0} is a basis for ei Aei′ for all i, i′ ∈ I , and B = ∪i,i′ ei B ei′ . We further assume that ei ∈ B for all i ∈ I . It is clear that, for any j ∈ J , there exist unique ij , i′ j ∈ I such that eij aj = aj and aj ei′ = aj . We will write ro(j ) := ij and co(j ) := i′ j for all j ∈ J . For a formal infinite linear combination f =
Date : February 1, 2008. Supported by the Australian Research Council (Grant: DP 0665124) and partially by the National Natural Science Foundation of China (10601037 & 10671142). The paper was written while the second author was visiting the University of New South Wales.
Dedicated to Professor Leonard L. Scott on the occasion of his 65th birthday 1. Introduction The Lie algebra gl∞ of infinite matrices and its extension A∞ are interesting topics in the theory of infinite dimensional Lie algebras. Certain highest weight representations of these algebras have important applications in finding solutions of a large class of nonlinear equations (see, e.g., [3]) and in the representations theories of Heisenberg algebras, the Virasoro algebra and other KacMoody algebras (see, e.g., [17, 18, 27, 28]). The quantum versions of the corresponding universal enveloping algebras have also been studied in [20, 29, 30]. It should be noted that the structure and representations of quantum gl∞ have various connections with the study of Lie superalgebras gl(m|n) (see, e.g., [2]) and the study of quantum affine gln (see [14, §6] and [26, §2]). In this paper, we will investigate the quantum group U(∞) = Uv (gl∞ ) and its representations through a series of its quotient algebras U(∞, r ) and the infinite quantum Schur algebras S (∞, r ). The main idea is to extend the approach developed in [1] for quantum gln to quantum gl∞ . Thus, we obtain a realization for U(∞) and an explicit description of the algebra homomorphism ζr : U(∞) → U(∞, r ). This in turn gives rise to a presentation and various useful bases for U(∞, r ). We will also prove that U(∞, r ) is a proper subalgebra of S (∞, r ). This fact shows that the classical Schur–Weyl duality fails in this case. Finally, we investigate the ‘polynomial’ representation theory and classify all irreducible polynomial representations for U(∞). We expect that this work will have further applications to quantum affine gln . We organize the paper as follows. We start in §1 with a general construction of two completion algebras A and A† for certain algebras A. We recall the definition of quantum glη and q -Schur algebras S (η, r ) at any consecutive segment η of Z in §2. In §3, we use the η -step flag variety to define the algebra K(η, r ) and discuss its stabilization property and triangular relations developed in [1] in a context suitable for infinite η . From §4 onwards, we will focus on the infinite case η = Z. First, the stabilization property allows us to define an algebra K(∞) over Q(υ ) whose completion
相关文档
最新文档