Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Aayush
purr-data
Commits
70541308
Commit
70541308
authored
Sep 07, 2014
by
Ivica Bukvic
Browse files
*added ability to copy and paste endlines inside texted for objects
parent
de1ce9ab
Changes
2
Hide whitespace changes
Inline
Side-by-side
pd/src/g_rtext.c
View file @
70541308
...
...
@@ -558,7 +558,7 @@ void rtext_key(t_rtext *x, int keynum, t_symbol *keysym)
if
(
keynum
)
{
int
n
=
keynum
;
if
(
n
==
'\r'
)
n
=
'\n'
;
if
(
n
==
'\r'
||
n
==
'\v'
)
n
=
'\n'
;
if
(
n
==
'\b'
)
/* backspace */
{
if
(
x
->
x_selstart
&&
(
x
->
x_selstart
==
x
->
x_selend
))
...
...
pd/src/pd.tk
View file @
70541308
...
...
@@ -7098,10 +7098,14 @@ proc pdtk_pastetext {} {
global
pdtk_pastebuffer
set
pdtk_pastebuffer
""
catch
{
global
pdtk_pastebuffer
;
set
pdtk_pastebuffer
[
clipboard
get
]}
#
puts
stderr
[
concat
paste
$
pdtk_pastebuffer
]
#
puts
stderr
"
paste
<
$pdtk_pastebuffer
>"
for
{
set
i
0
}
{$
i
<
[
string
length
$
pdtk_pastebuffer
]}
{
incr
i
1
}
{
set
cha
[
string
index
$
pdtk_pastebuffer
$
i
]
scan
$
cha
%
c
keynum
#
puts
stderr
"keynum=<$keynum>"
#
if
{
$
keynum
==
11
}
{
#
set
keynum
15
#}
if
{$
i
==
[
expr
[
string
length
$
pdtk_pastebuffer
]
-
1
]}
{
#
unlike
key
command
which
would
be
pd
[
concat
pd
key
1
$
keynum
0
\;]
#
we
add
first
digit
to
ask
for
force
getscroll
as
we
limit
the
number
of
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment