Dynamically toggle visibility of WPF grid column from C# code

<ColumnDefinition> <ColumnDefinition.Style> <Style TargetType=”ColumnDefinition”> <Setter Property=”Width” Value=”*” /> <Style.Triggers> <DataTrigger Binding=”{Binding IsColumnVisible}” Value=”False”> <Setter Property=”Width” Value=”0″ /> </DataTrigger> </Style.Triggers> </Style> </ColumnDefinition.Style> </ColumnDefinition> Please do implement INotifyPropertyChanged in your ViewModel

Is there a downside to using -Bsymbolic-functions?

Answering my own question because I just earned a Tumbleweed badge for it… and I found out subsequently But I was wondering whether there is perhaps a finer-grained control over this, like overwriting -Bsymbolic for individual function definitions of a library. Yes, there is the option –dynamic-list which does exactly that Should I be aware … Read more

Accessing a Private Constructor from Outside the Class in C#

New answer (nine years later) There is now several overloads for Activator.CreateInstance that allow you to use non public constructors: Activator.CreateInstance(typeof(YourClass), true); true = use non public constructors. . Old answer Default constructors are private for a reason. The developer doesn’t make it private for fun. But if you still want to use the default … Read more

Why there are only 75 visible characters in Intellij Idea’s embedded terminal?

Notice: since IDEA 2016.3.2 this breaks the terminal and is not required anymore. So just delete it when you update to a version it cannot create the Terminal. For windows change the terminal shell path (File->Settings->Tools->Terminal) from cmd.exe to: cmd.exe “/K mode con:cols=500 lines=9999&cmd.exe” or if using the bash for windows subsystem: cmd.exe “/K set … Read more

How to demonstrate java multithreading visibility problems?

By modifying the example here by removing operations I have come up with an example that consistently fails in my environment (the thread never stops running). // Java environment: // java version “1.6.0_0” // OpenJDK Runtime Environment (IcedTea6 1.6.1) (6b16-1.6.1-3ubuntu3) // OpenJDK 64-Bit Server VM (build 14.0-b16, mixed mode) public class Test2 extends Thread { … Read more