I want to create a grouped object with multiple lines and fill the object with a background color.
As you can see, however, the background does not respect the lines as a frame.
Is it possible to fill only the grouped object within the lines?
It's not possible using grouped lines (style will be applied to whole group which have shape of rectangle) , but you can create custom shape using Arrange > Insert > Shape. You can find description how to do that here or here. If you want to edit shape after inserting it, you can do that using Edit Shape from Style tab in format panel on right (it is also possible to edit some of draw.io shapes).
Example shape similar to your image:
<shape h="100" w="100" aspect="variable" strokewidth="inherit">
<foreground>
<path>
<move x="50" y="0" />
<line x="80" y="40" />
<line x="100" y="50" />
<line x="60" y="100" />
<line x="30" y="100" />
<line x="0" y="60" />
<close />
</path>
<fillstroke />
</foreground>
</shape>
Remeber to use <fillstroke /> or <fill /> if you want colored background.
Related
I have a very large form with hundreds of fields on it. Some are black and some are blue. I'm trying to parse the dxl using xsl to find the fields where they are set to the color blue.
i've found several xsl files to parse the dxl but I can'tfigure out how to find the field then find the previous font color='blue'
Can anyone help me with that syntax? Here is a sample of the dxl I am trying to parse:
<par def="100">
<run>
<font size="9pt" style="bold" name="Arial" pitch="variable" truetype="true" familyid="20" />
</run>
<run>
<font size="9pt" color="blue" style="bold" name="Arial" pitch="variable" truetype="true" familyid="20" />
<field type="text" kind="editable" name="DevComments">
<code event="inputtranslation">
<formula>#Trim( #ThisValue )</formula>
</code>
</field>
</run>
<compositedata type="98" prevtype="65418" nexttype="222" afterparcount="6" containertype="65418" aftercontainercount="1" afterbegincount="3">Yg4BAIQAAAAAAAAAAAA=</compositedata>
<run>
<font size="9pt" style="bold" name="Arial" pitch="variable" truetype="true" familyid="20" />
</run>
</par>
I have a gantt chart which is created from a stacked bar chart. I am trying to make the h-axis titles look different from each others, like in the image below. I've look into the API and could not find any solution.
Does anyone know how to accomplish this?
Individual styling is not supported with Google API. So if you can handle risk of future code break you can 'manually' change text properties.
As a example I used Simple Example from google docs and change it to the stacked bar chart.
The following elements are created in DOM for labels on the left (2004 - 2007):
<g>
<text text-anchor="end" x="147" y="139.9" font-family="Arial" font-size="14" stroke="none" stroke-width="0" fill="#222222">2004</text>
</g>
<g>
<text text-anchor="end" x="147" y="216.9" font-family="Arial" font-size="14" stroke="none" stroke-width="0" fill="#222222">2005</text>
</g>
<g>
<text text-anchor="end" x="147" y="293.9" font-family="Arial" font-size="14" stroke="none" stroke-width="0" fill="#222222">2006</text>
</g>
<g>
<text text-anchor="end" x="147" y="370.9" font-family="Arial" font-size="14" stroke="none" stroke-width="0" fill="#222222">2007</text>
</g>
You can change them using for example:
var labels = document.querySelectorAll('text[text-anchor=end]');
for (var i = 0; i < labels.length; i++) {
if (labels[i].textContent == '2004') {
labels[i].setAttribute('font-weight', 'bold');
labels[i].setAttribute('font-size', '20');
}
if (labels[i].textContent == '2005') {
labels[i].setAttribute('font-style', 'italic');
labels[i].setAttribute('font-size', '20');
}
}
See whole example at jsbin.
I am trying to add a new string field (IterationCompleted) to the bug work item in tfs2010. Using the TFS 2010 power tools I edited the work item adding the new field. This results in the following XML
<FieldDefinition reportable="dimension" refname="DevX.IterationCompleted" name="Iteration Completed" type="String">
<ALLOWEDVALUES>
<GLOBALLIST name="Iterations" />
</ALLOWEDVALUES>
<ALLOWEXISTINGVALUE />
<DEFAULT from="value" value="∞" />
</FieldDefinition>
I added it to the form next to some related fields. Here is the relevant XML
<Group Label="Classification">
<Column PercentWidth="100">
<Control FieldName="System.AreaPath" Type="WorkItemClassificationControl" Label="&Area:" LabelPosition="Left" />
<Control FieldName="System.IterationPath" Type="WorkItemClassificationControl" Label="Ite&ration Found:" LabelPosition="Left" />
<Control FieldName="DevX.IterationCompleted" Type="FieldControl" Label="Iteration Resolved:" LabelPosition="Left" Name="IterationCompleted" />
<Control FieldName="DevX.Customer" Type="FieldControl" Label="Customer:" LabelPosition="Left" />
<Control FieldName="DevX.ReleaseNotes" Type="FieldControl" Label="Include in Release Notes:" LabelPosition="Left" />
<Control FieldName="DevX.Billable" Type="FieldControl" Label="Billable:" LabelPosition="Left" Name="Billable" />
</Column>
</Group>
It is not involved in the workflow at all.
The problem I'm having is in the form. For new bugs, the field appears as expected and is editable (Iteration Resolved):
For old bugs however, the field is not editable. In fact there is no control at all there to input anything:
I found a similar question with an accepted answer to make sure the field is String and that on the Form the type is set to FieldControl. As you can see I have done that and still get the results I am seeing above. I have successfully added fields in the past and never encountered this problem. Does anyone know what I can do to get this field editable in old bugs?
I came across the same behaviour... Or at least similar...
I had to add default values for all the lists..
When I did not have a default value, any WIT's which had already been created could not have there values set, as it was not a ALLOWEDVAULES LISTITEM...
(Note: This code/XML changes the value of a list depending on the state of the WIT)
Sample:
<FIELD reportable="dimension" refname="GovDept.ActionRequiredTFS" name="Action Reqd TFS" type="String">
<WHEN field="System.State" value="Proposed">
<ALLOWEDVALUES>
<LISTITEM value="Assess" />
<LISTITEM value="Prioritize" />
</ALLOWEDVALUES>
<DEFAULT from="value" value="Assess" />
</WHEN>
<WHEN field="System.State" value="Active">
<ALLOWEDVALUES>
<LISTITEM value="IA Complete" />
<LISTITEM value="Impact" />
<LISTITEM value="Implement" />
<LISTITEM value="Migrate" />
<LISTITEM value="Unit Test" />
<LISTITEM value="Fix Fail" />
</ALLOWEDVALUES>
<DEFAULT from="value" value="Impact" />
</WHEN>
<WHEN field="System.State" value="Resolved">
<ALLOWEDVALUES>
<LISTITEM value="Test" />
<LISTITEM value="Fix Fail" />
</ALLOWEDVALUES>
<DEFAULT from="value" value="Test" />
</WHEN>
<ALLOWEXISTINGVALUE />
</FIELD>
End of Sample
I just had this problem in TFS 2010 using VS2012.
Steps to reproduce:
Create custom field type:String
Add field to layout, ensure it is a FieldControl
Preview Form: Works fine
Go to a query and double click and existing work item of the type you are editing
(for me it was a Backlog Item.)
Observe no proper way to edit field, even if cursor shows in field. Appears to be read only.
After verifying the field was not read only (Property false in layout), I restarted Visual Studio after saving the edits.
That cleared the issue and the edit control started working normally. I can reproduce this over and over.
Dustin,
We have never heard of this behavior. If you want Microsoft to take a look at this issue, you can file a bug at https://connect.microsoft.com/visualstudio
Ewald Hofman
TFS Program Manager
According to this page http://help.adobe.com/en_US/ColdFusion/9.0/CFMLRef/WSc3ff6d0ea77859461172e0811cbec22c24-792e.html you can use a dataLabelStyle which can be "none", "value", "rowLabel", "columnLabel" or "pattern". However whenever i use "rowLabel", "columnLabel" or "pattern" the image doesn't show. There is no error, just a blank canvas where the image should be. Does any one know how to work around this?
Thanks
I had the same problem, and I found that when I add the legend attribute placement, that is when the chart disappears. The legend shows with the placement indicated, but no chart.
I finally figured out what to do, I started from scratch with the bare minimum pie chart with examples from this page:
WebCharts3D Piecharts
And I discovered that the order of the elements in the XML file was the issue.
This is how my XML file is now and it works:
<?xml version="1.0" encoding="UTF-8"?>
<paint paint="Plain" />
<title>
<decoration style="None"/>
</title>
<dataLabels style="Pattern" font="Arial-16-bold">
<![CDATA[
$(value), $(colPercent)
]]>
</dataLabels>
<legend placement="Right" font="Arial-16">
<decoration style="None"/>
</legend>
<insets left="10" top="10" right="5" />
<elements action="" shape="Area" drawOutline="false">
<morph morph="Blur" /> <!-- other options: grow, none -->
<series index="0">
<paint color="#E48701" /> <!-- orange -->
</series>
<series index="1">
<paint color="#A5BC4E" /> <!-- lime -->
</series>
<!-- ...(etc) -->
</elements>
</pieChart>
This test of the five(5) styles works fine for me.
Maybe it is your code? Probably not a version problem as dataLabelStyle was introduced back in MX7 .
<cfloop list="value,rowLabel,columnLabel,pattern,none" index="style">
<cfchart format="png" scaleFrom="0" scaleto="30">
<cfchartseries type="bar" dataLabelStyle="#style#">
<cfchartdata item="bar" value="25">
<cfchartdata item="foo" value="10">
</cfchartseries>
</cfchart>
</cfloop>
The following string gets encoded in my source XML using toggles, and I want it changed to nodes with formatting information. (This is XLIFF to WordprocessingML.)
"Text, bold text, bold and italics text, bold text, plain text."
Source XML:
<text>
Text
<format id="1" type="bold" />
bold text,
<format id="2" type="italics" />
bold and italics text,
<endformat id="2" />
bold text,
<endformat id="1" />
plain text.
</text>
I need:
<run>
<format></format>
<text>Text, </text>
</run>
<run>
<format><b/></format>
<text>bold text, </run>
</run>
<run>
<format><b/><i/></format>
<text>bold and italics text, </run>
</run>
<run>
<format><b/></format>
<text>bold text, </run>
</run>
<run>
<format></format>
<text>plain text.</run>
</run>
If I were using a procedural language, I'd keep a running record of what formatting is active and write out the <format> element accordingly.
But how do I do it in XSL?
Since the child nodes of text are alternating text() followed by format with symmetric endformat and text() I think you can pass a list of the nodes to xsl:call-template recursively, processing two start nodes and 2 end nodes and shortening the list by the leading 2 nodes and traling 2 nodes each time. But I am not clear about the syntax of your file so this may not be possible.