Bash auto_completion with Xubuntu and xrdp from windows
You may find that this is a more general issue with interception of the Tab key under remote XFCE4 sessions, rather than a problem with bash completion itself.
I had a similar issue running XFCE4 over VNC and the workaround for me was to edit the ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml
file to unset the following mapping
< <property name="<Super>Tab" type="string" value="switch_window_key"/>
---
> <property name="<Super>Tab" type="string" value="empty"/>
Note that there may be two entries, and the first already has the value "empty". If this is the case, edit the second entry.
I found this solution online somewhere and can't really take credit for it.
Related videos on Youtube
kemosabe
Updated on September 18, 2022Comments
-
kemosabe almost 2 years
I am working with translations in Laravel and I have several arrays with translation keys that map to their corresponding translation. I need to remove any translation that has a
--
and replace it with an empty string. I am already doing some other str-replacements in the same function so maybe I'm clobbering the function.Here is what the entire function looks like:
public function getWithContext($locale, $context) { $this->registerContext($context); $contextKey = "{$locale}.{$context}"; if ($this->has($contextKey)) return $this->get($contextKey); $out = []; $data = $this->get($locale); foreach ($data as $key => $value) { if (preg_match("/^({$context}\.)/", $key)) { $k = str_replace("{$context}.", "", $key); $out[$k] = ($value == "—-") ? "" : $value; } } if (!empty($out)) { $this->put($contextKey, new Collection($out)); } return $out; }
I'm trying to get the line
$out[$k] = ($value == "--") ? "" : $value;
to work specifically.-
Gwendal over 8 yearsWhat's not working ? Do you have an error, or is assignment not working ? What's in you
$out
var ? -
kemosabe over 8 yearsI wasn't getting an error, it just wasn't changing the dashes to an empty string as I expected it to. I posted what happened in an answer below. Thanks for asking and trying to help.
-
-
nik the lion almost 11 yearsGood shot, but i found this issue also with google. This property has already this value at my xfce4-keyboard-shortcuts.xml by default. The link: codebangers.com/?p=134
-
nik the lion almost 11 yearsDamn. I wounder why this value is by default "empty". Checked this with less and find a second entry. But this time with the value "switch_window_key". Changed > restart > works!!!! Thank you :)
-
Sohaib almost 10 years@steeldriver I couldnt quite understand the change to be employed can I have a little more explanation?
-
Cameron Taggart over 8 yearsEdit that file and replace
switch_window_key
withempty
on that line. I used nano to edit the file. I then restarted VNC withsudo service vncserver restart
. It just worked for me. -
kemosabe over 8 yearsThat's exactly the problem!
-
Jon Carter almost 7 yearsI was sure this was an RDP issue. I was wrong. Thanks for this.
-
fIwJlxSzApHEZIl about 6 yearsthis did not fix the issue for me when using XRDP and XFCE4. I had one entry up top set to
switch_window_key
and another down below set toempty
. I set the first entry forSuper>Tab
toempty
and didsudo xrdp restart
and re-logged in to no change.