Questions tagged [texttrimming]

78 questions
1
vote
0 answers

Text drawn with GDI+ Graphics.DrawString jumps 1 pixel up when using StringTrimming.EllipsisCharacter

I'm using the classic DrawString method to output text in a WinForms app. A typical call look like this: g.DrawString(text, font, brush, new Rectangle(x, y, width, height), stringFormat); If stringFormat.Trimming equals…
TecMan
  • 2,743
  • 2
  • 30
  • 64
1
vote
1 answer

WPF MultiLine TextTrimming

We have a case where we need to display Character Ellipsis(i.e. show text as trimmed) when we have multiline text. The textblock shows trailing ellipsis when the content is anyway bigger than the width of the multiline TextBlock (i.e. TextWrapping…
Harsha
  • 103
  • 1
  • 2
  • 13
1
vote
4 answers

CharacterEllipsis doesn't work inside ItemsControl WPF

I'm trying to set CharacterEllipsis on text inside a DataTemplate of an ItemsControl.
Omri Btian
  • 6,499
  • 4
  • 39
  • 65
1
vote
1 answer

String Manupulation in VBA

I have single column that needs to be split to multiple, like Text-to-columns in excel. However there is a small challenge. Conventional delimiter will not work. Consider the string below Original: Domain\Domain Admins Domain2\User Group…
Arvinder
  • 7
  • 2
1
vote
1 answer

Windows Phone App - How to make text wrapping depending on device width

In my app I have a list box that contains a stack panel with text block items. The text block items have a text wrapping or text trimming property to avoid that the text block items slide outside the visible range. As far as I know the text…
Benny Code
  • 51,456
  • 28
  • 233
  • 198
1
vote
5 answers

How to remove starting 0's in uitextfield text in iphone sdk

Code Snippet: NSString *tempStr = self.consumerNumber.text; if ([tempStr hasPrefix:@"0"] && [tempStr length] > 1) { tempStr = [tempStr substringFromIndex:1]; [self.consumerNumbers addObject:tempStr];> …
Nothing
  • 27
  • 1
  • 4
1
vote
1 answer

Xcode how trim a string with special character $

I've a string with this kind of value /finocchi$FINOCCHamelo Now I need a new string with only this part of the word FINOCCHamelo I've try this: NSString * newString = [item.label stringByReplacingOccurrencesOfString:@"$" withString:@""]; But it's…
0
votes
1 answer

TextTrimming property of a textblock not working

I can find a property called TextTrimming for TextBlock, but I can't get it working. I have a text block in the MainPage, which is intended to give a preview.. When i click a button if there is any notes saved in it, I need to display few…
alfah
  • 2,077
  • 1
  • 31
  • 55
0
votes
1 answer

WPF How to get hidden text range of trimmed text (with TextTrimming enabled)

How to get the trimmed text of the TextBlock when TextTrimming is set to "WordEllipsis" or "CharacterEllipsis" ? For example, this code:
ErinQvnm
  • 117
  • 1
  • 9
0
votes
1 answer

Elastic WrapPanel and TextTrimming

I am attempting to create an Elastic WrapPanel. Which means that each columns stretch itself to fit the panel's width until a new column fits inside the panel. The columns width is based on a ItemMinWidth. I was able to create the panel, but my…
SiriusNik
  • 561
  • 2
  • 7
  • 19
0
votes
1 answer

How do I remove the first two characters from all cells in a selection using VBA?

In order to make my macro work, I've added a double # onto the start of each cell using VBA -> ##string However, I now need to remove the double hashtag for all cells in the selection, I'm using the below code to target all cells in my…
Harry C
  • 3
  • 3
0
votes
1 answer

Delete all text file content except one string chosen with C#

I have this txt file: ********** Welcome to file*********************This test file.It can gives value.It returns if the validation is successful or shows errors where the XML validation fails.It checks for syntax and content as…
MK Said
  • 165
  • 8
0
votes
1 answer

WPF ComboBox text trimming

I want to show "..." at the end of the ComboBox content when its text is to large. I tried this but it doesn't work: