Commit Graph

29 Commits

Author SHA1 Message Date
Florian Bruhin 0718b25796 reuse: Initial copyright text update for myself
git ls-files | \
    xargs sed -Ei 's/Copyright [0-9]{4}(-[0-9]{4}) Florian Bruhin \(The Compiler\) <mail@qutebrowser\.org>/SPDX-FileCopyrightText: Florian Bruhin (The Compiler) <mail@qutebrowser.org>/'
2023-07-23 12:49:05 +02:00
Florian Bruhin b2aaba6043 reuse: Adjust most license headers
git ls-files | xargs grep -l "is free software"  | xargs reuse annotate --license="GPL-3.0-or-later" --skip-unrecognised
2023-07-23 12:11:07 +02:00
Philipp Albrecht d9e8b638bf Remove vim modelines
We're deprecating vim modelines in favor of `.editorconfig`.

Removing vim modelines could be done using two one-liners. Most of the vim modelines
were followed by an empty line, so this one-liner took care of these ones:

```sh
rg '^# vim: .+\n\n' -l | xargs sed -i '/^# vim: /,+1d'
```

Then some of the vim modelines were followed by a pylint configuration line, so running
this one-liner afterwards took care of that:

```sh
rg '^# vim:' -l | xargs sed -i '/^# vim: /d'
```
2023-06-30 11:03:06 +02:00
Lembrun e8b05af233 Qtbot methods changed to snake case,snake case check added 2021-02-26 22:07:08 +01:00
Florian Bruhin 1a4fff1a42 doc: Switch URLs to https 2021-01-26 15:19:01 +01:00
Florian Bruhin 222f1f19a1 Bump copyright years
Closes #6015
2021-01-20 20:06:19 +01:00
Florian Bruhin 14373db9c7 dataclasses: Adjust import order
See #6023
2021-01-13 20:26:57 +01:00
Florian Bruhin c970c63355 dataclasses: Initial switch
See #6023
2021-01-13 20:26:41 +01:00
Florian Bruhin e652dcce29 Make javascript.string_escape tests run with QtWebEngine
Reveals some issues, see #5666
2020-08-11 20:23:08 +02:00
Florian Bruhin 9e4276db9b Adjust copyrights for 2020 2020-01-04 18:21:17 +01:00
Jay Kamat 3e816f5f8b
Update copyright for 2019 2019-02-22 21:45:08 -08:00
Florian Bruhin 718376f154 Refactor JS escaping
This renames javascript.convert_js_arg() to javascript.to_js() and uses that
instead of string_escape() where possible.
2018-09-27 16:36:28 +02:00
Florian Bruhin 38a4734b9a Merge remote-tracking branch 'origin/pr/4204' 2018-09-27 16:28:30 +02:00
Jay Kamat f0568ece57
Make convert_js_arg public and use it for dispatch_element in webkit 2018-09-21 18:08:04 -07:00
Florian Bruhin 1647c28632 Allow lists for javascript.convert_js_arg 2018-09-08 16:20:38 +02:00
Florian Bruhin 1b84bbd61d Refactor initialization of internal JavaScript
- Initialize JavaScript in webenginesettings.py instead of webenginetab.py
- Move JavaScript snippet into a .js file
- Make sure scripts can be re-run and do nothing if already run.
- Run scripts on DocumentCreation *and* DocumentReady. Closes #3717.
- Give each script an unique name for debugging.
- Also make custom stylesheets work on chrome:// pages
2018-03-19 09:14:55 +01:00
Florian Bruhin 6f028e9ad0 Update copyright years 2018-02-05 12:19:50 +01:00
Florian Bruhin 852baaa8c3 Drop support for Qt < 5.7.1
See #2742
2017-09-18 23:01:17 +02:00
Florian Bruhin 822623f2ed Finally update copyrights... 2017-05-09 21:37:03 +02:00
Florian Bruhin 4345d60ff1 Revert "javascript.assemble: Support document module"
This reverts commit afc7faabda.

This isn't actually needed as we can't use document.getElementById()
directly without serializing anyways.
2016-08-18 15:58:46 +02:00
Florian Bruhin afc7faabda javascript.assemble: Support document module 2016-08-18 14:07:21 +02:00
Florian Bruhin 30029a8259 utils.javascript: Handle bools in _convert_js_arg 2016-08-18 12:40:21 +02:00
Florian Bruhin 29b778b6d6 Use javascript.assemble for all functions 2016-08-10 17:27:34 +02:00
Florian Bruhin c8a92a0851 Fix test_assemble 2016-08-09 13:23:46 +02:00
Florian Bruhin 627f743c26 Handle float in _convert_js_arg
This fixes 'gg' with QtWebEngine.
2016-08-08 08:04:55 +02:00
Florian Bruhin 0169f3a24f Add _qutebrowser_ prefix for custom JS functions
With QtWebKit or QtWebEngine with Qt < 5.7, the functions end up in the
page's namespace. We can't easily avoid this, but at least we can name
them in a way which reduces conflicts.
2016-08-05 10:31:07 +02:00
Florian Bruhin 74b9b0ba90 Remove unneeded lambda 2016-08-04 18:15:29 +02:00
Florian Bruhin a8ef956726 Add quotes for strings in javascript.assemble 2016-08-04 17:58:40 +02:00
Florian Bruhin 08b70f0f4c Add qutebrowser.utils.javascript
webelem.javascript_escape got renamed to javascript.string_escape, and a
new javascript.assemble got added to make it easier to call a function
inside a .js file.
2016-08-04 17:53:13 +02:00