Enterprise Architect: Control Position or Margin of Element Title - enterprise-architect

Is there a way to configure the margin or position of an element's title in Enterprise Architect?
For example, can I move the word "Foobar" closer to the top of this packaging component to save some space?
I also noticed that some elements seem to have a minimum size even when they are empty. For example, here Component1 cannot be smaller than whats shown in the picture, while the packaging component can made much smaller.

No, you cannot configure that for the standard EA elements.
The only way to influence something like that would be to write your own shapescript, link that to a stereotype and apply the stereotype to the element.
But that would probably be a bit too much if you only want to change the position of the name field.

Related

Trying to reduce the size of boxes on screen

I am trying to setup a style based on bootstrap3.
Basically I want to try and reduce the size of the input elements which I have done, getting a decent proportion of 'box' vs 'text'.
However if I use the same font-size in a select box with the same size then I get a situation where the text is masked along the bottom edge...
I think there is a tiny bit more margin at the top of the select box, but for the life of me I cant find where that is set in BootStrap to change it (if at all).
I think all I need to do is move the text in the 'select' element up by a couple of pixels and it will align with those bits of text in standard text boxes....
Can anyone point me in the right direct please?
Found the associated CSS in the bootstrap, with a bit of trial and error....
Mainly in the 'form-control' section.
but now also using Bootstrap 4, with a couple of additional styles.

Setting text alignment with visio stencil

I'm in the proccess of creating an automated visio diagram script in powershell, adding elements with text like so.
$GROUP = $CPage.Drop($Stencil_AgentList, $x, $Y)
$GROUP.Text = $MatchedGroup.Name
$GROUP.AutoConnect($QUEUE, 0, $Stencil_Connector)
most of the functionality in terms of layout works at the moment, but i'm having serious troubles with the aspects that actually make diagrams look good.
I think this image explains it best: when you 'Edit Text' on an object, it appears to be aligned to the object in some way, either below or on top of it.
what I would like is to be able to align text, from the object itself, to the right side like below, where 'Example user name' is the ideal output.
I'm assuming this involves shapesheets etc. which I have almost no experience with.
Any help or resources on modifying these stencils so the 'text' area is where I want it to be would be much appreciated.
You should check out this page : https://msdn.microsoft.com/en-us/library/aa200988(v=office.10).aspx
The Text Block of a shape is by default, the same size as the enclosing rectangle of the shape. However, you can modify its size, position, rotation and the horizontal and vertical text alignment

TreeViewer no longer sizes properly when using StyledCellLabels

I was using a JFace TreeViewer perfectly well for a while.
It has a bunch of branches of varying lengths, but at the end of the day, the entire tree stretched to the size of its longest string. This was great.
Recently, I decided that the TreeItems labels should have some style to them fonts and highlights.
The trouble, is that the new fonts are a bit larger and stretch the size of the overall string. It seems that the Tree or TreeViewer doesn't recognize this expansion and still judges the size of the label by the amount of small characters in it. The result is that I get a TreeViewer with a horizontal scrollbar, which is highly inconvenient because now my users will have to scroll across each tree, rather than just being to quickly glance at the data.
Does anyone know how to get the Tree to properly fit the length of the longest string, and take into account the added length of the styling, etc?
Thanks!
While this is not a complete answer, I hope it will help jogs someone's memory who has more advanced knowledge on this:
When I set the font to the ViewerCell object to a font that is wide, the entire row properly resizes. It seems that the Tree measures its width by checking the length of the text and the font, but disregards the Style Ranges.

Word Styles to get two elements to share same background/border

Within MS Word 2013 I am trying to create a text element plus a list underneath it, all wrapped inside a coloured border with background shading (see image). The attached image shows the text in plain form.
I would like to place a blue border around both the title and the list. I can achieve this by placing both objects within a 1x1 table and applying colouring rules to the cell, but semantically this seems bad (I'm from an HTML development background where it is very wrong!)
When I edit a Style rule to create the border/background, it works well until I create the list, then it goes badly wrong. Is it possible to achieve the output of the table cell approach by only using a style rule and no table?
After a day of experimentation, the closest I can get is by doing the following:
Create a style rule called Tips Heading based on Normal, then set it to be Bold with a blue background.
Create another style rule called Tips List based on List Paragraph, and set it to have a blue background.
Unfortunately the List cannot be indented because the background colour also indents. The border is also affected in this manner, so I ignored the border and indentation. It works really well and is semantically well structured.

Visio 2013: How to reduce width of built-in UML class shape?

I drew a class diagram of the type 'UML static structure' with Visio 2013. Now I would like to reduce the width of the class shapes in the diagram. I removed the size protection in the developer tools section and also tried to set the width in the corresponding shape sheet but nothing worked.
Does someone know how to do this?
In Visio 2013, you can change class width using a control point (yellow dot), just drag it:
The class shape is composed of a group of objects. You should drag your mouse over it to select not only the external shape, but also all the elements inside it such as the ClassName text and any possibly existing members, etc.
Now, if you remove the size protection as you mentioned, this will apply to all the elements, and then you can change the size using "Size & Position" task pane. (Ribbon --> View --> Show --> Task Panes)