Jump to content

Tracy Debugger


adrian

Recommended Posts

1 minute ago, szabesz said:

I am really thinking of the basics here, nothing more: id, count() that's all that comes to my mind

It's not really that simple though - a page object doesn't have count. In the case of count(), it is relevant to PageArray, PageFiles, PageImages objects, but also to field types with multiple values. Then there are template, field, module etc objects - what should be displayed for those? 

  • Like 1
Link to comment
Share on other sites

1 minute ago, matjazp said:

I prefer buttons or links top left with descriptive text instead of icons...

 I don't disagree with you, but I also don't want to pollute the dump output with lots of extra stuff. It could easily look quite messy with several object dumps, all of which have text / button links to the debugInfo and Full Object versions.

 

  • Like 1
Link to comment
Share on other sites

5 minutes ago, adrian said:

Then there are template, field, module etc objects - what should be displayed for those? 

How about doing it only for objects with ID and Array/WireArray? Just a simple isset/instanceof to decide what to do?

Link to comment
Share on other sites

Im on mobile so I can't do a mock-up but I vote for a text based solution like matjazp mentioned and I would put the tabs above the dump. Just like the tabs in processpageedit. They would be code for the mouse and would not mess up alignments on the left or right.

I don't want any automatic additional info. As Adrian said the need is always different and the solution is just one extra dump away. Please save your time Adrian ? thanks for all your great work! Still waiting for a donation button ?

  • Like 1
Link to comment
Share on other sites

Ok @bernhard - here's a try a tabs. I think this works ok and looks ok, although I am sure someone out there will want to tweak the look of it - looking at you @tpr ? - and happy for your thoughts!

Is everyone happy enough with this so I can finish it up and commit?

image.png.0c38a7c9b4364b0e0353ec11af31b200.png 

  • Like 2
Link to comment
Share on other sites

@szabesz - this isn't the count of a PageArray that you were looking for, but it does return the ID of each page and is linked to the edit interface for the page. Is this at all useful? I think this is simple and clean enough not to be too messy

image.png.899a549e8ba85416bc92de149bbd3339.png

  • Like 2
Link to comment
Share on other sites

Is the white tab the active one? If not, I would change it so, and perhaps remove the bottom border.

However, perhaps pills instead tabs would look better here, I will make some mockups when I will have time.

  • Like 2
Link to comment
Share on other sites

7 hours ago, adrian said:

Is everyone happy enough with this so I can finish it up and commit?

Absolutely awesome ? tpr is right about the bottom border but it's already great imho ??

for my understanding I'd also see the white tab as the active one (having the same colour as the dump section)

  • Like 1
Link to comment
Share on other sites

Thanks @tpr and @bernhard for the feedback - here is the new version with white tab as selected and also with no bottom border. I am going to go ahead and get this version ready for committing. If you guys want to tweak after that you can send me a PR.

image.png.b203d4c0c8fb000fe417477c29865edd.png

image.png.71350844ad6c158e3a8d5bc708151347.png

 

I was also playing with a version where both tabs are white, but I think it's a little less clear when it's so small like this:

image.png.6207f22cf352fdb8991e55e75828e679.png

Link to comment
Share on other sites

I like the first one. Is the dotted border style intentional or comes from tracy core? I think solid would be better.

The brown color is also from tracy core? Seems too old fashioned to me, I think very pale blue would be more modern, eg like borders in the reno theme.

  • Like 1
Link to comment
Share on other sites

The dotted style is what the Tracy core wraps around dumps. I suppose we could override it completely.

The brown - do you mean the non-active tab color? That is the color that you chose for the title header bar for all the panels. It looks browner than it really is when I do a copy/paste screenshot on my Mac - never bothered to find out why.

Do you want me to send you a copy before I commit that you can mess with, or are you happy enough?

Link to comment
Share on other sites

Ok, new version just committed with the tabbed debugInfo / Full Object interface for dumps and barDumps.

Please test and let me know if you notice any problems or have ideas for improvements. 

Don't forget to do a hard reload to get the new css/js that this feature requires.

Thanks to everyone for your feedback on this - it's made it significantly better!

Link to comment
Share on other sites

Thanks, I gave it a go and it was almost perfect ? The main issue I found is that you applied the padding to the list items and not to the links inside them so not the whole tabs were clickable (or at least the links weren't entirely fill the tabs). I also enlarged the tab sizes to make them easier to click on. Plus I removed the dotted border styles, for me it now looks less "crowded". I needed to replace these items in 2 CSS files as I remember, but perhaps there are other places too (#D9E1EA is the new border-color I used):

dotted silver => solid #D9E1EA

As for hiding the active tab's bottom border, I enlarged the link's bottom padding by one pixel and applied a negative 1px bottom margin (instead of the existing box-shadow). I have also added some padding to the edit link at the end of the tab bar for easier click.

I didn't like the white background on hover because it looked the same as the active item, so I made it slightly darker instead.

tracydumptabs.gif.415fe699fc72791cd63fedd5539a659b.gif

Feel free to add/modify these if you feel so.

styles.css

  • Like 1
Link to comment
Share on other sites

Thanks - I like the darker hover (instead of white). I am not sure about the increased size of the tabs though - they take up a lot of space and I think they look a bit weird when you have added a title - see how they are taller than the title element.

image.png.ce740b132b6e5b3d20444eb425d417ed.png

5 minutes ago, tpr said:

The main issue I found is that you applied the padding to the list items and not to the links inside them so not the whole tabs were clickable (or at least the links weren't entirely fill the tabs)

Good catch - thanks.

6 minutes ago, tpr said:

I removed the dotted border styles, for me it now looks less "crowded"

Did you do this in the core Tracy files? If we're going to take this approach, I'd rather override if possible, rather than hacking the core. Did you try that and have problems?

Thanks again - always super-appreciative of your skill with this stuff.

Link to comment
Share on other sites

I haven't taken the title into account, sorry.

How about using no background for titles? That would solve this issue and even make the panel clearer.

They could be made smaller but eg touchpad users would easier target larger tabs.

Edit: of course I can live with that ?

Link to comment
Share on other sites

2 minutes ago, tpr said:

How about using no background for titles? That would solve this issue and even make the panel clearer.

I'm not really sure how to make it look decent without a background - with this the title just looks out of place to me. But I'd love to see your idea for how it might look!

image.png.b97ba620cc532571bba5098779f33314.png

3 minutes ago, tpr said:

They could be made smaller but eg touchpad users would easier target larger tabs.

Do you think TD is getting much use on a touch screen? I have done small amounts of work like that, but mostly drives me crazy!

Link to comment
Share on other sites

Yes, I thought about something like this, with some additional bottom margin in the title, and perhaps a little larger font size but that would not add too much difference. Like headlines in documents. Anyway it's ok to me leaving as it was but I feel that the new tab bar and the title with background is too boxy. 

Alternatively if the whole tab block would have the same bg color as the title (so making the title and the tabs one unit) then that could have the best of the two worlds. So on your last screenshot the area to the right of the last tab would not be white but the same as the inactive tab, even when there is no title. I can upload a preview tomorrow if you need.

Touch screen: I meant a notebook touch pad, and I sometimes have to use it, eg on a train.

Link to comment
Share on other sites

1 hour ago, tpr said:

Alternatively if the whole tab block would have the same bg color as the title (so making the title and the tabs one unit) then that could have the best of the two worlds. So on your last screenshot the area to the right of the last tab would not be white but the same as the inactive tab, even when there is no title. I can upload a preview tomorrow if you need.

Yeah, I think this could work quite well. If you feel like having a go at this tomorrow, that would be great thanks!  You can start from the latest styles.css I attached above.

 

1 hour ago, tpr said:

Touch screen: I meant a notebook touch pad, and I sometimes have to use it, eg on a train.

Sorry, I understand - I actually use my touchpad exclusively these days - never thought I would give up a mouse, but I actually prefer it now that I am on a Mac and the touchpad is actually decent, although I am sure new Windows ones are good these days too. Anyway, I think the size I have it at now should be fine.

 

Link to comment
Share on other sites

Thanks @tpr - that looks really great! There was only one issue - in the Console panel, the page ID link was positioned at the far right of the console, rather than the dump element. Attached version fixes that if you want to take a look before I commit.

@bernhard - not sure what's going on there, it seems to work fine here. Could you try to debug why it's not working at your end please?

image.png.d8af02f6f4a6728accbfc24e2b16802c.png

 

 

styles.css

  • Thanks 1
Link to comment
Share on other sites

  • adrian pinned and locked this topic
  • adrian unpinned and pinned this topic
Guest
This topic is now closed to further replies.
×
×
  • Create New...