system/autocutsel: Added (sync X clipboard with the cutbuffer)

Signed-off-by: Niels Horn <niels.horn@slackbuilds.org>
This commit is contained in:
Grigorios Bouzakis 2011-12-10 16:09:44 -02:00 committed by Niels Horn
parent 7fce9c810c
commit ba539b5717
6 changed files with 315 additions and 0 deletions

9
system/autocutsel/README Normal file
View file

@ -0,0 +1,9 @@
Autocutsel tracks changes in the X server's cutbuffer and CLIPBOARD
selection. When the CLIPBOARD is changed, it updates the cutbuffer.
When the cutbuffer is changed, it owns the CLIPBOARD selection.
The cutbuffer and CLIPBOARD selection are always synchronized.
Autocutsel is mostly useful with window managers since most desktop
environments today include their own clipboard managers.
If you dont use a display manager like KDM you can use autocutsel
by adding an entry to your $HOME/.xinitc file using the -fork option.

View file

@ -0,0 +1,106 @@
.TH "AUTOCUTSEL" "1" "5 December 2007" "autocutsel 0.9.0"
.SH "NAME"
autocutsel \- keep the X clipboard and the cutbuffer in sync
.SH "SYNOPSIS"
.HA
.na
.B autocutsel
.RB [ \-selection
.IR selection_name ]
.RB [ \-cutbuffer
.IR number ]
.RB [ \-debug ]
.RB [ \-verbose ]
.RB [ \-fork ]
.RB [ \-pause
.IR milliseconds ]
.RB [ \-buttonup ]
.LP
.SH "DESCRIPTION"
.PP
This manual page documents briefly the
.B autocutsel
command.
.PP
This manual page was written for the
.B Debian
distribution because the original
program does not have a manual page.
.PP
.B autocutsel
tracks changes in the server's
cutbuffer and clipboard selection.
When the clipboard is changed,
it updates the cutbuffer.
When the cutbuffer is changed,
it owns the clipboard selection.
The cutbuffer and clipboard
selection are always synchronized.
Since the VNC client synchronizes
the Windows' clipboard and the
server's cutbuffer,
all three "clipboards" are
always kept synchronized.
When you copy some text in Windows,
the cutbuffer and the clipboard
selection are updated.
When you copy text on the server
using either the cutbuffer or
the clipboard selection,
the Windows's clipboard is always
updated.
.SH "OPTIONS"
.TP
.B -selection, -select, -sel, -s {CLIPBOARD|PRIMARY}
Specify which selection to use.
Default is CLIPBOARD.
.TP
.B -cutbuffer <number>
(Details of this parameter unknown.)
.TP
.B -debug, -d
Run with debugging mode.
.TP
.B -verbose, -v
Be more verbose.
Reports the version and announces synchronizations.
.TP
.B -fork, -f
Run as a daemon program in the background.
This is recommended when used from an X startup script.
.TP
.B -pause, -p <milliseconds>
Wait some milliseconds before owning the selection.
.TP
.B -buttonup
Get the selection only when the
button 1 is not pressed.
This may help with OpenOffice Writer.
.SH "AUTHOR"
.PP
This manual page was written by
Elmar S. Heeb <elmar@heebs.ch> for the
.B Debian
system (but may be used by others).
Permission is granted to copy,
distribute and/or modify this
document under the terms of the
GNU General Public License,
Version 2 any later version published
by the Free Software Foundation.
.PP
On Debian systems,
the complete text of the
GNU General Public License
can be found in
/usr/share/common-licenses/GPL.

View file

@ -0,0 +1,101 @@
#!/bin/sh
# Slackware build script for autocutsel
# Copyright 2011 Grigorios Bouzakis <grbzks@imap.cc>
# All rights reserved.
#
# Permission to use, copy, modify, and distribute this software for any purpose
# with or without fee is hereby granted, provided that the above copyright
# notice and this permission notice appear in all copies.
#
# THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
# INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
# AUTHORS AND COPYRIGHT HOLDERS AND THEIR CONTRIBUTORS BE LIABLE FOR ANY
# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
PRGNAM=autocutsel
VERSION=${VERSION:-0.9.0}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
i?86) ARCH=i486 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
fi
CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
if [ "$ARCH" = "i486" ]; then
SLKCFLAGS="-O2 -march=i486 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
fi
DOCS="AUTHORS COPYING ChangeLog INSTALL NEWS README TODO"
set -e
rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
cd $PRGNAM-$VERSION
chown -R root:root .
find . \
\( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \
-exec chmod 755 {} \; -o \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
--libdir=/usr/lib${LIBDIRSUFFIX} \
--sysconfdir=/etc \
--localstatedir=/var \
--mandir=/usr/man \
--build=$ARCH-slackware-linux
make
make install DESTDIR=$PKG
# add man pages
mkdir -p $PKG/usr/man/man1
cp $CWD/{autocutsel,cutsel}.1 $PKG/usr/man/man1
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}

View file

@ -0,0 +1,10 @@
PRGNAM="autocutsel"
VERSION="0.9.0"
HOMEPAGE="http://www.nongnu.org/autocutsel"
DOWNLOAD="http://savannah.nongnu.org/download/autocutsel/autocutsel-0.9.0.tar.gz"
MD5SUM="ba4a6f632cb4815ae4e5c3027c24cfc5"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
MAINTAINER="Grigorios Bouzakis"
EMAIL="grbzks@imap.cc"
APPROVED="Niels Horn"

View file

@ -0,0 +1,70 @@
.TH "CUTSEL" "1" "5 December 2007" "autocutsel 0.9.0"
.SH "NAME"
cutsel \- show information about the X clipboard and the cutbuffer in sync
.SH "SYNOPSIS"
.PP
.B cutsel
[-selection \fIselection_name\fP]
[-cutbuffer \fInumber\fP]
[-debug]
[-verbose]
{cut|sel}
.LP
.SH "DESCRIPTION"
.PP
This manual page documents briefly the
.B cutsel
command.
.PP
This manual page was written for the
.B Debian
distribution because the original
program does not have a manual page.
.TP
.B cutsel [\fIoptions\fP] cut
shows the contents of the cut buffer
and
.TP
.B cutsel [\fIoptions\fP] sel
shows the owner of the selection.
.SH "OPTIONS"
.TP
.B -selection, -select, -sel, -s {CLIPBOARD|PRIMARY}
Specify which selection to use.
Default is CLIPBOARD.
.TP
.B -cutbuffer <number>
(Details of this parameter unknown.)
.TP
.B -debug, -d
Run with debugging mode.
.TP
.B -verbose, -v
Be more verbose.
Reports the version and announces synchronizations.
.SH "AUTHOR"
.PP
This manual page was written by
Elmar S. Heeb <elmar@heebs.ch> for the
.B Debian
system (but may be used by others).
Permission is granted to copy,
distribute and/or modify this
document under the terms of the
GNU General Public License,
Version 2 any later version published
by the Free Software Foundation.
.PP
On Debian systems,
the complete text of the
GNU General Public License
can be found in
/usr/share/common-licenses/GPL.

View file

@ -0,0 +1,19 @@
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|'
# on the right side marks the last column you can put a character in. You must
# make exactly 11 lines for the formatting to be correct. It's also
# customary to leave one space after the ':' except on otherwise blank lines.
|-----handy-ruler------------------------------------------------------|
autocutsel: autocutsel (keep the X clipboard and the cutbuffer in sync)
autocutsel:
autocutsel: Autocutsel tracks changes in the server's cutbuffer and clipboard
autocutsel: selection. When the clipboard is changed, it updates the cutbuffer.
autocutsel: When the cutbuffer is changed, it owns the clipboard selection. The
autocutsel: cutbuffer and clipboard selection are always synchronized.
autocutsel:
autocutsel: Homepage: http://www.nongnu.org/autocutsel
autocutsel:
autocutsel:
autocutsel: