private void CopyHex(object sender, RoutedEventArgs e) { MenuItem item = e.OriginalSource as MenuItem; if (item != null && item.DataContext != null) { FontSymbol dat = item.DataContext as FontSymbol; putclipboard(dat.XamlMarkup); } }
private void CopyStaticRessource(object sender, RoutedEventArgs e) { MenuItem item = e.OriginalSource as MenuItem; if (item != null && item.DataContext != null) { FontSymbol dat = item.DataContext as FontSymbol; putclipboard("{StaticResource " + fontInfos.CurrentFontInfo.ResourcePrefix + dat.Name + "}"); } }