mirage-0.7.2/ 0000775 0000000 0000000 00000000000 14077472336 0013001 5 ustar 00root root 0000000 0000000 mirage-0.7.2/.flake8 0000664 0000000 0000000 00000001331 14077472336 0014152 0 ustar 00root root 0000000 0000000 # vim: ft=dosini
# https://flake8.pycqa.org/en/latest/user/configuration.html
[flake8]
# E131: continuation line unaligned for hanging indent
# E301: when method is after a commented line + one blank line
# E302: expected 2 blank lines, found 1 when using @dataclass
# E303: more than one blank line between methods
# W504: when line breaks occur after a binary operator
# A003: when class attribute name is the same as a builtin
# E402: when a module import isn't at the start of the file
ignore = E131, E221, E241, E251, E301, E302, E303, W504, A003, E402
max-complexity = 99
inline-quotes = "
format = ${cyan}%(path)s${reset}:${yellow_bold}%(row)d${reset}:${green_bold}%(col)d${reset}: ${red_bold}%(code)s${reset} %(text)s
mirage-0.7.2/.github/ 0000775 0000000 0000000 00000000000 14077472336 0014341 5 ustar 00root root 0000000 0000000 mirage-0.7.2/.github/ISSUE_TEMPLATE/ 0000775 0000000 0000000 00000000000 14077472336 0016524 5 ustar 00root root 0000000 0000000 mirage-0.7.2/.github/ISSUE_TEMPLATE/bug_report.md 0000664 0000000 0000000 00000001376 14077472336 0021225 0 ustar 00root root 0000000 0000000 ---
name: Bug report
about: 'Report an unexpected behavior '
title: ''
labels: bug
assignees: ''
---
### Description
Describe your issue in details, provide error logs or screenshots if possible.
### Your environment
- OS or distribution (e.g. Arch Linux, macOS 10.15, Windows 7...)
- Architecture (e.g. x86 64bit)
- For Linux users: your desktop environment or window manager (e.g. GNOME 3.34 Wayland, i3 4.17, etc)
- How did you install Mirage? (e.g. manual build, distribution repository, AppImage, Flatpak...)
- For manual installations: your Qt version
- For manual installations: your Python version
### Steps to reproduce
1. Do this...
2. Do that...
### Expected behavior
Tell us what should happen
### Actual behavior
Tell us what happens instead
mirage-0.7.2/.github/ISSUE_TEMPLATE/feature_request.md 0000664 0000000 0000000 00000000203 14077472336 0022244 0 ustar 00root root 0000000 0000000 ---
name: Feature request
about: Suggest an idea for the application or project
title: ''
labels: enhancement
assignees: ''
---
mirage-0.7.2/.github/ISSUE_TEMPLATE/question.md 0000664 0000000 0000000 00000000172 14077472336 0020715 0 ustar 00root root 0000000 0000000 ---
name: Question
about: Ask a question about the application or project
title: ''
labels: question
assignees: ''
---
mirage-0.7.2/.gitignore 0000664 0000000 0000000 00000000567 14077472336 0015001 0 ustar 00root root 0000000 0000000 __pycache__
.mypy_cache
*.egg-info
*.pyc
*.qmlc
*.jsc
*~
tmp-*
build
dist
.qmake.stash
Makefile
mirage
mirage.pro.user
*.AppImage
tags
packaging/flatpak/flatpak-env
packaging/flatpak/requirements.txt
packaging/flatpak/flatpak-env-requirements.txt
packaging/flatpak/flatpak-pip.json
packaging/flatpak/flatpak-pip-generator
.flatpak-builder/
flatpak-build/
docs/TODO.md
mirage-0.7.2/.gitmodules 0000664 0000000 0000000 00000001064 14077472336 0015157 0 ustar 00root root 0000000 0000000 [submodule "submodules/qsyncable"]
path = submodules/qsyncable
url = https://github.com/benlau/qsyncable
[submodule "submodules/RadialBarDemo"]
path = submodules/RadialBarDemo
url = https://github.com/mirukana/RadialBarDemo
[submodule "submodules/hsluv-c"]
path = submodules/hsluv-c
url = https://github.com/hsluv/hsluv-c
[submodule "submodules/gel"]
path = submodules/gel
url = https://github.com/Cutehacks/gel
[submodule "submodules/SortFilterProxyModel"]
path = submodules/SortFilterProxyModel
url = https://github.com/oKcerG/SortFilterProxyModel
mirage-0.7.2/.isort.cfg 0000664 0000000 0000000 00000000201 14077472336 0014671 0 ustar 00root root 0000000 0000000 # https://pycqa.github.io/isort/docs/configuration/options/
[settings]
multi_line_output = 5
include_trailing_comma = True
mirage-0.7.2/.mypy.ini 0000664 0000000 0000000 00000000400 14077472336 0014550 0 ustar 00root root 0000000 0000000 # https://mypy.readthedocs.io/en/stable/config_file.html
[mypy]
cache_dir = ~/.cache/mypy
ignore_missing_imports = True
follow_imports = silent
warn_redundant_casts = True
warn_unused_ignores = True
warn_unreachable = True
mirage-0.7.2/COPYING 0000664 0000000 0000000 00000104515 14077472336 0014042 0 ustar 00root root 0000000 0000000 GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc.
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
Copyright (C)
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 .
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
Copyright (C)
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
.
mirage-0.7.2/COPYING.LESSER 0000664 0000000 0000000 00000016744 14077472336 0015044 0 ustar 00root root 0000000 0000000 GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc.
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
mirage-0.7.2/README.md 0000664 0000000 0000000 00000007537 14077472336 0014274 0 ustar 00root root 0000000 0000000 # Mirage
[](https://github.com/mirukana/mirage/releases)
[](https://github.com/poljar/matrix-nio)
[](https://matrix.to/#/#mirage-client:matrix.org)
[Features](#currently-implemented-features) ⬥
[Installation](docs/INSTALL.md) ⬥
[Configuration](docs/CONFIG.md) ⬥
[Theming](docs/THEMING.md) ⬥
[Contributing](docs/CONTRIBUTING.md) ⬥
[Screenshots](#screenshots)
A fancy, customizable, keyboard-operable [Matrix](https://matrix.org/) chat
client for encrypted and decentralized communication.
Written in Qt/QML and Python, **currently in alpha**.

## Currently Implemented Features
### General
- **Fluid, responsive interface** that adapts to any window size
- Toggleable **compact mode**
- Customizable **keyboard shortcuts** for everything, including
switching rooms, navigating messages, sending/opening files...
- Versatile **theming system**, properties can refer to each other and have
any valid ECMAScript 7 expression as values
- Comes by default with **dark** and **transparent themes**
- Desktop **notifications**, sounds and window alerts
- Support for HTTP and SOCKS5 proxies including TOR
### Accounts
- Built-in public homeservers list
- **Multiple accounts** in one client
- **SSO** and password authentication
- Set your display name and profile picture
- Import/export **E2E** key files
- Inspect, rename, manually verify and sign out one or multiple **sessions**
- Sessions for accounts within the same client automatically verify each others
- Set your account's **presence** to online, unavailable, invisible or offline
- Set custom **status messages**
- Automatically set your status to unavailable after a period of inactivity
- Advanced **push rules** editor
### Rooms
- Create, join, leave and forget rooms
- Send, accept and refuse invites
- Edit the room's name, topic, invite requirement, guest access and enable E2E
- Kick, ban and set the power level of users
- Pin rooms to the top of the list
- Unread message and highlight counters
- Sending **read receipts** to mark rooms as read
- Seeing who has read a message and when
- Inspect and manually **verify** other users's **E2E sessions**
- See other users's **presence, status message and last seen time**
- **Typing notifications**
### Messages
- Send and receive **E2E encrypted messages**
- Send and receive emote messages (e.g. `/me reads attentively`)
- Receive notice (bot) messages
- Send **markdown** formatted messages
- Additional syntax for **coloring text**, e.g. `(Some text...)` -
[SVG/CSS color names](https://www.december.com/html/spec/colorsvg.html),
`#RGB`, `#RRGGBB` and `#AARRGGBB` hex codes can be used
- Send and receive normal or **E2E encrypted files**
- Client-side Matrix & HTTP URL **image previews**, including animated GIF
- Upload images by pasting or drag-and-drop
- Full-size image viewer
- User ID, display names, room ID and room aliases **mentions**
- **Autocompletion** for usernames and user ID
- Individual and mass **message removal**
- Sending **rich replies**
## Documentation
- [Installation](docs/INSTALL.md)
- [Configuration](docs/CONFIG.md)
- [Theming](docs/THEMING.md)
- [Contributing](docs/CONTRIBUTING.md)
## Screenshots







mirage-0.7.2/autoreload.py 0000775 0000000 0000000 00000003720 14077472336 0015517 0 ustar 00root root 0000000 0000000 #!/usr/bin/env python3
"""Usage: ./autoreload.py [MIRAGE_ARGUMENTS]...
Automatically rebuild and restart the application when source files change.
CONFIG+=dev will be passed to qmake, see mirage.pro.
The application will be launched with `-name dev`, which sets the first
part of the WM_CLASS as returned by xprop on Linux.
Any other arguments will be passed to the app, see `mirage --help`.
Use `pip3 install --user -U requirements-dev.txt` before running this."""
import os
import subprocess
import sys
from contextlib import suppress
from pathlib import Path
from shutil import get_terminal_size as term_size
from watchgod import DefaultWatcher, run_process
ROOT = Path(__file__).parent
class Watcher(DefaultWatcher):
def accept_change(self, entry: os.DirEntry) -> bool:
path = Path(entry.path)
for bad in ("src/config", "src/themes"):
if path.is_relative_to(ROOT / bad):
return False
for good in ("src", "submodules"):
if path.is_relative_to(ROOT / good):
return True
return False
def should_watch_dir(self, entry: os.DirEntry) -> bool:
return super().should_watch_dir(entry) and self.accept_change(entry)
def should_watch_file(self, entry: os.DirEntry) -> bool:
return super().should_watch_file(entry) and self.accept_change(entry)
def cmd(*parts) -> subprocess.CompletedProcess:
return subprocess.run(parts, cwd=ROOT, check=True)
def run_app(args=sys.argv[1:]) -> None:
print("\n\x1b[36m", "─" * term_size().columns, "\x1b[0m\n", sep="")
with suppress(KeyboardInterrupt):
cmd("qmake", "mirage.pro", "CONFIG+=dev")
cmd("make")
cmd("./mirage", "-name", "dev", *args)
if __name__ == "__main__":
if len(sys.argv) > 2 and sys.argv[1] in ("-h", "--help"):
print(__doc__)
else:
(ROOT / "Makefile").exists() and cmd("make", "clean")
run_process(ROOT, run_app, callback=print, watcher_cls=Watcher)
mirage-0.7.2/docs/ 0000775 0000000 0000000 00000000000 14077472336 0013731 5 ustar 00root root 0000000 0000000 mirage-0.7.2/docs/CHANGELOG.md 0000664 0000000 0000000 00000146730 14077472336 0015555 0 ustar 00root root 0000000 0000000 # Changelog
All notable changes will be documented in this file.
The format is based on
[Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to
[Semantic Versioning](https://semver.org/spec/v2.0.0.html).
- [0.7.2 (2021-07-26)](#072-2021-07-26)
- [0.7.1 (2021-03-04)](#071-2021-03-04)
- [0.7.0 (2021-02-28)](#070-2021-02-28)
- [0.6.4 (2020-09-16)](#064-2020-09-16)
- [0.6.3 (2020-09-16)](#063-2020-09-16)
- [0.6.2 (2020-08-28)](#062-2020-08-28)
- [0.6.1 (2020-08-21)](#061-2020-08-21)
- [0.6.0 (2020-07-17)](#060-2020-07-17)
- [0.5.2 (2020-06-26)](#052-2020-06-26)
- [0.5.1 (2020-06-05)](#051-2020-06-05)
- [0.5.0 (2020-05-22)](#050-2020-05-22)
- [0.4.3 (2020-04-03)](#043-2020-04-03)
- [0.4.2 (2020-03-27)](#042-2020-03-27)
- [0.4.1 (2020-03-23)](#041-2020-03-23)
- [0.4.0 (2020-03-21)](#040-2020-03-21)
## 0.7.2 (2021-07-26)
### Added
- Navigation keybinds:
- `Keys.quit` keybind to exit the application, unbound by default
- `Keys.earlier_page` and `Keys.later_page` keybinds to navigate the
pages/chats history, Ctrl+H/Left and Ctrl+L/Right by default
- Mouse button 4/5 can now be used to navigate the history
- `General.wrap_history` setting, affects the behavior of history navigation
- `Keys.Rooms.Direct` section, allowing keybinds to jump to specific rooms
- `Keys.Rooms.oldest_unread`/`latest_unread` to jump to the room with the
oldest or newest unread message, by default Ctrl(+Shift)+U
- `Keys.Rooms.oldest_highlight`/`latest_highlight`, same as above but only
considers rooms where you've been mentioned/replied to/etc, by default
Ctrl(+Shift)+H
- Ignoring users:
- Ignore option in the context menu for room members
- Ignore option when rejecting invites
- Editable ignored users list in account settings
- Invites and messages from ignored users are silently discarded.
Their display name, avatar and presence are removed.
They will also always be placed at the bottom of the room member list.
- Status messages history in the left pane account context menu, and
auto-suggestion for the status field.
The number of saved entries can be controlled with `Presence.saved_status`.
- "Add another account" entry in the top left settings menu
- Copiable room ID field in the room settings pane
- Back button in account settings and server browser when the window is
too narrow to show the side panes
- Escape key handling in the account settings, server browser and
add chat pages
- Support for rendering HTML `
` lines (markdown `---`) in messages
### Changed
- Keybinds:
- `Keys.messages.clear_all` default keybind is now Ctrl+Shift+L
- `Keys.Account.AtIndex` keybinds will consistently move to the corresponding
account settings, instead of skipping to the first room if the account is
expanded in the left pane
- `Keys.messages.open_links_files`(`_externally`): ignore matrix.to
user and room mention links
- Presence:
- Allow using the invisible mode on servers not supporting presence, which
will still prevent sending typing notifications and read marker updates
- Restore any previously set status message when reconnecting after being
offline, unless another one has been set from a different client
- Render set status message striked out while invisible/offline to indicate
that it isn't being broadcasted
- Error popup:
- Multiple unexpected errors will be combined into a single popup, instead
of opening a new one for every error
- Report button now links to Github issues
- More details shown for matrix errors
- Messages:
- Require a space after the `#` for markdown titles
- Render matrix.to URL in messages as shorter hyperlinks
- Left pane rooms:
- Last message display: shorten long "In reply to..." prefixes for the
message to be shown as "↩ : "
- Show the inviter for invites where the room has an explicit name/alias set
- Leave, decline invite and forget room options are merged into an unified
popup
- Raise default `General.tooltips_delay` from 0.5 to 0.7s
- Updated headers UI navigation arrow icons
- Misc UI text changes for shortness and consistency
### Fixed
- Fix error popup appearing when invalid room events appear in syncs
- Fix parsing of URL in messages containing some special characters
- Left pane rooms last message display: fix `> quote` right after another quote
not getting colored
- Fix the forgetting rooms feature
- Fix rendering status messages containing HTML-unsafe characters
- Fix chat bottom bar for invited/left rooms glitching at certain sizes or not
properly updating when the room's state changes
- Prevent theme `animationDuration` property from affecting the speed of
loading spinners, progress bars, server ping indicators and image rotation
button cooldown
- Hopefully fix account presence stuck flickering between two states
## 0.7.1 (2021-03-04)
### Fixed
- Fix loading custom themes when compiled in release mode
- Fix homeserver list errors with aiohttp 3.6.x and less, used in Flatpak
- Various corrections to default config file comments
## 0.7.0 (2021-02-28)
### Added
- **Push rules and notifications support**:
- Add native desktop notifications support
- Add sound effect playback support
- Add button and keybinds to mute all notifications in the running client
- Add notification context menu options to rooms in the left pane
- Add a push rule editor to account settings:
- Control for any rule whether matching messages are
marked as unread, highlighted, trigger a desktop notification,
sound, window alert, or any combination of those actions
- Create custom rules targeting a particular room, message sender,
messages containing certain words or messages matching
advanced conditions
- **New configuration system** replacing the previous `settings.json`,
see the
[documentation](https://github.com/mirukana/mirage/blob/master/docs/CONFIG.md)
for more info
- Rooms in the left pane can now be pinned to the top of the list, using the
added context menu option or config file setting
- Support drag-and-dropping text and files to upload in chats
- Add tooltips to the message read counters, listing who has read a message and
when. Tooltips can also be shown for the keyboard-focused message using a
keybind.
- The chat header now indicates when messages are selected in the timeline,
and offers copy/redact/clear selection buttons
- Add a visible indicator when downloading files
- Add command-line arguments parsing and a `--start-in-tray` option, see
`mirage --help`
- Support for HTTP and SOCKS5 proxies, can be set in config file or using the
`http_proxy` environment variable
- Hovering on stability percentages in the sign-in page's homeserver list
now shows more detailed tooltips about the server's recent downtimes
### Changed
- Config files and theme (with the exception of `accounts.json`) are now
automatically reloaded when changed on disk
- The top-left settings button now opens a menu giving access to the
settings folder, theme folder and developer console
- Clicking on the "Mirage x.y.z" text in the top left no longer opens the
github page
- Merge the "Encryption" and "Sessions" account settings tabs into a new
"Security" tab
- Developer console improvements:
- Improve default colors and provide clearer separation of different
commands's outputs
- Support multi-line input, use shift+return to insert a newline
- The output text can now be selected and copied
- Improve room page loading speed
- In the left pane, lock the position of the room corresponding to the
currently visible chat page if any.
This fixes annoyances like clicking on a room with unread messages only to
see it immediatly fly down the list, potentially outside of scrolling view.
- When replying to a message, pressing the reply keybind again while focusing
on that message will now cancel the reply
- Make user ID in account settings a copiable read-only text field
- Hide useless context menu entries for read-only text fields (undo/paste/etc)
- Make the scroll to top/bottom keybinds work faster for long timelines and
be more accurate
- Better explain why not all selected messages can be removed in the
message removal confirmation popup
- When clicking on an account in the top left account bar or using the
previous/next account keybinds, focus the account settings instead of
the account's first room
- While keyboard-focusing an image message, hide its sender and time bubbles
as if it was hovered by mouse
- Color key words in invite/leave/forget/error popups instead of using italic
- Apply theme radius on context menus
- Theming:
- Reduce default `fontSize.big` from `22` to `20`
- Change the default style of room unread indicators
- Add new properties to the `mainPane.accountBar.account.unreadIndicator`
and `mainPane.listView.room.unreadIndicator` sections, see
[620b5815](https://github.com/mirukana/mirage/commit/620b58151d7d9d15e242402da34ef55a05549ca5#diff-fdb828d814eca61316a31204666263a410da6dd9c1cf0099dbf54da9e82e33e1)
### Fixed
- Fix build failing on Python 3.9 due to incompatible `blist` dependency
- Fix event context menu "Reply" option targetting the wrong message
- Fix read counter on image events lacking color and having extra padding
- Prevent opening multiple instances of the same context menu by right clicking
or using keybinds
- Fix current page not being highlighted in the left pane when Mirage starts
and the initial page to load is an account settings page
- Fix list delegates (especially left pane rooms) occasionally appearing as
invisible items
- Fix incorrect user ID text hue in account settings
- Close the reply bar when switching to another room while composing a reply
- Fix "Copy link address" entry in message context menu not being visible
- Fix some characters being rendered incorrectly in redacted messages reasons
(e.g. `` was shown as `<test>`)
- Fix cancel button in the "Join Room" page not returning to previous page
- Fix Matrix server errors lacking a `M_CODE` triggering an account logout
- Fix "Go to previous/next unread/highlighted room" keybinds ignoring rooms
with a local unread counter ([!] markers)
- Fix copying multi-line mouse-selected rich text, newlines were not preserved
- Prevent warnings spam when the XScreenSaver protocol is available but not
supported, e.g. when running in XWayland
- Fix message timeline occasionally breaking and mixing messages from multiple
rooms when switching room
- Show an error when loading a JSON config file fails instead of silently
failing and using a default configuration, which can potentially overwrite
user files
- Fix "focus previous/next message" keybinds sometimes skipping messages and
focusing the middle of the screen while the timeline scrolling
was at the bottom
- Fix read marker updates sometimes getting stuck and never clearing the unread
message counts for a room
- Fix scroll keybinds not working when kinetic scrolling is disabled
- Fix chat right pane having an invisible 10px edge when hidden/collapsed,
interfering with any button in the way
- Fix the "expand right pane" button failing to bring back the pane and
turning the chat room header invisible
- Fix "open debug console for this message" keybind erroring
- Prevent horizontal dragging of flickable column layout pages
- Fix scrolling keybinds not working to scroll popups
- Revert 0.6.2's message combining fix, which caused message bubble movements
to randomly stop in the middle of their animations and be left at odd
positions or overlap with other bubbles
### Known Issues
- Flatpak does not seem to support direct ALSA access, sound notifications
might not work within it
- Desktop notifications within Flatpak might not work out of the box when
Xorg is launched without a display manager, try running
`export $(dbus-launch --autolaunch "$(cat /var/lib/dbus/machine-id)")`
before launching Mirage in a terminal.
## 0.6.4 (2020-09-16)
### Fixed
- Fix checkboxes in the room settings not having their default values updated
after switching room
- Fix various minor features broken on Qt 5.12 and the AppImage since v0.5.2
## 0.6.3 (2020-09-16)
### Added
- Add a **system tray icon**.
A left click will bring up the Mirage window,
middle will quit the application and right will show a menu with these
options.
- Add a `closeMimizesToTray` setting to the config file, defaults to `false`.
Controls whether closing the Mirage window will leave it running in the
system tray, or fully quit the application.
- Add a discrete **read marker indicator** to messages, shows how many people
have this event as their last seen one in the room.
A way to see who read the message and when will be added in the future.
- Themes: add `chat.message.localEcho` and `chat.message.readCounter` color
properties
- Add a `zoom` setting, defaults to `1.0`
- Add a `lexicalRoomSorting` setting, to sort rooms by their name instead of
recent activity.
A restart is needed to apply changes to this setting.
### Changed
- Restrict Mirage to a single instance per config folder, trying to launch a
new window will instead focus the existing one.
The `MIRAGE_CONFIG_DIR` and `MIRAGE_DATA_DIR` environment variables can be
set to run different "profiles" in parallel.
- Reduce the visible lag when opening a chat page, switching rooms should be
a lot smoother
- When using the `focusPreviousMessage` and `focusNextMessage` keybinds, if no
message is focused and the timeline has been scrolled up,
focus the message in the center of the view instead of returning to the
bottom of the timeline and focusing the last one.
- Don't re-center the room list on clicks by default.
This prevents the list from jumping around every time a room is selected.
The previous behavior can be restored with the new `centerRoomListOnClick`
setting.
- Show a better terminal error message than "Component is not ready" when the
window creation fails, giving details on what went wrong in the code
- If an account's access token is invalid (e.g. our session was signed out
externally), say so with a popup and cleanly remove it from the UI,
instead of spamming the user with errors.
- Rename message context menu option "Debug this event" to just "Debug"
- Unify up/down and (shift+)Tab navigation for the account Sessions page
- Changes to the UI scale/zoom via keybinds are now persisted across restarts
- Themes: `uiScale` is now bound to `window.settings.zoom`.
This change is necessary to keep the zoom keybinds working.
### Fixed
- Midnight theme: fix missing `}` from change to the `chat.message.styleSheet`
property introduced in 0.6.2, see
[2a0f6ae](https://github.com/mirukana/mirage/commit/2a0f6aead17d05fd35e8a944e5434781e9c08d50).
- Fix multiple consecutive one-line events (/me emotes, "x joined", etc)
not combining properly
- Fix theme finder ignoring the `MIRAGE_DATA_DIR` environment variable
- Fix theme background image not updating when reloading theme/settings
- Fix up/down keys not working when the text cursor is in a word starting
with `@`, but the word doesn't match any usernames to complete.
- Fix context menu copy options for messages containing URL thumbnails
- Fix context menu copy option for single non-message events
- Fix GIF URL thumbnails not being animated in the timeline
- Fix image viewer sizes shown as "0x0" for loading images and GIFs
- Fix incorrect sync filter usage introduced in 0.6.1, which caused problems
like redaction events never arriving
- Fix redacted media messages keeping their thumbnails
- Fix terminal warnings when uploading to a non-encrypted room
- Fix some cases of undetected power level changes, e.g. a muted user
(level -1) going back to the default (level 0).
- Don't show popup for `400 M_UNRECOGNIZED` errors that can occur when trying
to fetch an offline user's presence
- Focus the filter field again when exiting a room member profile page
## 0.6.2 (2020-08-28)
### Changed
- When replying to a message, you can now press enter without entering any
text to send it directly (useful to "forward" a message).
- Sending a file while replying to a message will create a pseudo-reply,
consisting of an "In reply to" text message with no body, followed by the
actual file event.
This is a workaround to the reply restrictions imposed by the Matrix spec.
- **Composer aliases cannot contain whitespace anymore.**
This includes spaces, hard tabs or newline characters.
If an alias from your config still has whitespace, only the first word
will be taken into account (ignoring any leading or trailing space).
- Faster server browser loading, now gathers all needed data with a
single request instead of one for each server
- Auto-focus the "Join" button on invited room pages
((Shift+)Tab can be used to navigate between buttons)
- Auto-focus the "Forget" button on left room pages
- Themes: modify `chat.message.styleSheet` to add some spacing between HTML
list items, see
[48663ae](https://github.com/mirukana/mirage/commit/48663ae8465e90646855435b47b89c01395ae4d9)
### Fixed
- Fix @username autocompletion closing if there's more than one character
after the @
- Consider the partial text from IME (input method editors) and touch screen
autocompleting keyboards for username autocompletion
- Reset IME state upon autocompleting a username
- Fix clicking on autocompletion list user not making the username a mention
- Fix UI freezing when mentioning user lacking a display name
- Fix mentioning users with blank display name (e.g. only spaces), mention
them by their user ID
- Fix text fields/areas unable to be focused on touch screen
- Fix random chance of profile retrieval requests failing if one of the logged
in account doesn't federate with other servers (e.g. localhost synapse)
- Fix composer text saved to disk for the wrong account if that text begins
by an account alias
- Servers can potentially return an outdated member list for rooms on initial
sync, which is one of the possible cause of "Members not synced" error for
encrypted rooms.
When loading the full room list, discard members from the initial sync list
that are absent from the full list.
For those not using the AppImage or Flatpak,
this fix requires **matrix-nio 0.15.1** or later to take effect.
- When erasing an account alias inside the composer, send a
"x isn't typing anymore" notification corresponding to that account
- Fix potential 403 error on chat pages for invited rooms.
- Start loading room history immediately when the room join state changes,
e.g. when clicked "Join" for an invited room page.
## 0.6.1 (2020-08-21)
### Added
- **SSO authentication** support
- **Homeserver browser**:
- To add a new account, you will be asked first to pick one of the
listed public server
(list data from [anchel.nl](https://publiclist.anchel.nl/))
or to manually enter a server address
- Typing in the server address field will also filter the public server list,
Up/Down or (Shift+)Tab and Enter can be used to navigate it by keyboard
- If the address doesn't have a `scheme://`, auto-detect whether the server
supports HTTPS or only HTTP
- Use the .well-known API if possible to resolve domains to the actual
homeserver's URL, e.g. `matrix.org` resolves to
`https://matrix-client.matrix.org`
- The server address field will remember the last homeserver that was
connected to
- **Room members autocompletion**:
- Type `@` followed by one or more characters in the composer,
or one or more characters and hit (Shift+)Tab to trigger username/user ID
autocompletion
- Only autocompleted names will be turned into mentions, unlike before
where any word in a sent message that happened to be someone's name would
mention them
- **Full image viewer** for matrix image messages and URL previews:
- Click on a thumbnail in the timeline to open the image viewer
- Middle click on a thumbnail (or use the option in the context menu)
to open the image externally
- Left click on the image (mouse only): expand to window size if the
image's origin size is smaller than the window,
else expand to original size
- Tap on the image (touch screen/pen only): reveal the info and button bars
when auto-hidden (bars will auto-hide only when they overlap with a big
enough displayed image)
- Any mouse movement: reveal auto-hidden bars
- Double click on the image: toggle full screen
- Middle click anywhere: open externally
- Right click anywhere: close the viewer, back to chat
- Drag when displayed image is bigger than window to pan
- Wheel to pan up/down, hold shift or alt to pan left/right
- Ctrl+wheel to control zoom
- Buttons to control rotation, scale mode, full screen, GIF play/pause
and GIF speed
- New keyboard shortcuts are available for all these actions,
see `keys.imageViewer` in the config file (will be automatically updated
when you start Mirage 0.6.1)
- Add `media.openExternallyOnClick` setting to swap the new
click and middle click on thumbnails behavior
- Add `openMessagesLinksOrFilesExternally` keybind, by default Ctrl+Shift+O
- Add `copyFilesLocalPath` keybind, by default Ctrl+Shift+C
- Room and member filter fields now support (Shift+)Tab navigation, in addition
to Up/Down
- Add a colored left border to the currently highlighted item in list views
(e.g. room list, members list, etc) to improve visibility
- Themes:
- Add `controls.listView.highlightBorder` and
`controls.listView.highlightBorderThickness` properties (can be set to `0`)
- Add the `chat.userAutoCompletion` section
### Changed
- Messages context menu:
- Use a cleaner icon for the "Copy text" entry
- Replace the confusing broken "Copy media address" entry with:
- Copy media address: visible for non-encrypted media, always
copies the HTTP URL
- Copy local path: always visible for already downloaded media, even if
they were downloaded before mirage was started
- The `openMessagesLinks` keybind (default Ctrl+O) is renamed to
`openMessagesLinksOrFiles` and can now also open media message files
- Using the `openMessagesLinksOrFiles` keybind on a reply will now ignore the
matrix.to links contained in the "In reply to XYZ" header
- Pressing Ctrl+C to copy selected/highlighted non-encrypted media messages
will copy their HTTP URL instead of the filename
- Retry downloading image thumbnails if they fail with a 404 or 500+ server
error (uploads sometimes take a few seconds to become available on the
server)
- Non-encrypted media messages are now always downloaded on click and opened
with a desktop application (or the image viewer), instead of
being opened in a browser
- Compress thumbnails and clipboard images in a separate process, to avoid
blocking every other backend operation while the compression is running
- Reduce the level of optimization applied to clipboard images,
the previous setting was too slow for large PNG (10MB+)
- Increase applied scrolling velocity when using the
`scrollPageUp`/`scrollPageDown` keybinds, now similar to how it was before
Mirage 0.6.0
- Don't catch SIGQUIT (Ctrl+\ in terminal) and SIGTERM signals,
exit immediately
- Slightly increase the top/bottom padding to the multi-account bar in the
left pane
- Dependencies: minimum nio version bumped to 0.15.0
### Removed
- Themes: remove unused `controls.listView.smallPaneHighlight` property
### Fixed
- Don't show account avatar tooltips when the context menu is open
- Don't automatically focus member power level control when grayed out
- Fix uploading files for servers not telling us their maximum allowed
file size
- Fix message context menu "Copy text": when an event was highlighted with
the keyboard, right clicking a message and clicking "Copy text" would always
copy the message that was highlighted instead of the one the user aimed for.
- Fix pressing menu key in chat opening both the composer's and the timeline's
context menus
- Fix random chance of failure when fetching thumbnails or user profiles and
an account other than the current one is offline
- Catch potential 403 errors when fetching presence for offline room members
- Fix room right pane stealing focus from opened popup when resizing the window
from narrow/mobile mode to normal mode
- Never try to send typing notifications in rooms where we don't have
permission to talk
- Fix clipboard upload preview popup not updating when the copied image changes
- Fix some pages not respecting `enableKineticScrolling: false` setting
- Fix truncated "Loading previous messag..." text in timeline
- Fix possible race condition corrupting user config files on write
- Fix missing member events from initial syncs, also fixes some cases
of the "Members not synced" error occurring in encrypted rooms where members
have recently joined or left.
- Fetch missing member display name when displaying last messages in room pane
for rooms that haven't had their members list fully loaded yet
- Use uploaded sync filter IDs in sync requests instead of passing a long
JSON object in the URL every time, which caused problems on some servers with
a short URL length limit (e.g. halogen.city)
- Fix autolinking user IDs that include `;` or `<` characters
- Ignore enter keypresses in pages or popups when the accept button is grayed
out
- Fix never-ending spinner in left pane when logging in to an account that was
already connected
## 0.6.0 (2020-07-17)
### Added
- **Room member profiles**:
- Can be accessed by clicking on a user in the room's right pane, or focusing
the filter field and navigating with up/down/enter/escape
- Includes large avatar, display name, user ID, **presence** info,
**power level control** and **E2E sessions list**
- **E2E Verification**:
- Sessions for room members can now be (manually) verified from
their profile
- Sessions for different accounts within the same client will automatically
verify each others based on session keys
- Verifying a session will automatically verify it for all connected accounts,
as long as the session keys are identical
- **Presence**:
- Added presence (online, unavailable, invisible, offline) and status
message control to the accounts context menu in the room list
- Added `togglePresence{Unavailable,Invisible,Offline}` keybinds bound by
default to `Ctrl+Alt+{A/U,I,O}`
- Added `openPresenceMenu` keybind to open the current account's context
menu, `Alt+P` by default
- The room member list is now sorted by power level, then presence, then name
- The room member list will display presence orbs and last seen time for
members if the server supports it. Last seen times for offline members
are also automatically retrieved as needed.
- Set logged in accounts offline when closing Mirage
- Linux/X11 specific: Add auto-away feature configurable by the
`beUnavailableAfterSecondsIdle` setting (default 600 for 10mn),
can be disabled by setting it to `-1`.
**This requires the libX11 and libXScrnSaver/libXss developpment headers
installed, see INSTALL.md for more info**.
The dependencies and support for this feature can be disabled at
compile-time.
- **Session sign out**: you can now sign out your other sessions from the
account settings. This currently only supports password authentification.
- **Pasting images** via Ctrl+V or composer context menu, shows a preview of
the image before uploading
- Added basic keyboard navigation for account settings session list:
- Up/down: highlight previous/next session
- Enter/Return/Menu: open highlighted session menu
- Space: check or uncheck highlighted sessions
- Escape: uncheck all sessions
- Alt+R/F5: refresh list
- Alt+S/Delete: sign out checked sessions, or all sessions if none checked
- Add a verified devices indicator to encrypted room headers
- Add experimental support for rendering of inline images and custom emotes in
messages
- Add `kineticScrollingMaxSpeed` and `kineticScrollingDeceleration` settings
- When highlighting accounts, rooms or members in lists
(focus filter field and use up/down), the highlighted item's context menu
can now be accessed with the keyboard Menu key
- Support for Menu key when keyboard-navigating messages in the timeline
- Add context menus to text field and areas
- Add a button to quickly expand the room pane when collapsed and focus
the filter field
- Clicking on the current tab button for the room pane now fully hides it,
this can also be toggled with the new `toggleHideRoomPane` keybind
(default Ctrl+Alt+R)
- Themes:
- Add the `controls.presence` section
- Add `mainPane.listView.offlineOpacity` property
- Add CSS styling for `table` and `td` in the `chat.message.styleSheet`
property
### Changed
- When panes are smaller than their default width due to user resizing or
window size constraints, focusing certain elements will auto-expand them
until the focus is lost: filter fields, member profile and room settings
- Reduced the default kinetic scrolling speed, which was hardcoded to an
aggressive `4000` before.
This can be restored with the `kineticScrollingMaxSpeed` setting.
- Improve key verification popup texts and make the session details copiable
- Power levels/room permission change events will now show a line of text or
table containing the details of what exactly changed
- Messages containing tables will no longer be width-limited
- Using the `sendFileFromPathInClipboard` keybind (default Alt+Shift+S)
now shows a preview of the file if it's an image and asks for confirmation
- Image messages now show spinners when loading the thumbnail
- Clicking on a GIF message will now open it externally like other images
instead of pausing it. A dedicated play/pause button is now displayed in
the corner.
- Themes:
- Update the `colors.positiveBackground`, `colors.middleBackground` and
`colors.negativeBackground` properties to be brighter and have full opacity
- Increase the opacity for the `menu.background` color (context menu), the
previous value made it very hard to read in certain situations
### Removed
- Themes: removed the `image` section and its `maxPauseIndicatorSize` property,
no longer used since the GIF changes
### Fixed
- Fix parsing user/room ID and room aliases containing dashes in messages
- Fix responding to own messages sending an incorrect event ID to other clients
- Fix plain text body of replies sent from Mirage
- Fix high CPU usage due to the "Loading messages..." animation still being
rendered when invisible
- When logging in to an already connected account, redirect to the account
settings page instead of overwriting it and losing the previous session
- Fix signing out of an account leaving all its room in the room list
- Fix all keybinds becoming disabled until next restart if a popup or menu
is destroyed instead of being properly closed
- Fix pressing left/right arrow to deselect text in fields and areas when the
cursor is positioned at the beginning/end
- Fix missing text for events involving display names that contain `< >`
characters and other dangerous characters interpreted by HTML
- Fix sending a typing notice indicating we stopped typing when the composer
is cleared (e.g. when erasing all text or sending a message)
- Fix hovering image messages not setting the pointing hand cursor
- Opening a context menu and clicking at the exact spot where it was opened
without having moved the cursor will now close the menu instead of doing
nothing
- Highlight the correct room list item when adding a new account, going
to account settings or ctrl+tabbing to the "add new chat" page
- Fix right room pane being shown as overlay sometimes in small window mode
- Fix avatar membership icon (crown/star) position when the room pane is small
- Correctly handle SIGINT (ctrl+c in terminal), SIGTERM, SIGHUP and SIGQUIT
to exit Mirage
- Fix opacity of topic area in room settings when disabled due to lack of
permission
- Fix GIF only having a cropped portion of their content rendered
- Hide the "recursive layout" warnings spam in terminal that appeared
in Qt 5.14
## 0.5.2 (2020-06-26)
### Added
- **Sessions/device list**: you can now inspect, rename, manually verify and
blacklist your devices from the account settings page.
The interface is still work in progress, keyboard navigation and signing
out sessions will be added in a next version.
- Re-add client-side unread/highlight room indicators.
If your account has push notifications disabled, which precise cross-client
counters depend on, the local indicators will be used as fallback.
- Support the `MIRAGE_CACHE_DIR` environment variable to override where
files and thumbnails are downloaded
- Themes:
- `colors.positiveText` property
- `mainPane.listView.room.unreadName` property
- In the `controls` section:
- `scrollBar` section
- `button.focusedBorder` and `button.focusedBorderWidth` properties
- `tab.focusedBorder` and `tab.focusedBorderWidth` properties
- `textArea.borderWidth`, `textArea.border`, `textArea.focusedBorder` and
`textArea.errorBorder` properties
### Changed
- Overhauled account settings to match the design of other tabbed pages.
The horizontal layout design has been removed due to complicated code and
being impossible to extend without breaking it.
- The display name field in account settings is now colored,
preview your new display name's color as you type
- For rooms without image avatars set, the room settings's avatar color now
responds to the name field as you type
- Overhauled scrollbars:
- Now match the Mirage theme and much better visibility
- No more right margin for the timeline's bar
- Minimum height to prevent the bar from becoming impossible to grab
- Use brighter text for room names of rooms that have unread messages
- Buttons, tabs, text fields and areas now have animated bottom borders
to represent keyboard focus instead of being highlighted like when hovered
- Text fields and areas can now have rounded corners, following the theme
- Tabbed pages (Sign In, Add Chat, etc) can now be swiped left and right
- Popups can now be scrolled when their content is bigger than the
window's height
- Replace most generic checkmark icons for apply buttons in popups
- Pressing escape in forms will consistently trigger corresponding
cancel buttons
### Fixed
- Fix `Connections` deprecation warning on Qt 5.15
- Skip invisible entries when navigating context menus with up/down arrows
- Fix tab focus for unhandled error and invite to room popups
- Fix guest access event saying that guest access has been allowed when it
has actually been forbidden
- Deselect any selected message before clearing a room's events, not doing so
made the gone messages impossible to deselect.
- Properly center some previously offset popups
## 0.5.1 (2020-06-05)
### Added
- **Saving room settings**: room name, topic, guest access, invite requirement,
guest access and encryption can now be changed and saved from the room's
settings pane
- `markRoomReadMsecDelay` setting to configure how long in milliseconds Mirage
will wait before marking a focused room as read, defaults to `200`
- `alertOnMentionForMsec` setting separate from `alertOnMessageForMsec`,
defaulting to `-1`: will trigger a non-expiring window highlight on
messages received that mention your user
(the behavior differs depending on desktop environment or window manager)
### Changed
- **Unread message/highlight counters**:
- The counters are now implemented in a cross-client, persistent way,
and respect configured push rules for your account
- Read receipts will be sent to the server to mark rooms as read
- The `alertOnMessageForMsec` setting now defaults to `0`, disabling window
highlights for messages not mentioning you
- While an E2E key import operation is running, prevent accidentally closing
the popup by clicking outside of it
- For manual installations, `make install` will now copy files to `/usr/local`
instead of `/usr` by default.
This can be changed by setting `PREFIX` when running `qmake`,
e.g. `qmake PREFIX=/usr`.
After pulling the latest version, make sure to clean up old installation
and build files before regenerating the Makefile and installing:
`sudo make uninstall; make clean; qmake && make && sudo make install`
- Improve the error messages shown when trying to start a direct chat with or
invite a non-existing user
- In room settings or creation, use a text area for the topic instead of a
field limited to a single line
### Removed
- Removed delay when multiple rooms are removed/hidden from the list.
This should provide a smoother experience when filtering rooms or collapsing
accounts, and prevent the account duplication bug.
If you encounter issues with these operations like the room list becoming
invisible, make sure first that your Qt installation is up-to-date
(latest x.y.Z version, e.g. 5.14.2).
### Fixed
- The room settings pane is now scrollable
- Avoid potential error if the room list data model is initialized after an
initial sync has already been completed
- Closing the import key popup by pressing escape will now correctly
cancel any running import operation
- Fix Python pickling error when trying to re-decrypt events after importing
E2E keys ([#50](https://github.com/mirukana/mirage/issues/50))
- Handle Matrix 502 errors returned when trying to start a direct chat or
invite a user with an incorrect or unresponsive server in their ID
- Correctly hide `socket.gaierror` error popups that appear when the
internet connection drops
- Hide popups for pointless
`ssl.SSLError: [SSL: KRB5_S_INIT] application data after close notify`
exceptions that occur in the Flatpak releases due to a Python 3.7 bug
- Make sure the account shown in the left pane is immediately updated
after changing display name or avatar in the account settings
- When signing in a new account, correctly position it after the other
existing ones without needing a restart
- Correctly handle room topics containing new lines, hard tabs or text inside
`<>` brackets
- Starting a direct chat, creating or joining a room will now correctly
update the left pane room list's highlighted item
- Fix `KeyError` when forgetting a room
- Fix cursor shape not changing to caret when hovering text fields and areas.
This fix can only apply when the `enableKineticScrolling` setting is `true`,
until the project switches to Qt 5.15.
## 0.5.0 (2020-05-22)
### Added
- **Unread messages and mentions**:
- Rooms in the left pane will now have a counter for unread messages and
times you were mentioned
- `goToPreviousUnreadRoom` (default Alt+Shift+U) and
`goToNextUnreadRoom` (default Alt+U) keybinds to cycle between rooms
with unread messages
- `goToPreviousMentionedRoom` (default Alt+Shift+M) and
`goToNextMentionedRoom` (default Alt+M) keybinds to cycle between rooms
with mentions, or those with unread messages if no rooms with mentions
are left
- Room with mentions will be sorted first, then room no mentions but unread
messages, then the rest
- **Accounts navigation**:
- With two or more accounts, an always visible account thumbnail grid will
be visible in the left pane.
Clicking on an account will make the room list jump to that account.
The accounts will also show a total number of unread messages and
mentions for all the rooms associated with it.
- `goToPreviousAccount` (default Alt+Shift+M) and
`goToNextAccount` (default Alt+M) keybinds to cycle and jump between
accounts in the room list.
- `keys.focusAccountAtIndex` in config file, a `{"": ""}`
mapping similar to `focusRoomAtIndex` which by default binds
Ctrl+1-9 and Ctrl+0 to jump to account 1 to 10 in the room list
- **Replies**:
- The context menu for messages now has a "Reply" option
- The new `replyToFocusedOrLastMessage` keybind (default Ctrl+Q) can be used
to reply to the focused message if any
(use the `focusPreviousMessage` and `focusNextMessage` keybinds),
or to the last message in the timeline not sent by you.
- Pressing escape will cancel the reply
- **Kick and bans**: room members can now be kicked or banned with an optional
reason, using the option in the right pane's member context menu
- `openMessagesLinks` keybind (default Ctrl+O).
Will open externally all the URLs present in the selected/focused message(s),
or the last message that contains links if none are selected or focused.
- `clearMemberFilterOnEscape` setting.
If `true` (default),
pressing escape while focusing the "Filter members" field will not only
focus the chat again but also clear the filter.
- `maxMessageCharactersPerLine` setting to control the maximum width of
messages. If set to `-1`, there will be no limit.
- `ownMessagesOnLeftAboveWidth` setting, replaces the themes's
`eventList.ownEventsOnRightUnderWidth` properties.
Can be set to `-1` to always keep your own messages on the right.
- `enableKineticScrolling` setting, try setting it to `false` if you have
scrolling issues on a trackpad
- Support a new `enabled` key for accounts in the accounts.json config file.
If set to `false`, Mirage will not login to or show the account on startup.
- Support a new `order` key for accounts in the accounts.json config file
The value is an integer that will determine how accounts in the left pane
are sorted, lower comes first.
If multiple accounts have the same `order` value, they are sorted by
their user ID.
- Themes:
- `mainPane.minimumSize` property
- `mainPane.accountBar` section
- `mainPane.listView.room.unreadIndicator` section
- `chat.replyBar` section
### Changed
- **Performance**:
- Use room members lazy-loading, accounts that have joined
large numbers of rooms will now finally be able to finish their
initial sync.
When the currently shown UI page is a room, the full members list for it
will be loaded.
- Request less events for the initial sync, and exclude some types like
membership events to increase initial sync speed
- Retrieving profiles for events sent by users no longer present in a room
will no block and delay past events loading.
Missing profiles will be fetched asynchronously when the messages
are currently in view in the UI.
- Reduce the number of events that need to be sent between Python and QML
due to changes in list models data
- Consecutive syncs will now have a one second delay between them to reduce
both client and server strain
- Improved group display name calculations (nio 0.11+ change):
for example, a room that would previously be shown as "Alice and 6 others"
will now be shown as "Alice, Bob, Carol, Dave, Erin and 1 other"
(up to 5 visible names).
- Group rooms with more than two users and without an explicitely set avatar
will no longer show their first member's profile picture as avatar
- The `unfocusOrDeselectAllMessages` keybind now defaults to Ctrl+D
instead of Escape, which no longer works as of Qt 5.14.
`debugFocusedMessage` is changed from Ctrl+D to Ctrl+Shift+D.
- Better QML logging format: messages will now be dated, and have a
symbol + color (on Linux and OSX terminals) representing their category
- Messages containing code blocks will no longer have their max width limited
- Set `hideUnknownEvents` to `true` in the default config file
- Set a more useful default minimum size for the left pane
- The `collapseSidePanesUnderWindowWidth` setting now defaults to `450` instead
of `400`, to account for the larger minimum pane size.
- Show a more useful error message with traceback when retrieving an account's
profile or the server config fails on startup
- Hide `socket.gaierror` error popups
- When pressing the `startPythonDebugger` (default Alt+Shift+D) keybind,
use `pdb` if `remote_pdb` isn't installed
- Themes:
- `mainPane.bottomBar` properties: `background` is now by default
`transparent`, `settingsButtonBackground` and `filterFieldBackground` are
now set to `colors.strongBackground`
### Removed
- **Performance**:
- After the initial sync, Mirage will no longer try to continually fetch
previous events for rooms where the sync haven't brought any event that is
suitable to be shown as room last event subtitle in the left pane.
- Mirage will no longer try to find and autolink display names in incoming
events, which was a very costly operation for rooms with
thousands of members.
- The uvloop python module is no longer supported or recommended as an optional
dependency, due to being responsible for some segfaults
- The SortFilterProxyModel and RadialBarDemo git submodules are no longer
used. hsluv-c is the only submodule still used currently.
### Fixed
- **Performance**:
- Stop rendering and keeping in RAM rooms that aren't currently visible in
the left pane.
This fixes the massive memory usage that occurred with hundreds of rooms
and their avatar images loaded all at once.
- Room elements in the left pane will no longer be reloaded every time
a list movement happens (e.g. a room is bumped to the top due to a new
message).
This also lets the movement animation correctly play instead of being
skipped.
- Don't show a popup when pressing the redact message keybind if that
message can't be redacted
- Stricter mention parsing, fix various cases of text being autolinked when it
shouldn't
- Fix exception when parsing `` HTML tags without `href` attribute
- Fix crash on Python 3.6 due to `asyncio.current_task`
- Fix `AttributeError` when using matrix-nio v0.11+
- Fix potential crash on startup due to asyncio event loop and threading
- Fix uploads getting rejected by servers due to not passing a file size
- Fix extra spacing between "Add chat" and "Expand/Collapse" account buttons
- Hide the Binding deprecation warnings in terminal that Qt 5.14+ spams
- Fix client not waiting before retrying a failed sync due to server error
- Correctly handle server 429 "Too many requests" errors when they come purely
in the form of a HTTP status code without a JSON object giving any info
- Fix left rooms remaining at full opacity in the left pane
- Fix escape key not working to clear the "Filter rooms" field and focus
the chat again
- Fix event mention link detection, and stop trying to autolink event ID
strings in messages as matrix.to URLs also need a room ID to make sense
## 0.4.3 (2020-04-03)
### Added
- Support for `MIRAGE_CONFIG_DIR` and `MIRAGE_DATA_DIR` environment variables
to change the config and user data folders
- `inviteToRoom`, `leaveRoom` and `forgetRoom` keybindings
(Alt+I, Alt+Esc and Alt+Shift+Esc by default)
- **Redactions support**: individual or selected messages can now be
redacted/removed using the option from the message context menu,
or the `removeFocusedOrSelectedMessages` keybind
(by default Ctrl+R or Alt+Del).
- Themes: `colors.dimColoredTextSaturation` and
`colors.dimColoredTextIntensity` color properties
- Themes: `controls.displayName.dimSaturation` and
`controls.displayName.dimLightness` color properties
- Themes: `chat.message.redactedBody` color property
### Changed
- `unfocusOrDeselectAllMessages` keybind: now deselect messages first if any
on first press, *then* cancels the keyboard message focus if possible on
second press
### Fixed
- Segfault after login on KDE
- Buttons not displaying correctly on Qt 5.14
- Hard tab characters in theme files not being handled by the theme parser
- `focusRoomAtIndex` keybindings: default to Cmd+numbers on OSX instead of
Alt/Option+numbers, which prevented typing special characters on some
keyboard layouts
- Needing to press escape twice to close context menus and popups
- "Go back to chat" button not doing anything when the room settings pane was
focused in narrow mode
## 0.4.2 (2020-03-27)
### Added
- Accounts, rooms, room members and messages can now be long-tapped on touch
screens to open their context menu
- New touch screen and keyboard-friendly message selection system, replaces
the previous slow and buggy text selection implementation:
- Tap a message to select or deselect it
- Press escape, or use the context menu entry "Deselect all" to deselect
all messages
- Tap a first message, then shift+tap another one
(or use "Select until here" from the context menu) to select all messages
from the first to last
- With a mouse, a single message can be partially selected and copied
- The keyboard can be used to navigate with Ctrl+Up/Down (or Ctrl+J/K),
Ctrl+Space to (de)select, Ctrl+Shift+Space for first-to-last selection,
Ctrl+C for copying the selection, and Escape to focus the composer again
(twice to also deselect messages).
These shortcuts can be changed in the config file.
- Themes: `chat.message.focusedHighlight`,
`chat.message.focusedHighlightOpacity`, `chat.message.checkedBackground` and
`chat.message.thumbnailCheckedOverlayOpacity`
- Scripts and instructions to build a Flatpak package
The new selection system is still work in progress, dragging to select multiple
messages at once on desktop is not implemented yet.
### Changed
- Themes: increased default `colors.accentBackground` brightness
### Fixed
- Possible error when handling a room member event that is missing previous
display name or avatar info
- Correctly parse `mailto:` links where the mail address ends with a digit
(e.g. `mailto:foo@localhost:8050`, or where the host is a single character
- Respect case when turning display names into mentions, typing a display name
containing uppercase letters all in lowercase would result in a broken link
- Correctly handle `0` as a value for the `alertOnMessageForMsec` setting,
this will now prevent urgency hints (window/desktop highlighting or flashing
on new message for most desktops, "ready" notification on Gnome)
## 0.4.1 (2020-03-23)
### Added
- `hideMembershipEvents` setting, controls whether events such as
"x joined the room" are shown in the timeline.
- `hideProfileChangeEvents` setting, controls whether display name and avatar
change events are shown in the timeline.
- `hideUnknownEvents` setting, controls whether events not yet supported by
Mirage (e.g. `m.reaction`) are shown in the timeline.
- Compact mode to make accounts, rooms, messages and room members take only
one line as well as reducing vertical spacing between them.
Set by the new `compactMode` setting in config file, can also be toggled
with the `keys.toggleCompactMode` keybind which defaults to Alt+Ctrl+C.
- `keys.focusRoomAtIndex` in config file, a `{"": ""}` mapping
which by default binds Alt+1-9 and Alt-0 to focus room 1 to 10
in the current account.
- User ID, display names, room ID, room aliases and message ID are now
automatically turned into [matrix.to](https://matrix.to) links and will be
rendered as mentions by clients.
In Mirage, user ID/names will be colored with the same color seen when they
send messages.
- Track the number of times your user was mentioned in rooms.
The visual counter is not yet displayed, since there currently is no way
to mark messages as read and make the counter go down.
- Themes: `controls.avatar.compactSize` property
- Themes: mention classes styling to `chat.message.styleSheet`
### Fixed
- Python exceptions occurring in the asyncio loop not being printed in
the terminal
- Extra newline shown after code blocks in messages
- Constant CPU usage due to button loading animations still being rendered
while unneeded and invisible
## 0.4.0 (2020-03-21)
Initial public release.
mirage-0.7.2/docs/CONFIG.md 0000664 0000000 0000000 00000007712 14077472336 0015227 0 ustar 00root root 0000000 0000000 # Configuration
[Folders](#folders) ⬥
[settings.py](#settingspy) ⬥
[accounts.json](#accountsjson)
## Folders
On Linux:
- `$XDG_CONFIG_HOME/mirage` if the `XDG_CONFIG_HOME` environment variable is
set, else `~/.config/mirage` for config files
- `$XDG_DATA_HOME/mirage` if that variable is set, else `~/.local/share/mirage`
for user data
- `$XDG_CACHE_HOME/mirage` if that variable is set, else `~/.cache/mirage`
for cache data
For Flatpak installations:
- `~/.var/app/io.github.mirukana.mirage/config/mirage` for config files
- `~/.var/app/io.github.mirukana.mirage/data/mirage` for user data
- `~/.var/app/io.github.mirukana.mirage/cache/mirage` for cache data
These locations can be overriden with environment variables, see
`mirage --help`.
The user data folder contains saved encryption data, interface states and
[themes](THEMING.md), while the cache contains downloaded files and thumbnails.
## settings.py
A file written in the [PCN format](PCN.md), located in the
[config folder](#folders), which is manually created by the user to configure
the application's behavior.
The default `settings.py`, used when no user-written file exists, documents all
the possible options and can be found at:
- [`src/config/settings.py`][1] in this repository
- `/usr/local/share/examples/mirage/settings.py` or
`/usr/share/examples/mirage/settings.py` on Linux installations
- `~/.local/share/flatpak/app/io.github.mirukana.mirage/current/active/files/share/examples/mirage/settings.py` for per-user Flatpak installations
- `/var/lib/flatpak/app/io.github.mirukana.mirage/current/active/files/share/examples/mirage/settings.py` for system-wide Flatpak installations
Rather than copying the entire default file, it is recommended to
[`include`](PCN.md#including-built-in-files) it and only add the settings
you want to override.
For example, a user settings file that disables kinetic scrolling,
sets a different theme, and changes some keybinds could look like this:
```python3
self.include_builtin("config/settings.py")
class General:
theme: str = "Glass.qpl"
class Scrolling:
kinetic: bool = False # Has issues on trackpad
class Keys:
# The default ctrl+= doesn't work on some keyboard layouts
reset_zoom = ["Ctrl+Backspace", "Ctrl+="]
class Messages:
open_links_files = ["Ctrl+Shift+O"]
open_links_files_externally = ["Ctrl+O"]
```
When this file is saved while the application is running, the settings will
automatically be reloaded, except for some options which require a restart.
The default `settings.py` indicates which options require a restart.
You can also manually trigger a reload by updating the file's last change
timestamp, e.g. with the `touch` command:
```sh
touch ~/.config/mirage/settings.py
```
[1]: https://github.com/mirukana/mirage/tree/master/src/config/settings.py
## accounts.json
This JSON file, located in the [config folder](#folders), is managed by the
interface and doesn't need to be manually edited, except for changing account
positions via their `order` key.
The `order` key can be any number. If multiple accounts have the same `order`,
they are sorted lexically by user ID.
This file should never be shared, as anyone obtaining your access tokens will
be able to use your accounts.
Within the application, from the Sessions tab of your account's settings,
access tokens can be revoked by signing out sessions,
provided you have the account's password.
Example file:
```json
{
"@user_id:example.org": {
"device_id": "ABCDEFGHIJ",
"enabled": true,
"homeserver": "https://example.org",
"order": 0,
"presence": "online",
"status_msg": "",
"token": ""
},
"@account_2:example.org": {
"device_id": "KLMNOPQRST",
"enabled": true,
"homeserver": "https://example.org",
"order": 1,
"presence": "invisible",
"status_msg": "",
"token": ""
}
}
```
mirage-0.7.2/docs/CONTRIBUTING.md 0000664 0000000 0000000 00000021650 14077472336 0016166 0 ustar 00root root 0000000 0000000 # Contributing
- [Issues](#issues)
- [Pull Requests](#pull-requests)
- [Procedure](#procedure)
- [Commit Guidelines](#commit-guidelines)
- [Coding Conventions](#coding-conventions)
- [General](#general)
- [Python](#python)
- [QML](#qml)
- [C++](#c)
- [Resources](#resources)
- [Packaging](#packaging)
## Issues
[Issues](https://github.com/mirukana/mirage/issues) on GitHub should be used to
ask questions, report problems, request new features,
or discuss potential changes before creating pull requests.
Before opening new issues, please search for any already open or closed
issue related to your problem, in order to prevent duplicates.
You can also join us on the
[#mirage-client:matrix.org](https://matrix.to/#/%23mirage-client:matrix.org)
room for questions and discussions.
## Pull Requests
For changes outside of simple bug/typo/formatting fixes, it is strongly
recommended to first discuss your ideas in a related issue or in
[#mirage-client:matrix.org](https://matrix.to/#/%23mirage-client:matrix.org).
New changes are merged to the
[`dev` branch](https://github.com/mirukana/mirage/tree/dev) first.
Once a new version of the application is released,
the current `dev` is merged into the main `master` branch.
By sending your changes, you agree to license them under the LGPL 3.0 or later.
### Procedure
Start by forking the main repository from GitHub, then
clone your fork and switch to a new branch based on `dev`, in which
you will make your changes:
```sh
git clone --recursive https://github.com/yourUsername/mirage
cd mirage
git remote add upstream https://github.com/mirukana/mirage
git fetch upstream
git checkout upstream/dev
git branch example-branch-name
git checkout example-branch-name
```
Test and commit your changes according to the
[commit guidelines](#commit-guidelines), and `git push` to your fork's repo.
You will then be able to make a pull request by going
to the [main repo](https://github.com/mirukana/mirage).
Once your pull request is merged, you can update `dev`, and delete your
GitHub and local branch:
```sh
git fetch upstream
git checkout upstream/dev
git push -d origin example-branch-name
git branch -d example-branch-name
```
Make sure `dev` is up-to-date before creating new branches based on it.
## Commit Guidelines
Commit messages should be made in this form:
```
Title, a short summary of the changes
The body, a more detailed summary needed depending on the changes.
Explain the goal of the code, how to reproduce the bug it solves
(if this is a bug fix), any special reasoning behind the
implementation or side-effects.
```
- Write informative titles, e.g.
`TextField: fix copying selected text by Ctrl+C` instead of
`fix field bug`
(assuming `TextField` was the name of the component affected by the bug)
- Write the title in imperative form and without a period at the end,
e.g. `Fix thing` instead of `Fixed thing` or `Fixes thing.`
- The title must not exceed 50 characters
- A blank line is required between the first line summary and detailed
body, if there is one
- Lines of the body must not exceed 72 characters
- Split independent changes into separate commits,
don't combine fixes for different problems or add multiple systems forming a
complex feature all at once
- Every commit should be able to build and run the application without
obvious crashes or tracebacks
- Check for linter errors before committing by running `make test` in the
repository's root. The test tools can be installed with
`pip3 install --user -Ur requirements-dev.txt`.
- For changes that aren't yet merged in a branch of the main repo,
prefer amending or editing previous commits via git interactive rebase,
rather than adding new "fix this" commits.
This helps keeping the history clean.
## Coding Conventions
### General
- Use four space indentations, no tabs
- Use double quotes for strings, unless single quotes would avoid having to
escape double quotes in the text
- Keep lines under 80 columns, the only exception for this is long URL links
that can't be broken in multiple parts
- Keep lines free from any trailing whitespace
- Function definitions, calls, list/dict/etc not fitting in
one line follow this format (notice the trailing comma on the last element):
```python3
long_function_call(
long_argument_1, long_argument_1, long_argument_3, long_argument_4,
)
very_long_list_def = [
"Lorem ipsum dolor sit amet, consectetuer adipiscing elit",
"Aenean massa. Cum sociis natoque penatibus",
"Mus donec quam felis, ultricies nec, pellentesque",
]
```
- When creating new files, don't forget the copyright and license
header you see in other files of the same language.
### Python
- All functions, class attributes or top-level variables should have type hints
- Separate all top-level classes and functions by two blank lines.
For classes with many long methods, separate those methodes by two blank
lines too.
- Readability is important. Vertically-align consecutive lines of assignments,
function definition arguments, dictionaries and inline comments:
```python3
# Bad:
num: int = 1 # A comment
args: List[str] = ["a", "b"] # Another comment
def func(
self,
example_argument: int = 300, # Comment
other: str = "Sample text", # Other comment
some_floats: Tuple[float, float, float] = (4.2, 1.1, 9.8),
) -> None:
pass
# Good:
num: int = 1 # A comment
args: List[str] = ["a", "b"] # Another comment
def func(
self,
example_arg: int = 300, # Comment
other: str = "Sample text", # Other comment
some_floats: Tuple[float, float] = (4.2, 9.8),
) -> None:
pass
```
If this is annoying, consider getting a plugin for your editor to automate it
(e.g. [EasyAlign](https://github.com/junegunn/vim-easy-align) for vim).
- Use f-strings as long as the readability isn't impacted.
For more complex string formatting, use the shorter `%` syntax when features
special to `str.format()` aren't needed.
- Otherwise, follow the
[PEP-8 standard](https://www.python.org/dev/peps/pep-0008/)
### QML
- Don't add trailing semicolons to lines
- If an object has more than one property, always keep each property on their
own line:
```qml
Rectangle { x: 10; width: 100; height: width; color: "black" } // Bad!
Rectangle { // Good
x: 10
width: 100
height: width
color: "black"
}
```
- When creating new files, the `id` for the root component should always
be `root`
- When writing new code, refer to parent object properties explicitely, e.g.
`parent.prop_name` or `someId.prop_name` instead of just ``
- Don't use [States](https://doc.qt.io/qt-5/qml-qtquick-state.html),
the Rectangle in the description's example could simply be written like this:
```qml
Rectangle {
width: 100
height: 100
color: mouseArea.containsPress ? "red" : "black"
MouseArea {
id: mouseArea
anchors.fill: parent
}
}
```
- Otherwise, follow the
[QML Coding Conventions](https://doc.qt.io/qt-5/qml-codingconventions.html)
### C++
- Add C++ only if it can't easily be done in QML or Python;
or if doing it in Python requires adding a dependency while a
similar feature is already provided by Qt, feature that just needs to be
exposed with some wrapper code
([example](https://github.com/mirukana/mirage/blob/v0.6.4/src/utils.h#L31)).
- Be explicit, always use `this->` to refer to methods and class attributes
- Don't split modules between `.h` and `.cpp` files, this creates unnecessary
code repetition and has no benefits when most methods will
contain very few lines and the module is only included once before
starting the GUI.
## Resources
Resources include background images, icons or sounds.
New resources must have a permissive license that does not require attribution.
Built-in icons must be in the SVG format. The majority of icons used in the
application come from [iconmonstr](https://iconmonstr.com).
When possible without any noticable quality loss, reduce the size of
resources and strip any metadata by using tools such as:
- `svgcleaner --allow-bigger-file --indent 4