line

Force JList to NOT wrap at all?

我是研究僧i 提交于 2020-04-14 13:07:30
问题 Is there a possibility to force JLists to display all items on one line? setOrientationLayout() does not give you that option. 回答1: list.setLayoutOrientation(JList.HORIZONTAL_WRAP); list.setVisibleRowCount(1); 来源: https://stackoverflow.com/questions/7144689/force-jlist-to-not-wrap-at-all

GLSL Geometry shader to replace glLineWidth

喜欢而已 提交于 2020-04-14 04:11:48
问题 I'm trying to write a geometry shader to replace glLineWidth behavior. I want to draw lines with a customizable width (doing this with a uniform suffices for now). The lines should always have the same thickness, regardless of the camera projection or distance to where the lines are. Based on a lot of googling, I've come up with the following geometry shader: #version 330 layout (lines) in; layout (triangle_strip, max_vertices = 4) out; uniform mat4 u_model_matrix; uniform mat4 u_view_matrix;

GLSL Geometry shader to replace glLineWidth

拜拜、爱过 提交于 2020-04-14 04:09:17
问题 I'm trying to write a geometry shader to replace glLineWidth behavior. I want to draw lines with a customizable width (doing this with a uniform suffices for now). The lines should always have the same thickness, regardless of the camera projection or distance to where the lines are. Based on a lot of googling, I've come up with the following geometry shader: #version 330 layout (lines) in; layout (triangle_strip, max_vertices = 4) out; uniform mat4 u_model_matrix; uniform mat4 u_view_matrix;

oracle 使用sqlplus

跟風遠走 提交于 2020-04-07 05:56:00
A Using SQL Command Line This section provides an introduction to SQL Command Line (SQL*Plus), an interactive and batch command-line query tool that is installed with Oracle Database Express Edition. This section contains the following topics: Overview of SQL Command Line Using SQL Command Line For information about running SQL language statements, see Chapter 3, "Using SQL" . See Also: SQL*Plus User's Guide and Reference for complete information about SQL*Plus Oracle Database SQL Reference for information about using SQL statements Oracle Database Express Edition 2 Day DBA for information

json格式不对引起的报错

你说的曾经没有我的故事 提交于 2020-04-04 04:27:19
报JSONDecondeError这种类型的错误的时候就要检查下json格式是否是正确的了,这里提供一个http://www.bejson.com/ Traceback (most recent call last): File "D:/python开发代码/Python之路/作业/New_Credit_Shopping/core/login.py", line 27, in <module> menu.menushow(current_user) #调用显示菜单 File "D:\python开发代码\Python之路\作业\New_Credit_Shopping\modules\menu.py", line 34, in menushow shopping.PayShopping(current_user) File "D:\python开发代码\Python之路\作业\New_Credit_Shopping\modules\shopping.py", line 78, in PayShopping Credit_info = json.loads(credit_file.read()) File "C:\python3.5\lib\json\__init__.py", line 319, in loads return _default_decoder.decode(s)

sed 命令详解

ぃ、小莉子 提交于 2020-04-03 22:14:55
sed是一种流编辑器,它是文本处理中非常中的工具,能够完美的配合正则表达式使用,功能不同凡响。处理时,把当前处理的行存储在临时缓冲区中,称为“模式空间”(pattern space),接着用sed命令处理缓冲区中的内容,处理完成后,把缓冲区的内容送往屏幕。接着处理下一行,这样不断重复,直到文件末尾。文件内容并没有 改变,除非你使用重定向存储输出。Sed主要用来自动编辑一个或多个文件;简化对文件的反复操作;编写转换程序等。 sed的选项、命令、替换标记 命令格式 sed [options] 'command' file(s) sed [options] -f scriptfile file(s) 选项 -e<script>或--expression=<script>:以选项中的指定的script来处理输入的文本文件; -f<script文件>或--file=<script文件>:以选项中指定的script文件来处理输入的文本文件; -h或--help:显示帮助; -n或--quiet或——silent:仅显示script处理后的结果; -V或--version:显示版本信息。 参数 文件:指定待处理的文本文件列表。 sed命令 a\ 在当前行下面插入文本。 i\ 在当前行上面插入文本。 c\ 把选定的行改为新的文本。 d 删除,删除选择的行。 D 删除模板块的第一行。 s

VIM使用技巧1

ぃ、小莉子 提交于 2020-04-03 01:24:21
.命令是vim中很重要的一个命令,用法如下: 加入有一个文件vimtest.txt,内容如下: 1 Line one 2 Line two 3 Line thredd 4 Line four 5 Line five (1)当光标在第一行的L上时,使用x就会删除L,使用.就会重复刚才的命令,结果就是重复删除一个字符,须要多次删除,就多按几次.即可 (2)当光标在第一行的L上时,使用dd就会删除当前行,使用.就会重复刚才的命令,结果就是重复删除当前行也就是Line two,须要多行删除,就多按几次.即可 (3)当光标在第一行的L上时,使用>G就会把当前行进行层级缩进,使用.就会重复刚才的命令,结果就是重复缩进当前行,须要多行缩进,就多按几次.即可,结合j和k就可以改变行的缩进 (4)从进入插入模式器,直到按<Esc>结束,都可以算作是.的一个周期,充分利用.就可以完成各种重复动作 来源: https://www.cnblogs.com/guochaoxxl/p/6823200.html

Router配置

半腔热情 提交于 2020-03-27 17:44:27
1.Router配置 各模式切换简要命令 1 为enable配置密码 Reter(config)# enable password ******   ·设置明文密码 Reter(config)# enable secret ******    设置密文密码 Reter(config)# login 是密码生效 2 为consolo设置密码 2.1   Reter(config)# line consolo o   进去 consolo 接口   Reter(config-line)# password ******   Reter(config-line)#login   使密码生效   2.2 设置用户名密码 Reter(config)#username *** password ****** Reter(config)# line consolo o 进去 consolo 接口 Reter(config-linel)# login local 以本地用户名密码登录 来源: https://www.cnblogs.com/jokejie/p/12582588.html

解决pip下载超时

陌路散爱 提交于 2020-03-26 13:58:41
pip._vendor.requests.packages.urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Read timed out. Collecting tensorflow==1.2.1 Downloading https://files.pythonhosted.org/packages/e1/18/23a447f822daba3101d84f981d10f5eacd0ccd9a541bd4d2525eec0cba81/tensorflow-1.2.1-cp36-cp36m-win_amd64.whl (21.2MB) Exception: Traceback (most recent call last): File "E:\python_workplace\venv\lib\site-packages\pip\_vendor\requests\packages\urllib3\response.py", line 232, in _error_catcher yield File "E:\python_workplace\venv\lib\site-packages\pip\_vendor\requests

Linux sed进阶

帅比萌擦擦* 提交于 2020-03-26 09:18:15
一、多行命令 在使用sed编辑器的基本命令时,所有的sed编辑器命令都是对单行数据执行操作。sed编辑器也可以对多行数据进行处理,包含了3个可用来处理多行文本的特殊命令。 1》N:将数据流中的下一行加进来创建一个多行组来处理。 2》D:删除多行组中的一行。 3》P:打印钓竿组中的一行。 1.单选的next命令 小写n命令会告诉sed编辑器移动到数据流下一文本行,而不用重新回到命令的最开始再执行一遍。通常sed编辑器会在移动到数据流中的下一文本行前,在这行上执行所有定义好的命令。 $ cat data4 This is the header line This is data line This is the last line $ sed '/header/{n;d}' data4 This is the header line This is data line This is the last line 2.合并文本行 单行next命令会将数据流中的下一文本行移动到sed编辑器的工作空间(称为模式空间)。多行版本的next命令(用大写N)会将下一文本行加到已经在模式空间中的文本上。 这样的作用是将数据流中的两个文本行合并到同一个模式空间。文本行仍然用换行符分隔,但sed编辑器现在会将两行文本当成一行来处理。 $ cat data2 line1 line2 line3 line4