Jump to content

Vector Themes


Slice
 Share

455 posts in this topic

Recommended Posts

19 hours ago, blackosx said:

That looks good. 

My file has frame 1 -> frame 39

So frame 0 -> frame 38 is fine.

This is the first issue. It was not found frame_0 and then

      if (Screen->Film[0] != NULL) {

:)

 

Looking more...

  • Like 1
Link to comment
Share on other sites

And second issue is initializing values

  Anime->FilmX = INITVALUE;
  Anime->FilmY = INITVALUE;
  Anime->NudgeX = INITVALUE;
  Anime->NudgeY = INITVALUE;

As well time should be reduced

FrameTime="50"

And Voila!

Screen Shot 2018-12-03 at 20.44.37.png 

Committed to 4789

  • Thanks 1
Link to comment
Share on other sites

Just tested and I see animation works! :D

 

But it's not right. :(

It should look like Anim_1_Logo animation from BGM.

 

Each frame has size boundingrect set to 800x100, for example:

<rect visibility="hidden" id="BoundingRect_74_" y="0" class="NoFill" width="800" height="100"/>

 

Should look like this (here's frame 7 and 36).

frame7and36.jpg.9cc17c94afc3b09e7134a10e3f1f9c90.jpg

 

But all whitespace/empty space is cropped, leaving each image centred.

 

Can you retain the full bounding rect and not crop on empty space?

 

Link to comment
Share on other sites

Understand. It looks like in VectorGraphics.c line 204

  if ((Id != BUILTIN_ICON_BACKGROUND) && (strcmp(IconName, "Banner") != 0)) {

    float realWidth = (bounds[2] - bounds[0]) * Scale;

    float realHeight = (bounds[3] - bounds[1]) * Scale;

    tx = (Width - realWidth) * 0.5f;

    ty = (Height - realHeight) * 0.5f;

  }

should add condition 

&& (Id != BUILTIN_ICON_ANIME)

 

Can you check?

Link to comment
Share on other sites

It's better, but still not completely correct as all images are now ranged left. This is good.

 

But left side of image is still cropped (has whitespace removed) resulting in all image content being aligned to same X position.

 

anim_grabs.thumb.jpg.d7fcffdf9fbed2612323661858a87e2e.jpg

 

Where in post above I show the content in frame 7 (the fragments) is further left that the CLOVER word/icons

 

Link to comment
Share on other sites

Okay. I'll take a look at animation again soon.

 

Moving away from animation for now, can you check 2 things for me when you get time?

1 - I cannot figure out why Banner_night does not show. Am I missing something obvious?

2 - Background does not scale?, even though I have set BackgroundScale="scale"

 

EDIT: Attachment removed

 

Edited by blackosx
Link to comment
Share on other sites

Something wrong here

17:196  0:009  Use anime=<null string> frames=65535
17:208  0:012  icon 'frame_1' not loaded, status=Not Found
17:220  0:011  icon 'frame_2' not loaded, status=Not Found
17:231  0:010  icon 'frame_3' not loaded, status=Not Found
...
72:301  0:011  icon 'frame_4545' not loaded, status=Not Found
72:315  0:014  icon 'frame_4546' not loaded, status=Not Found
72:327  0:011  icon 'frame_4547' not loaded, status=Not Found
72:338  0:010  icon 'frame_4548' not loaded, status=Not Found
...

 

Link to comment
Share on other sites

Thank you for taking the time to check my theme slice.

 

EDIT: Making suggested changes:

- 1 - Fix AnimeFrames=“"

- 2 - Remove class=""

- 3 - Change background size to 1920x1080.

- 4 - Remove transform scale=1

 

Banner_night still not showing.

Background not being scaled horizontally.

 

I'll try to run a debug and see what's going on.

 

 

 

Edited by blackosx
Removed images of work-in-progress theme
Link to comment
Share on other sites

22 minutes ago, blackosx said:

You mean ?

(strstr(IconName, "Banner") != NULL)

:)

 

EDIT: Works

There is another place several lines below

  if ((Id != BUILTIN_ICON_BACKGROUND) &&
      (Id != BUILTIN_ICON_ANIME) &&
      (strstr(IconName, "Banner") == NULL)) {
    float realWidth = (bounds[2] - bounds[0]) * Scale;
    float realHeight = (bounds[3] - bounds[1]) * Scale;
    tx = (Width - realWidth) * 0.5f;
    ty = (Height - realHeight) * 0.5f;
  }

 

  • Like 1
Link to comment
Share on other sites

To do this we should implement SelectionColorNight="..." and insert parsing into nanosvg.c here

    } else if (strcmp(dict, "SelectionColor") == 0) {

      GlobalConfig.SelectionColor = getIntegerDict(dict[i + 1]);

with checking time of day.

For example

 

    } else if (strcmp(dict, "SelectionColor") == 0) {

      if (DayLight)

      GlobalConfig.SelectionColor = getIntegerDict(dict[i + 1]);

    } else if (strcmp(dict, "SelectionColorNight") == 0) {

      if (!DayLight)

      GlobalConfig.SelectionColor = getIntegerDict(dict[i + 1]);

 

But typefaces is more complex.

  • Like 1
Link to comment
Share on other sites

I think it is better to implement night menu 

Daylight as usual

<g id="MenuRows" class="st0"><text class="st1">Menu</text></g>
<g id="HelpRows" class="st0"><text class="st2">Help</text></g>
<g id="MessageRow" class="st0"><text class="st3">Boot macOS from HDD</text></g>

and for night

<g id="MenuRows_night" class="st0"><text class="st1n">Menu</text></g>
<g id="HelpRows_night" class="st0"><text class="st2n">Help</text></g>
<g id="MessageRow_night" class="st0"><text class="st3n">Boot macOS from HDD</text></g>

 

  • Like 1
Link to comment
Share on other sites

1 hour ago, blackosx said:

Thanks for the SelectionColorNight instructions.

And yes, a separate night menu would be cleaner to visualise and handle.

 

I will try later when I get time.

I committed these advances for you to draw and test when you will have a time and wish.

  • Thanks 1
Link to comment
Share on other sites

Not sure if here is appropriate but I just downloaded the 10.14.2 combo update and rebooted, I am using the Clovy theme but when I chose the install macOS drive file on the GUI it just froze. I tried this three times with no success until I changed to a standard theme then I could boot the install macOS from xxxx drive.


Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

@Slice

I'm testing using symbols for OSBadge but not having success getting Clover to load it. Can you help?

 

Here are two files which I've created to test the elements.

test_basic_badge_offset_in_finder_good_in_ai.svg

Test_os_cap_not_bad_in_finder_wrong_in_ai.svg

 

However, when I put this in to theme.svg for Clover I'm not seeing the Badge. Debug shows:

2:893  0:003  search for os_mac
2:905  0:002  load os_mac status=Not Found
2:907  0:002  OSicon os_mac not parsed

Here's are 2 slightly different theme.svg files I'm using.

Theme.svg

Theme2.svg

 

Gives me the following result.

1622146691_Screenshot2018-12-07at21_50_03.thumb.png.0d9be761e4895dd644286365a556748b.png

 

Can you identify what's wrong and why the os_mac badge is not showing?

 

Thanks

 

 

  • Like 1
Link to comment
Share on other sites

 Share

×
×
  • Create New...