Preserving whitespace in Run element

When formatting a paragraph as so -
<RichTextBlock><Paragraph xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation'>
<Run></Run>
<InlineUIContainer><TextBlock >Words here</TextBlock></InlineUIContainer>
<Run xml:space="preserve"> </Run>
<InlineUIContainer><TextBlock>More words here</TextBlock></InlineUIContainer>
<Run xml:space="preserve"> Lastly some words here</Run>
</Paragraph>
</RichTextBlock>
The <Run> element containing a single space is never displayed and ignore the space=preserve property. However the last run with a leading space is displayed correctly.
How can I get a run containing a single space to display ?

Hi BradStevenson,
You can see the whitespace working principle in XAML from
http://msdn.microsoft.com/en-us/library/windows/apps/xaml/hh758290.aspx.
As we can see, “A space immediately following the start tag is deleted.”
it should be removed by the system. But when we add whitespace before other characters, I think it is used as a string, because “If the type of the property is Object, then the inner text is parsed as a single String. If there are intervening element
tags, this results in a XAML parser error, because the Object type implies a single object (String or otherwise).” When whitespace in inner text. You can find these explanation from the above link.
So if you want to preserve the whitespace, use whitespace in string and make the system considering it as inner text.
Feel free to let me know if you have any concerns.
Regards,
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place. Click HERE to participate
the survey.

Similar Messages

  • Jdeveloper 10.1.3: JAXB - how to preserve whitespace in text element??

    Dear all,
    i am trying to use jaxb to do the xml <> java object conversion.
    i meet a problem that the jaxb seems don't preserve the white space when xml to
    java conversion (but java to xml is ok, the whitespace is preserved.)
    for example:
    an element with string type: <Address> with leading and trailing spaces </Address>,
    in java code, obj.getAddress() return "with leading and trailing spaces", the spaces
    are trimmed..
    is there any configuration to make?
    how can i preserve the whitespaces?
    thank you
    ping

    Hi, Branislav,
    That's great! It works!
    I choose to use the first method. I have two project modules, both use the same data model. I opened the data model project's properties editor, highlighted the business components node, and the the Connection dropdown list is right there.
    Thank you very much! You are always very helpful!
    Newman

  • Preserve whitespace in XML element value

    I am trying to add XML element with value prefix with white space:
      ex_doc->create_simple_element(
          name = 'VALUEPART1'
          value = '          BQ/XWKB-99-5-9999-2'
          parent = lo_ele_e1bpparex_bape_vbak ).
    But when the XML is create, the white space is removed! How can I preserve the white space???
    <VALUEPART1>BQ/XWKB-99-5-9999-2</VALUEPART1>
    What i want is:
    <VALUEPART1>          BQ/XWKB-99-5-9999-2</VALUEPART1>
    Appreciate for any help

    Hi,
    if you had been using XSLT instead, I would have said 'remove the strip-space element or alter it according to your needs'...
    Please provide what class you are using, else it's too generic..
    regards, Lukas

  • Is there any way to force Sun C++ Preprocessor preserve whitespace?

    Hello!
    I'm preprocessing simple source file:
    void test()
        int i;
    }with command: CC -E test.cpp
    and CC preprocessor eats all whitespace at the beginning of each line, like this:
    void test()
    int i;
    }Is there any way to force CC preprocessor preserve whitespace?

    You cannot use the C preprocessor on C++ code, for at least two major reasons.
    1. The default -I options in CC are not the same as for cc. Try adding
    #include <iostream>
    #include <cstdlib>
    to your example.
    Even if you add the missing -I options, the conventions for finding the C++ standard headers are not known to the C preprocessor.
    Example:
    % cc -P -I/opt/SUNWspro/prod/include/CC/Cstd -I/opt/SUNWspro/prod/include/CC -I/opt/SUNWspro/prod/include/cc z.c
    "z.c", line 2: cannot find include file: <cstdlib>
    cc: acomp failed for z.c2. The predefined macros (-D options and predefined macros built into the compilers) are different for cc and CC.
    In particular, the C compiler predefines macros saying it is a C compiler. The C++ compiler predefines macros saying it is a C++ compiler. Code that is conditionalized on whether it is compiled by the C or C++ compiler will give different results. If you add -D options for C++ macros, the results will depend on the way the tests are coded. That is, testing for a C compiler or a C++ compiler will not give mutually exclusive answers, as they would if you use the correct compiler. The Solaris headers have conditional code for C and C++.

  • I am running Elements 10 on Yosemite 10.0.1 and it crashes in the middle of every project. Is there a work around?

    I am running Elements 10 on Yosemite 10.0.1 and it crashes in the middle of every project. Is there a work around?

    Did you delete the preferences on upgrading to 10.10? If not:
    A Reminder for Mac Folks upgrading to Yosemite | Barbara's Sort-of-Tech Blog

  • I have been running elements 12 for a few months now....today when I tried to open the editor I get " Visual C  C  runtime error. I can open the organizer but not the editor

    I have been running elements 12 for a few months now....today when I tried to open the editor I get " Visual C  C  runtime error. I can open the organizer but not the editor

    I'm keen to know if you get a response to this.  I've been running Elements 12 for a year now, and suddenly my Editor is not working.  I'm running Windows 8.1 and just get a message that says "The Editor is not working".    Not very helpful.

  • How can I move my photos from Photoshop Elements 8 to a new computer also running Elements 8?

    How can I move my photos from Photoshop Elements 8 to a new computer also running Elements 8?

    I am not sure this is going to work. For one thing, the preferences file is in a different place in Mountain Lion. It is at: ~/Library/Containers/com.apple.mail/Data/Library/Preferences/com.apple.mail.pli st. I wouldn't try to move the .plist file, I'd be very surprised if it would work.
    I would do a different approach and start with just recreating the mail account(s) you have on the new machine from scratch and let them download your mail from the server. Then if there were e-mails not on the server any more, but stored in the black macbook, I'd copy them from the mailboxes folder, from the old machine to the new. I'm not sure where they are in 10.5.8, but in ML they are at ~/Library/Mail/V2/Mailboxes.
    At each stage along the way I'd do a backup, so in case it screws things up, you can revert to a functional Mail.app.

  • Install complete - how to run elements on my mac

    install complete - how to run elements on my mac?

    If Installation has been completed, then you can go to the Applications menu on your MAC and you find Photoshop elements listed out there.
    For understanding PSE, you can check this : http://helpx.adobe.com/photoshop-elements.html

  • I am running Elements 11 on Windows 8.  When I use the healing tool, the entire image moves with the cursor.  How do I fix???  Thanks!

    I am running Elements 11 on Windows 8.  When I use the healing tool, the entire image moves with the cursor.  How do I fix???  Thanks!

    With the Healing Brush Tool selected, in the Tool Options, click on Clone Overlay and check Clipped.

  • Can i run elements 13 with windows vista

    is anyone running elements 13 with windows vista?

    Adobe Photoshop Elements 13 for Mac, Windows - System requirements
    Only Windows 7 or Windows 8.

  • Having trouble running Elements 6 w/ Ltrm 4.4 upgrade

    Running Elements on a Mac with Lion 10.7.5 without difficulty. Downloaded Lightroom upgrade 4.4. Since then when editing in Elements 6, I can't use the following (grayed out in pull-down menu): auto smart Fix, Image/transform, many of the layer and filter functions. Any suggestions for fixing or uninstalling the upgrade?

    It sounds like you have your bit depth of the file you are sending to Elements as 16 bit instead of 8.  Elements only lets you use a subset of the edits when using 16 bit.  It can be changed when you use Edit In or exporting the file.  The following is the Edit In dialog box which you are probably using.

  • Attempting to run Elements for the first time and the Adobe Application Manager was stopped.  What to try next?

    What to try if attempt to run Elements for first time and Adobe App Manager was stopped?

    has the program you want to run been successfully installed?
    if not, install it.
    if yes, restart your computer and run the program.

  • Oracle XSLT Transformation not preserving space in text element

    If we have a BPEL process which is calling a XSLT transformation contains the code similar as below:
    for Populating an element with white space only
    <tns:TargetField>
    <xsl:text disable-output-escaping="yes"> </xsl:text> <!--Note the whitespace , also tried with disable-output-escaping =”no” -->
    </tns: TargetField>
    Our expected result / output would be:
    <tns:TargetField> </tns: TargetField> <!--Note the whitespace -->
    But, we get:
    <tns:TargetField/>
    Oracle XSLT is ignoring the white space even if we try with preserve space in XSD, or in XSLT this is not producing the expected output.
    This looks a BUG with Oracle XSLT Transformation .
    For a workaround solution we can use below XSLT snippet:
    *<tns:TargetField>*
    *<xsl:value-of select="string(' ')"/> <!--Note the whitespace -->*
    *</tns:TargetField>*
    This is returning Output:
    *<tns:TargetField> </tns:TargetField> <!--Note the whitespace -->*
    Any other work around do you find?
    Edited by: panks on Jul 29, 2011 12:37 PM

    The workaround only works with one white space, if one put more white spaces, it do not work.
    <tns:TargetField>
    <xsl:value-of select="string(' ')"/> <!--Note the whitespaces -->
    </tns:TargetField>
    This is returning Output:
    <tns:TargetField> </tns:TargetField> <!--Note the only one whitespace -->
    Edited by: user10697506 on Aug 10, 2011 3:27 PM

  • Why is running Elements 8 slower on Windows 7 than XP?

    I am afraid this is query is a bit long, but I have tried to provide all the
    info I can ....
    THE PROBLEM
    My old PC died, so I bought a new PC to improve my video processing speed, and also move off Windows XP.
    - I installed the same copy of Adobe Premiere Elements 8 on both PCs.
    - I applied no updates (on either machine) as the original versions works fine (on XP - why fix something that isn't broken)
    - I changed the preferences to stop background rendering (due to data volumes -
    same on old PC).
    - I then copied the project file (.prel) from the old PC to the new.
    Having set up the new PC, I carried out a benchmark test in Premiere Elements 8.0 converting the same 4-hour long HD file from M2TS to MPG on both PCs.
    It was 4 times slower on the new PC !!!!
    I then tried out another video conversion program (to demux MPG files so that they can be edited in Premiere) and that was 30% faster on the new PC.
    In the Premier test the original file was on a 6GB/s 3TB disk drive with the output file on a 6GB/s 2TB drive (which also has the Windows system and Adobe cache files).
    -  Both processes ran identically without errors.  In fact the output files were almost identical (one was 12 685 358 KB, the other 12 658 402 KB). I ran MediaInfo on both output files and it summarised them as identical in terms of codecs, size, etc, etc.
    - On the old PC, CPU utilisation is usually around 90%, on the new one it is closer to 50%.
    - Disk and memory utilisation are not limiting factors.
    Can anyone help me finding out why the new PC is so much slower than the old?
    SPECIFICATIONS
    OLD PC
    ASUS P8Z68-V
    INTEL CORE I5 2500K 3.30GHZ
    2 x KINGSTON 4096MB DDR3
    NVIDIA GeForce GT 440 1GB
    1 x 2 TB disks with 4k sectors
    4 x 3 TB disks with 4k sectors (each with 2 partitions)
    Windows XP Pro SP3
    NEW PC
    ASUS P8H77V
    INTEL I7 3770 3.4GHZ
    2 x KINGSTON 4096MB DDR3
    NVIDIA GeForce GT 610 1GB
    1 x 2 TB disks with 4k sectors
    4 x 3 TB disks with 64k sectors
    Windows 7 Pro
    BACKGROUND
    I have a very specific use of Premiere (for research purposes):
    - I have 2 HD video Sony XDR160E camcorders monitoring bird nests 13 hours per day.
    - Each camera generates 160 GB data per day on its internal HD.
    - File sizes range from 20 GB (smallest) to 160 GB.
    - I download the files from the camera to disk using the cameras download facility.
    It is then that I use Premiere.
    - I open a project that has the exact specs of the camera's output.
    - I open the M2TS file in Premiere, drag it onto the sceneline.
    - I do not view the file but immediately share it using a preset that matches the requirements of my MVIX PVR.
    This bit is not relevant to the problem per se, but provides background info:
    - I then copy the file onto the PVR decoder.
    - I view the file through an MVIX PVR which allows viewing at 32x speed with minimal data loss.
    - I will then identify activity periods (which may be only 5 minutes per day).
    - I use the camera's editor to extract the relevant clips keeping all the camera metadata intact.
    - After that I may use Premiere again to create illustrative montages.
    CONCLUSION
    Does anyone have a clue as to why I am having this problem? (it is not an error per se)
    - The obvious differences are the operating system, the graphics card and the disk allocation unit size
    - It may well NOT be a Premiere issue, it may be Windows 7 Pro that is causing the problem.
    - I assume that the graphics card is irrelevant as I never actually view the video in Premiere (in this scenario)
    - Could it be that Adobe cannot handle the 64k disk allocation size?
    - Is there some special setting in Windows 7 that I need to enable that wasn't required in Windows XP?
    - Is there some special setting in Adobe that I need to enable when running in a 64-bit environment?
    Or is there something else I am missing?
    Any help would be really appreciated - it could take weeks to try out all the various combinations to identify the problem.
    Giles

    Steve
    Thanx for your insights.  I do not have the disks partitioned (except the system disk, I always like to keep the system files separated from the 'user' files to make backups simpler).
    I suspect you are right that upgrading to 11 would speed things up, but I still suspect there is something more fundamentally wrong in my Windows 7 set-up - my guess is that upgrading to 11 might double the speed of processing - but that would still leave it 50% slower than on the old machine.
    My first step will be to run all the patches on 8 - but not for a few days. We are expecting 3 or 4 days of thunderstorms (normal for this time of year in South Africa) and my UPS hasn't the battery life to keep going during an upgrade cycle.
    Giles

  • Help with running elements 11

    I bought elements 11 and it wont work on my computer.  I Installed it all correctly and I get a system error everytime i try to run the program. "The program can't start because DCIMAN32.dll is missing from your computer.  Try reinstalling the program to fix this problem."  I have no idea what that means, and have unistalled and reinstalled this twice now.  An hour later still same thing.  My other adobe stuff like lightroom work on my computer, its only four months old.  I have elemets 9 and it started saying the same thing a month ago and thats why i bought this one, to hopefully fix the problem. Nope, still there, what can i do to fix this and run photoshop?

    Hello there, just to let you know, I still cant get it to deactivate but I have been on to adobe and they have sorted my serial number out so that I can use it on my new machine

Maybe you are looking for

  • Custom color palette in WAD charts

    Hi BI Experts, we are trying to create a custom color palette, which we want to apply to all your WAD charts. Can anyone tell us how to do this? Of course we can customize the colors in each chart, but that's a hell of a lot of work. Moreover, there

  • Web Service Request Failed

    Hello, Errors in the EE 4 with RedHat ES 3. Web Service Request Failed The following fault was returned from the web service call: Code HTTP String (404)/axis/services/rpc/webtopsession ------ log ----- Starting service Tomcat-Standalone Apache Tomca

  • Is an ID5 exported PDF different from a Distiller PDF?

    Am doing a book cover for a client publishing thru an on-demand press. Press specified the following: "Acrobat Distiller is the ONLY acceptable PDF software (Adobe Library and other PDF programs are not acceptable). . . [MS Word info removed] . . . F

  • Lync Delegate Meeting Creation works in OWA but not in Outlook 2010

    The environment is Exchange Online and Lync Online. When users are assigned Delegate rights (either through Outlook OR via Powershell into Exchange Online) they are able to create regular meetings, modify calendar entries per their rights assigned in

  • How to break range of dates into different months in mm/yyyy format

    See the following eg: MaterialNo         Validfrom         ValidTo            RecordNo                    Value A100                01.01.2007        13.05.2007       1000                           1150/-                          14.05.2007       24.