UE4 - Removing Text When Exiting TriggerBox - text

Having some trouble getting text to disappear when I exit the trigger box from reading the note. I can easily display the text I want but I am unsure how I can make it disappear when I leave the triggerbox. Blueprint included, any help is appreciated.

Connect GetPlayerController to Create Widget?
Also store the created widget as a variable. It's likely that the widget reference is being lost once the E input event is finished, so the RemoveFromParent node doesn't know what to remove.
For widgets that you're going to use all the time, pre-create them and store them as variables. Much easier to maintain in the long run.

Related

How to show long ListItem in Rust TUI List

I am working on a Terminal User Interface where one of the widgets is a List where I show some logs. Right now, I have two functions: listener(log_list) and printer(log_list). In listener I receive the logs and store them in log_list, which is a Arc<Mutex<VecDeque<ListItem<'_>>>>, and then I print that VecDeque in a List in printer function.
The problem is when a line of this log is longer than terminal width, because it just cuts it, missing part of the information when printing. So which would it be the best way to solve this? I mean, I could create a shared value with the terminal width that I get in printer, and share it to listener, so that I cut each log longer than the width and create 2 ListItems, but I find this very messy. Is there any elegant way of doing this?
Thanks

Reprint a table in js terminal without a waterfall print or clearing console

JS has this great feature called console.table. It allows a list of objects to be displayed as a table.
Now I could like to create a simple little program that continously displays the same table just with updated values (individual values change very fast, so a re render only on change isn't an option)
So far I got the best results simply rendering one table after the other, which leaves the most recent table always at the bottom. The problem with this is that it fills the entire terminal extremely fast and as such makes scrolling back up difficult.
Another option would be to clear the terminal and the print the table again. But this leads to excessive "blinking" which makes the table unreadable.
So basically I would need a way to print the console.table, somehow get the terminal cursor back to the start of a table and the overwrite it, similar to how it works in a lot of terminal programms like htop. Is there a way to do this in node js?

sublime text 3 file tabs changed with update (too wide/too smart?)

A new update to sublime text 3 seems to have changed the way the file tabs work. I'm not even sure what is the proper element for this name but something happened with this:
Before this most recent update, i think the tabs would just shrink as the number increased, and not being able to read the name was a signal that i need to close stuff. Now it feels a lot smarter, it makes sure that i can read the entire name, but then a whole bunch of them can be hidden and stacked at the very beginning or end. I dont like this, how can i change it back?
You can set "enable_tab_scrolling": false, in your user preferences to get the old ST2 behavior back.

Is it possible to keep a variable active with Revit Python Shell, using canned commands?

I'm currently using Revit Python Shell 2017 and I'd like let's say to make "communicate" different canned commands.
For instance, let's say I load a house model, and I create some additional walls on it, via a canned command that I would have previously created. While creating these walls, I could store all these new walls IDs in a variable, as a list.
Now, if I want to delete exactly these walls afterwards, I'd like to identify them using their IDs that I stored in the list, then delete them.
If I was in an interactive Python Shell session, well the "IDs list" variable would still be accessible (as long as I don't close the shell), and I could just retrieve the IDs from it, then delete the walls.
But what if I'm using canned commands? The first command would be "create the walls", and the 2nd would be "erase these walls". But that "IDs list" variable doesn't exists in the second canned command environment, so that I can't use it to erase the walls.
So, what would be the approach? Of course in this example I could identify the walls in the second command using a different methodology, such as asking the user to select them etc etc.. But the idea I'm going for would be the store that list from the first command "somewhere in Revit", and retrieve it when calling the second command.
I could write the list to an external text file, and read the file in the second command... but is there a cleaner way?
I'm sorry for the beginner's language used here, and hope that my question is clear enough! And that somebody can help ;)
Best,
Arnaud.
This is a great question Arnaud, in the past Ive done the following:
Create a text project parameter, and populate it with XML (yes you can have line breaks in a text parameter). This is similar to what Ideate BIM Link does (check the project parameters of any project that has used BIM Link). This is a long-winded method for keeping data persistent between commands.
The second part (saving a walls IDs) is more difficult I think, as I understand it every time you open a project the IDs are reassigned. You could test this to see if its the case?
Another method could involve using an External command that lingers after you have finished selecting walls. Could you go into a little more info about what youre wanting to achieve?
So,
Just for leaving a trace, I solved this using pyRevit and its ability to store data in temporary files (here, look for "Using Temporary Files").

dialog/whiptail radiolist consistence

So basically I am trying to rewrite a bash script which uses dialog --radiolist for choosing locale,keyboard,time. At the moment the tag is a number that corresponds to a local (I created a hashtable for it). But because I have, and want to keep it that way for now, around 100 locales it gets messy at the end.
What I wanna achieve is to make it more compact without having to add or add an artificial, non visible item that might easily translate to its tag. (as a tag I would put the locale name)
What I have tried:
1. Noobish thing but I though that there might be some way to include empty like NULL in ASCII or 0, blank space etc, but dialog would always make it visible.
2. Exclude the item at all and finish on on/off but instead on/off takes place of item (not surprisingly if options are as follow --radiolist text height width list-height [ tag item status ])
3. Instead of letting the dialog on exit write to the output the name of the chosen locale I created an output statement myself.
I had red a lot about dialog and whiptail(http://linux.die.net/man/1/dialog, http://linuxcommand.org/lc3_adv_dialog.php) but always end up with having to add tag and an item. Would appreciate any suggestions and maybe some info if there is easily plug-gable dialog/whiptail compatible libs.
Thank You in advance
Perhaps you overlooked the --no-tags option (see manpage):
--no-tags
Some widgets (checklist, inputmenu, radiolist, menu) display a
list with two columns (a "tag" and "description"). The tag is
useful for scripting, but may not help the user. The --no-tags
option (from Xdialog) may be used to suppress the column of tags
from the display. Unlike the --no-items option, this does not
affect the data which is read from the script.
The question mentions whiptail and consistency, which could refer to consistency across dialog and whiptail. There is none, since
whiptail provides fewer options than dialog (inevitably, there will be differences, since there is no one-one mapping possible)
consistency as such between the two is done in dialog occasionally to help with compatibility (the reverse is not true).

Resources