Skip to content
This repository was archived by the owner on Mar 27, 2020. It is now read-only.

Commit b06c21d

Browse files
committed
Extra: [Tweetdeck-colordeck] Add cdk files for "Colordeck" extension
Backgrounds: Twitter will stop providing UserStream APIs until 24th Aug, this means all 3rd-party twitter clients will have these issues: * User-stream can't be updated. * Notifications, legacy DM styles will be ended. Changes: So we now do Tweetdeck support in both Chrome(ium) and Firefox. This commit provides light/dark colour schemes for "Colordeck" browser extensions for re-colouring Tweetdeck widgets partially. Still some widgets may be out of control though, but ours will improve Tweetdeck styling nicer than stock light/dark variants.
1 parent acebcca commit b06c21d

8 files changed

+159
-11
lines changed

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -38,3 +38,5 @@ Makefile
3838
Makefile.in
3939
missing
4040
inkscape.log
41+
ColorDeck-adapta.cdk
42+
ColorDeck-adapta-nokto.cdk

README.md

+18
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,24 @@ Extra Telegram Support
330330
> * Bundled noise-texture images are for *tiled* mode.
331331
> * Telegram support is a W.I.P currently.
332332
333+
Extra Tweetdeck Support
334+
-----------------------
335+
To try "Colordeck for Tweetdeck" extension theming, pass this option:
336+
337+
```
338+
--enable-tweetdeck enable Tweetdeck-colordeck support (type: bool)
339+
```
340+
341+
The installer installs `cdk` files into `Adapta*/tweetdeck` directories if Tweetdeck support is enabled.
342+
Then open the file via Colordeck -> import > "Colors" -> Choose File.
343+
344+
> **Note:**
345+
>
346+
> * [**Chrome Web Store**](https://chrome.google.com/webstore/detail/colordeck-for-tweetdeck/jgoilgghdiafcdpgaddhfnlnhjhiejjl)
347+
> * [**Firefox Add-ons**](https://addons.mozilla.org/en-US/firefox/addon/colordeck/)
348+
> * Light and dark variants are supported.
349+
> * Currently those files support "Colors" only, so enabling "Colors" checkbox is enough.
350+
333351
Other Projects
334352
------
335353
This is a list of community projects, related to Adapta:

autogen.sh

+1
Original file line numberDiff line numberDiff line change
@@ -18,5 +18,6 @@ if test -z "${NOCONFIGURE}"; then
1818
--disable-chrome-legacy \
1919
--disable-plank \
2020
--disable-telegram \
21+
--disable-tweetdeck \
2122
"$@"
2223
fi

configure.ac

+13-11
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,18 @@ AM_INIT_AUTOMAKE([
2323
AC_PREFIX_DEFAULT(/usr)
2424
AM_SILENT_RULES([yes])
2525

26-
ADAPTA_OPTION([PARALLEL], [parallel], [parallel-build], [disable])
27-
ADAPTA_OPTION([GTK_NEXT], [gtk_next], [Gtk-4.0], [disable])
28-
ADAPTA_OPTION([GNOME], [gnome], [Gnome-Shell], [disable])
29-
ADAPTA_OPTION([CINNAMON], [cinnamon], [Cinnamon], [disable])
30-
ADAPTA_OPTION([FLASHBACK], [flashback], [Flashback], [disable])
31-
ADAPTA_OPTION([XFCE], [xfce], [XFce], [disable])
32-
ADAPTA_OPTION([MATE], [mate], [Mate], [disable])
33-
ADAPTA_OPTION([OPENBOX], [openbox], [Openbox], [disable])
34-
ADAPTA_OPTION([CHROME_LEGACY],[chrome_legacy],[Chrome(ium)-legacy],[disable])
35-
ADAPTA_OPTION([PLANK], [plank], [Plank], [disable])
36-
ADAPTA_OPTION([TELEGRAM], [telegram], [Telegram], [disable])
26+
ADAPTA_OPTION([PARALLEL], [parallel], [parallel-build], [disable])
27+
ADAPTA_OPTION([GTK_NEXT], [gtk_next], [Gtk-4.0], [disable])
28+
ADAPTA_OPTION([GNOME], [gnome], [Gnome-Shell], [disable])
29+
ADAPTA_OPTION([CINNAMON], [cinnamon], [Cinnamon], [disable])
30+
ADAPTA_OPTION([FLASHBACK], [flashback], [Flashback], [disable])
31+
ADAPTA_OPTION([XFCE], [xfce], [XFce], [disable])
32+
ADAPTA_OPTION([MATE], [mate], [Mate], [disable])
33+
ADAPTA_OPTION([OPENBOX], [openbox], [Openbox], [disable])
34+
ADAPTA_OPTION([CHROME_LEGACY],[chrome_legacy],[Chrome(ium)-legacy], [disable])
35+
ADAPTA_OPTION([PLANK], [plank], [Plank], [disable])
36+
ADAPTA_OPTION([TELEGRAM], [telegram], [Telegram], [disable])
37+
ADAPTA_OPTION([TWEETDECK], [tweetdeck], [Tweetdeck-Colordeck], [disable])
3738

3839
PKG_PROG_PKG_CONFIG
3940
AS_IF([test -z "$PKG_CONFIG"], [AC_MSG_ERROR(['pkg-config' not found.])])
@@ -131,6 +132,7 @@ AC_MSG_RESULT([
131132
Chrome(ium)-legacy: $ENABLE_CHROME_LEGACY
132133
Plank: $ENABLE_PLANK
133134
Telegram: $ENABLE_TELEGRAM
135+
Tweetdeck-Colordeck: $ENABLE_TWEETDECK
134136
135137
===========================================================
136138
=>> run 'make' and 'sudo make install'

extra/Makefile.am

+30
Original file line numberDiff line numberDiff line change
@@ -20,11 +20,18 @@ gedit_file = \
2020
$(geditdir)/adapta.xml \
2121
$(geditdir)/README.md
2222

23+
tweetdeckdir = $(srcdir)/tweetdeck
24+
tweetdeck_file = $(tweetdeckdir)/light/ColorDeck-adapta.cdk
25+
tweetdeck_nokto_file = $(tweetdeckdir)/dark/ColorDeck-adapta-nokto.cdk
26+
2327
# ******************
2428
# * Generate files *
2529
# ******************
2630

2731
all:
32+
if ENABLE_TWEETDECK
33+
cd $(tweetdeckdir) && ./recolor-cdk.sh
34+
endif
2835

2936
# *****************
3037
# * Install files *
@@ -62,6 +69,16 @@ if ENABLE_TELEGRAM
6269
ln -sf ../Adapta-Nokto/telegram $(noktoetadir)/telegram
6370
endif
6471

72+
if ENABLE_TWEETDECK
73+
$(MKDIR_P) $(adaptadir)/tweetdeck
74+
$(MKDIR_P) $(noktodir)/tweetdeck
75+
cp -Rv $(tweetdeck_file) $(adaptadir)/tweetdeck
76+
cp -Rv $(tweetdeck_nokto_file) $(noktodir)/tweetdeck
77+
cd $(adaptadir)
78+
ln -sf ../Adapta/tweetdeck $(adaptaetadir)/tweetdeck
79+
ln -sf ../Adapta-Nokto/tweetdeck $(noktoetadir)/tweetdeck
80+
endif
81+
6582
$(MKDIR_P) $(adaptadir)/gedit
6683
cp -Rv $(gedit_file) $(adaptadir)/gedit
6784
cd $(adaptadir)
@@ -93,6 +110,13 @@ if ENABLE_TELEGRAM
93110
test -e $(adaptaetadir)/telegram && rm -rfv $(adaptaetadir)/telegram
94111
endif
95112

113+
if ENABLE_TWEETDECK
114+
test -e $(noktodir)/tweetdeck && rm -rfv $(noktodir)/tweetdeck
115+
test -e $(adaptadir)/tweetdeck && rm -rfv $(adaptadir)/tweetdeck
116+
test -e $(noktoetadir)/tweetdeck && rm -rfv $(noktoetadir)/tweetdeck
117+
test -e $(adaptaetadir)/tweetdeck && rm -rfv $(adaptaetadir)/tweetdeck
118+
endif
119+
96120
test -e $(noktodir)/gedit && rm -rfv $(noktodir)/gedit
97121
test -e $(adaptadir)/gedit && rm -rfv $(adaptadir)/gedit
98122

@@ -102,5 +126,11 @@ endif
102126

103127
CLEANFILES =
104128

129+
if ENABLE_TWEETDECK
130+
CLEANFILES += \
131+
$(tweetdeckdir)/light/ColorDeck-adapta.cdk \
132+
$(tweetdeckdir)/dark/ColorDeck-adapta-nokto.cdk
133+
endif
134+
105135
DISTCLEANFILES = \
106136
$(CLEANFILES)
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"data":{
3+
"colors":{
4+
"c_principal":"#263238",
5+
"c_background":"#263238",
6+
"c_ct_background":"#222D32",
7+
"c_ct_background2":"#66CEFF",
8+
"c_ct_text":"#7F898E",
9+
"c_cw_background":"#009688",
10+
"c_cw_text":"#FFFFFF",
11+
"c_links":"#55BCDA",
12+
"c_ml_background":"#243035",
13+
"c_ml_icons":"#B9C2C6",
14+
"c_ntfBubble_color":"#4DB6AC",
15+
"c_ntf_background":"#009688",
16+
"c_ntf_text":"#FFFFFF",
17+
"c_scrollbar":"#596469",
18+
"c_tw_background":"#263238",
19+
"c_tw_text":"#CFD8DC",
20+
"ct_backgroundType":"solid",
21+
"mode":"advanced"
22+
}
23+
}
24+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"data":{
3+
"colors":{
4+
"c_principal":"#263238",
5+
"c_background":"#FAFBFC",
6+
"c_ct_background":"#E5E9EC",
7+
"c_ct_background2":"#66CEFF",
8+
"c_ct_text":"#7E868B",
9+
"c_cw_background":"#009688",
10+
"c_cw_text":"#FFFFFF",
11+
"c_links":"#03A9F4",
12+
"c_ml_background":"#F7F9F9",
13+
"c_ml_icons":"#414C51",
14+
"c_ntfBubble_color":"#4DB6AC",
15+
"c_ntf_background":"#009688",
16+
"c_ntf_text":"#FFFFFF",
17+
"c_scrollbar":"#BABFC1",
18+
"c_tw_background":"#FAFBFC",
19+
"c_tw_text":"#263238",
20+
"ct_backgroundType":"solid",
21+
"mode":"advanced"
22+
}
23+
}
24+
}

extra/tweetdeck/recolor-cdk.sh

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
#! /bin/bash
2+
#
3+
# This file is part of adapta-gtk-theme
4+
#
5+
# Copyright (C) 2016-2018 Tista <[email protected]>
6+
#
7+
# This program is free software; you can redistribute it and/or modify
8+
# it under the terms of the GNU General Public License as published by
9+
# the Free Software Foundation; either version 2 of the License, or
10+
# (at your option) any later version.
11+
#
12+
13+
SRC_LIGHT_FILE="./light/ColorDeck-adapta.cdk"
14+
SRC_DARK_FILE="./dark/ColorDeck-adapta-nokto.cdk"
15+
COL_FILE="../../gtk/sass/common/_colors.scss"
16+
KEY_FILE="../../gtk/sass/common/_key_colors.scss"
17+
18+
# Default colours
19+
accent1="`grep 'Teal300' $COL_FILE | \
20+
cut -d' ' -f3`"
21+
suggested1="`grep 'Teal500' $COL_FILE | \
22+
cut -d' ' -f3`"
23+
24+
# Check and re-color color-scheme
25+
if [ -e $KEY_FILE ]; then
26+
accent2="`grep 'key_accent' $KEY_FILE | \
27+
cut -d' ' -f2 | cut -d';' -f1`"
28+
suggested2="`grep 'key_suggestion' $KEY_FILE | \
29+
cut -d' ' -f2 | cut -d';' -f1`"
30+
31+
cp -f $SRC_LIGHT_FILE.in $SRC_LIGHT_FILE && \
32+
cp -f $SRC_DARK_FILE.in $SRC_DARK_FILE && sleep 1
33+
34+
if [ $accent1 != $accent2 ]; then
35+
sed -i "s/$accent1/$accent2/gi" $SRC_LIGHT_FILE
36+
sed -i "s/$accent1/$accent2/gi" $SRC_DARK_FILE
37+
echo $accent1 is re-colored with $accent2.
38+
fi
39+
if [ $suggested1 != $suggested2 ]; then
40+
sed -i "s/$suggested1/$suggested2/gi" $SRC_LIGHT_FILE
41+
sed -i "s/$suggested1/$suggested2/gi" $SRC_DARK_FILE
42+
echo $suggested1 is re-colored with $suggested2.
43+
fi
44+
else
45+
echo ../../gtk/sass/common/_key_colors.scss was not found. Stopped...
46+
exit 1
47+
fi

0 commit comments

Comments
 (0)