Giter Site home page Giter Site logo

chatty's Introduction

Chatty

Chatty is a Twitch Chat Client for Desktop written in Java featuring many Twitch specific features.

I learned about most of the Java techniques and APIs used in this during development, so many things won't be designed ideally. I also never released such a project as opensource before, so if I missed anything or didn't adhere to some license correctly, please tell me.

Download

Go to the website for ready to use downloads and more information on the features.

Contributions

Contributions to Chatty under the terms of the GPLv3 License (or compatible) are welcome.

If you're contributing code that you didn't write yourself, make sure to adhere to whatever license terms it is under (like retaining copyright notices) and to detail that in the Pull Request.

Obviously, I won't be able to accept all contributions, for example I may already be working on something similar. If you plan to put more than a little effort into a Pull Request, consider asking first if what you're doing has a chance of being added.

License Information

Chatty, as a whole, is released under the GPLv3 or later (see included LICENSE file).

Copyright (C) 2017-2023  tduva and contributors

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

Partly based on source code (most files located in the src/chatty/ directory and subdirectories) licensed under the MIT license.

Copyright (c) 2014-2017  tduva and contributors

Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.

External Libraries

Images / Other

Notes on building the program yourself

The project is compiled using Gradle. Once you've checked it out, you can run gradlew build to compile and run the tests, and gradlew release to package the release artifacts.

If you modified Chatty you should set your own client id in Chatty.java. You may also want to disable the Version Checker.

Main release tasks

  • release - Just the regular JAR version Zip
  • releaseWindows - Regular and Windows Standalone Zip
  • releaseWinSetups - Everything, including Windows Standalone and Windows setups

Build parameters

  • Windows Standalone (one of these required for the Windows Standalone tasks)
    • javapackagerPath - Path to the javapackager.exe in the Java 8 JDK
      • jrePath - Adds -Bruntime= option for javapackager (optional, will use default JRE otherwise)
    • jpackagePath - Path to the jpackage.exe in the Java 14+ JDK (if you specify this one, it will use jpackage instead of javapackager)
    • mtPath - Path to Microsoft's mt.exe (see e.g. https://stackoverflow.com/questions/54462568/how-to-install-just-mt-exe), used to add assets-bundle/Chatty.exe.manifest to the Chatty.exe/ ChattyPortable.exe (optional)
  • innosetupPath - Path to InnoSetup's iscc.exe (required for the Windows installer tasks)

These build parameters must be specified like this: gradlew windowsZip -PjavapackagerPath="<path_to>/javapackager.exe"

Full example: gradlew -Dorg.gradle.java.home="C:/Program Files (x86)/Java/jdk1.8.0_201" releaseWinSetups --console=verbose -PjavapackagerPath="C:/Program Files (x86)/Java/jdk1.8.0_201/bin/javapackager.exe" -PjrePath="C:\Program Files (x86)\Java\jre1.8.0_201" -PinnosetupPath="C:\Program Files (x86)\Inno Setup 6\ISCC.exe"

chatty's People

Contributors

23rd avatar 3ventic avatar azenet avatar bziemons avatar chhe avatar coolglen avatar craftwar avatar dincahill avatar ghettogirl avatar hinet60613 avatar jettisonjoe avatar lucaber avatar m00hlti avatar mheetu avatar redundanz avatar rybak avatar tduva avatar throkk avatar tmccarthy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

chatty's Issues

Make setting names case-insensitive

Setting names (used in setting commands) don't really need to be case-sensitive. You wouldn't want to have two settings that are just different by case anyway.

Add more information to Channel Info dialog

Information that could also be interesting for the Channel Info dialog:

  • Channel State (Sub/Slowmode/R9k/Hosting)
  • Possibly info available in the Stream object like stream fps/pixel height

This should be a toggle of some kind so it can easily be shown/hidden.

Pause Chat when moving the mouse over it

Stop scrolling chat when moving the mouse over to prevent misclicks when the chat is moving.

This probably won't work when the chat isn't already filled (and thus doesn't make use of a scrollbar yet), because as opposed to Twitch Webchat it starts at the bottom from the start.

Improve Context Menu setting format

Since these settings can contain linebreaks for a while already, make them more flexible:

  • Allow custom submenu names
  • Allow custom names for entries
  • Allow entering of command to be executed right there

Similiar to the mIRC format should be reasonable:

Command
Command2
Submenu
.Submenu Entry
.Submenu Entry2

This would need some sort of automatic transition between the old and new setting format.

Graphical glitches in text input field and userlist while on multiple monitors

So this one is fairly specific. I've read a little about it online and it seems like it might be something to do with java not handling multiple monitors very well.

Anyway. This bug happens when you have the main chatty window on your secondary monitor (not main as set in windows) and the bug seems to randomly come and go with the only triggering event being when a toaster notification is shown. This bug happens despite disabling either directdraw or direct3d in "Other" under "Options".
My current way of bypassing the glitch is currently having the client main window on my primary monitor and then popping out a channel and moving that to my secondary monitor.
But that fix also implies that that the problem might have something to do with chatty toaster notifications.

I might've jumped the gun with this bug report because I've just turned off "Chatty notifications" and am going to see if that fixes my graphical problems.

PS: Didn't attach picture in original post, so here it is: http://i.imgur.com/c20QjYZ.jpg

EDIT: Nope, still happens. Noticed it happened when I tried to use the auto-completion feature which also produce a small toaster like popup.

EDIT2: Previous observation regarding bug not happening on primary monitor was wrong.

[IDEA] FFZ Donor Badge (and more?) & BetterTTV Emote Approver Badge (and more?)

FrankerFaceZ has its Donor Badge and BetterTTV has its Emote Approver Badge.
I don't know about the 2 APIs (never used it, only the Twitch API), but there must be a way to receive this information because the browser add-ons can do it.
It would be an idea to implement this feature, so also Chatty users can know who is a FFZ Donor/BetterTTV Emote Approver :)

EDIT: I found this -> https://api.betterttv.net/2/badges
It seems BetterTTV has some more badges: Developer, Support Team, Design Team, Emote Approver
And there is also the complete user list stored. So it basically can be cached in the settings directory.
(just for reference: https://cdn.betterttv.net/betterttv.js)

EDIT2: For FFZ I also found everything relevant :)
http://cdn.frankerfacez.com/script/script.min.js <-- this is the script which the browser add-on injects to the website.
And FFZ also uses more than just donor badges... Developers and such.
This is at least the donor list http://cdn.frankerfacez.com/script/donors.txt

Sound notification & Look and Feel

Hello!
You fixed whispers very fast, thanks a lot. Now it works well.

Can you add sound notification when someone has sent a whisper? There is no option for it. Only for highlight/stream status/message/join&part/followers ... i think whisper is needed also.

And about Look&Feel. If change it to "system", then message's font size in "UserDialog" is very small. Problem...

1

Streamline timeout information/progress lines.

From having 3 separate lines, make it one or two dynamic lines.
Chat can get kind of messy at times and then gets filled with lines generated by chatty.

Now it shows separate lines like this:
[19:34] Trying to timeout i_like_pies123 (8s)
[19:34] [Info] I_like_pies123 has been timed out for 8 seconds.
[19:34] I_like_pies123 has been banned from talking

Suggestion is to have it dynamic, changing one single line to different states. Like this:
"Trying to timeout i_like_pies123 (8s)..." and then add to that line: "Trying to timeout i_like_pies123 (8s)... Applied timed out for 8 seconds."

Resubs not showing up

Twitch has made a change to the resub system which has stopped resub notifications from showing up in chatty

Animated emotes causing huge cpu usage spikes

Whenever somebody in a chat uses the emotes KKonaPls or Citto, my cpu usage spikes to ~50-80%, which is extremely detrimental to the performance of all other applications. It also continues to stay at about 25-50% usage after closing the channel that the emote was displayed in (but not closing the program).

Screenshots:
screenshot 14
screenshot 15

Add support for new twitch /emoteonly and /emoteonlyoff commands

Twitch has recently added emote-only mode (and, of course, the ability to disable it). Chatty does not support the commands in the / form and can only be entered using . notation. See http://help.twitch.tv/customer/portal/articles/659095-chat-moderation-commands between /subscribersoff and /clear.

Created a bare-bones PR to add support for the / commands themselves.
#33

Could maybe consider adding emote-only to the title bar (ChannelState) for clarity.

Support for astral characters (like emoji)

I realize that Java treats strings as UTF-16, so this won't be easy, but it would be nice to render emojis and use the platform's emoji fallback font, if one exists.

Add a Scripting-Interface to Chatty for Macros or simple Bots

Hey,
I know this feature from Nettalk IRC Client and think it's a nice thing to play with. The Good thing is that Java supports easy Java-Script-Engines to be used which saves us a lot of work.

I would recommend some GUI Window where you can enable/disable and add new scripts (which are maybe even saved as .js files). You can open a Tab to program in it.

I imagine it something like:
public void onChatMessage(String Channel, String message) {
// Some Code
}

When there is a new Chat-Message, we will loop through every enabled script and see if it has onChatMessage. If yes, we call it.

Same applies to onSlashCommand().
Or we decide to have an onEnable() "constructor" which forces the Script to use something like addSlashCommandHandler("/test", my_proc);

A nice example script would be one which is greeting everybody (so we know which API we basically need to implement, shouldn't be much):

public boolean onSlashCommand(String command) {
if (command == "greet-all")
{
    for (User u : channels.getActiveChannel().getUsers()) // active is defined by the opened tab, maybe we also need .isChannel() or .isWhisper()
    {
         if (u.isOwner() || u.isMod())
             continue; // Don't wake the sleeping dogs :D 
         channels.getActiveChannel().sendMessage("HeyGuys " + u.getName()); // or rather Twitch.sendMessage(channels.getActiveChannel().getName(), "HeyGuys ..");?
         return true;
     }
} else {
    return false; // Command not handled: We need to know when the command wasn't existing.
}

What do you guys think about that? :)

Alternating message background colors

Have messages separated by alternating background colors.

This is definitely possible somehow, but I currently don't know enough about where/how to affect the rendering in that way to properly implement that.

Limit Character Length Of Posts (anti spam)

Feature request;

Introduce an anti-spam measure.
Similar to the function behind shortening deleted message to 50 characters, introduce a user defined max length for posts in the chat window, meaning a malicious spammer can't fill the entire window.

Any feedback welcome, thanks

UrlOpener not catching exception; Desktop.browse() is not supported

I use chatty on linux and Desktop.browse() is not supported on most java versions, although Desktop itself is.
Starting on line 85 of chatty.gui.UrlOpener.java, in the openUrl() method, here's my suggested solution.

...
if (Desktop.isDesktopSupported()) {
    try {
        if (Desktop.getDesktop().isSupported(Desktop.Action.BROWSE))
            Desktop.getDesktop().browse(new URI(url));
        else
            Runtime.getRuntime().exec("xdg-open " + url);
        return true;
    } catch (IOException ex) {
...

All I added is the if/else statement and the action to execute in case Desktop.browse() is not supported. If browse is not supported, java will try to execute "xdg-open [url]" which will open the default browser on most linux systems that have the requirements to run chatty.

Look and Feel

Setting it to "System" causes a NullPointerException and can only be recovered by changing the look&feel in the setting file manually to default.

using Windows 10

Ability to hide Users list, and Menu list?

[Enhancement]

The ability to both hide the user list and the menu bar would be a great feature. And also possibly the ability to make the window transparent would be awesome.

AbstractMethodError when logging Exception

There has been an AbstractMethodError when using Throwable.printStackTrace for some users for quite a while now. It is unclear as to how that can even happen, because a thrown exception (to my understanding) shouldn't be abstract. Because of this there is little information as to what causes the error, but it appears to be related to the GUI.

It appears to only happen on Java 8, although that may be because it's the current version and most people use it. It seems to happen on different OS (at least on Windows 7/8.1, Linux, OSX).

Exception java.lang.AbstractMethodError: java.lang.Throwable.printStackTrace(Ljava/io/PrintWriter;)V
    occured during logging of uncaught exception: java.lang.ArrayIndexOutOfBoundsException [Thread[AWT-EventQueue-0,6,main]]

Any suggestions or help would be appreciated.

Improve Notifications

Some ideas:

  • More types of notifications
  • Different settings per type (color, position, time), default settings to apply if no custom settings are set
  • More possible positions (like center of screen, over the program)

Copy/Paste doesn't work on OSX

Title explains it all. Using latest version of OSX El Capitan. cmd + c, cmd + x and cmd + v doesn't work to copy and paste text, either from the chat pane or from the input text box.

Resettable marker line / read progress indication

The possibility to have a marker line or different background image or font color or some other way of indicating what lines are new since last time you reset it.

This so a streamer can reset the line with for example a mouse side button, to indicate to what is new since last time he looked at chat and pressed the "reset" button.

Maybe have a different font color for already "read" chat. So all text already in chat will just change it's color from black to gray or similar when the button is pressed, and new lines appearing will be in the default chat text color, until the button is pressed once again.

Sample: https://puu.sh/jG5AA/449de14fb9.png

Whispers bug

When i was testing whispers i ran chatty and wrote from another twitch account to myself.
Always some message was missing. I could see it via web twitch, but didn't get it in chatty.
Of course in chatty my account was verified and i got some messages, but not all of them.
Please test and fix it!
Thanks in advance.

[Suggestion] autologin when join channel

Open Live Channel (Ctrl+L), and join any channel. Chatty requests you login.
This happens when you don't have startup channel specified in setting "Main".
Chatty should autologin for user.

Doesn't load messages and users

When I join big channels with a lot of viewers I just load the moderators and I can't see any message posted... I tried to let it load for a while but nothing happens.
immagine

As you can see there a lot of viewers but no messagers/normal users. (s4 is an exception because he was mod when I joined the channel in Chatty)

Hanging when dragging files

This is a bit of a weird issue, but it's consistently reproducable.

Essentially, dragging a file in windows over the top of Chatty causes both Chatty and explorer to hang. Killing the Chatty process fixes everything, but it's extremely weird.

Chatty also has a habit of freezing after ~15k messages, so in some of the larger channels it can hang relatively frequently. This one is fairly intermittent though, but it does happen.

Command line login via token

Hi,
the command line login via token seems to be broken.
The token I'm using (which is including the chat_login scope) is being created by another application in which I want to integrate Chatty into. So the launch parameters pretty much look like this
-connect -single -token {token} -channel {channel}, but this is leading to the following error message: "Cannot connect: Incomplete login data."...
From what it looks like, the token will only be read from the settings, instead of the arguments list.

Thanks!

can't remember Chatty window position

In settings

Dialogs Location/Size
Restore Dialogs

I tested all 4 choices, no1 can't restore position.
Any hint to fix, or I misunderstand this setting.

Allow background colour of Usercolors and Highlights to be set

Feature Request;

When setting the text colour for rules in Usercolors and Highlights, allow the background colour for those rules to be set also. It can be difficult to see highlighted messages in a fast room, allowing the background color to be set to a darker option for specific rules will aid moderators and broadcasters by making those important posts more visible.

Thanks

Chatty menu and text entry support high DPI displays

Hello,

Thank you very much for your work on this client. It is an amazing experience. You can work around text size by increasing font size in the chat window.

However, the menu,settings etc. is extremely small on a surface book. Most importantly the text entry box for chat is extremely small and you can't really see what you are writing. Is there a way to increase DPI support for high DPI displays?

Thank you and have a great holiday.

Scroll button(s) that jumps to bottom and/or top of the chat windows.

I would like to request a feature that adds a scroll button to the chat window that would 'jump' to the bottom of the chat window after having scrolled up. Similar how 'Home' and 'End' work in a document.
I understand keyboard shortcuts are faster, but having an alternative option for mouse users could be useful.

In addition, if it is possible to further customize this feature for the user. I think it'd be great if the user could pick which window(chat, username) the button would show up, and if the user wants it only on the bottom of the scroll bar or both top and bottom.

Ability to specify the channel to join on start from the command line

First of all, thanks a lot, this client is awesome!

I have custom scripts that open a stream in livestreamer and would love to be able to join the chat at the same time, when I start the stream. To be able to do that, I need an ability to specify which channel to join straight on the command line, e.g. java -jar chatty.jar --channel dendi.

This should be fairly straight-forward to implement. Would you care to accept a diff for a simple implementation that does not go into proper argument parsing of every possible option and supports only this simple channel option?

Further Livestreamer integration

I've been using the existing Livestreamer support in Chatty and it works... well enough, but I'd like to see it go even further. I would like to have it show up as one of the "Twitch Stream" submenu items. Making the option invoke Livestreamer with the "select" quality option would be perfect, but even prefilling the stream name in the Main tab of the existing Livestreamer dialog box would be handy.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.