Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature(qchat): re-arrange websocket message to allow image communications #211

Merged
merged 13 commits into from
Nov 1, 2024

Conversation

gounux
Copy link
Contributor

@gounux gounux commented Oct 24, 2024

  • setup dataclass objects for messages that transit through websocket (see qtribu/logic/qchat_messages.py). There is a type key that all kinds of messages implement, thus changing and breaking the existing communications (implemented in the backend in this PR)
  • create a QChat websocket wrapper that handles the websocket comms and message parsing and emits Qt signals using the QChat message dataclasses
  • setup the image message type and let the user send some image via picking files with a QFileDialog, or via sending a screenshot of the current QGIS canvas. When clicking on a image message a dialog pops up and displays the image

image

@github-actions github-actions bot added enhancement New feature or request UI User interface: forms, widgets... labels Oct 24, 2024
@gounux gounux changed the title feature(qchat): display and send image feature(qchat): re-arrange websocket message to allow image communications Oct 26, 2024
@gounux gounux marked this pull request as ready for review October 26, 2024 09:31
@gounux gounux requested a review from Guts October 26, 2024 09:35
Copy link

sonarcloud bot commented Nov 1, 2024

@gounux
Copy link
Contributor Author

gounux commented Nov 1, 2024

@Guts is it okay if we merge this as well as as #212 ?

Sorry for the X+ changes btw..

@Guts
Copy link
Member

Guts commented Nov 1, 2024

Sure, let's go!

@gounux gounux merged commit 634cc28 into main Nov 1, 2024
12 checks passed
@gounux gounux deleted the feature/qchat-image branch November 1, 2024 14:08
Guts pushed a commit that referenced this pull request Nov 6, 2024
…ations (#211)

* feature(qchat): display and send image

* fix(qchat): create an item using bytes

* feature(qchat): send QGIS screenshot to chat

* feature(qchat): open image on single click

* refactor(qchat): use qchat message types and ws wrapper

* feature(qchat): send QGIS screenshot through websocket

* feature(qchat): send iamges through websocket

* fix(qchat): set send author and avatar for image items

* feature(qchat): set image message color if sent by user

* doc(qchat): add docstrings
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request UI User interface: forms, widgets...
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants