[MUSIC].
>> Hey everybody, I'm Jordan Matthiesen.
I'm a Program Manager on
the Visual Studio for Mac team at Microsoft.
Today, I'm going to take you through
our new Visual Studio 2022 for
Mac and the latest Preview 3 release that we just put out.
This is our release that now has support for .NET 6,
C# 10 and really big focus in this release for us is
on updating the IDE to
have a much more comfortable feel for developers,
presumably like yourselves who like to work on a Mac.
We've focused heavily on the UI of the IDE,
moving it to a fully native macOS UI.
Now, if you've been with us for a while in Visual Studio for Mac,
the IDEs have been a combination of
UI technologies that were native macOS UI,
as well as a cross-platform toolkit that we used to use.
That could lead to some experiences didn't feel quite Mac-like,
things like tabs feeling off
or just little controls didn't feel quite right.
This was a big opportunity for us
to go ahead and revisit those and do it
right to get this nice comfortable feel
for being a Mac-native application.
Along with that, that also give us an opportunity to go and fix
a number of UI glitches that have been in the IDE for a while,
as well as smooth out the experience for you,
so a big thing you'll notice will be this UI responsiveness,
things like resizing windows,
generally moving around the IDE should feel snappier.
That was a really big goal of the release,
as well as getting it to feel more
comfortable for those of you who are familiar with using,
say Visual Studio from on Windows,
got a number of developers have come in and you've got
some history working with Visual Studio.
We want you to be able to take
the knowledge you may have from the past
to go ahead and bring it into Visual Studio for Mac
and find your ways around.
I have a few things I'll give you a demo of
the changes we've made along those lines.
Another big thing that we announced
this week is our future plans for support
of the M1 processor from Apple
running the IDE natively on M1 processors.
This is Apple ARM64 processor if you weren't familiar.
We're going to do this and I love this part,
geeky detail of moving the IDE running on top of .NET 6,
CLR, the Common Language Runtime itself,
which will also bring a number of improvements to the IDE for
things like low-level performance of our file operations,
is like working with file system watchers
that are used across the IDE.
That combined with our new front-end of the IDE,
makes a really good release us around
these improvements on long-standing issues
we've had with performance.
We've got a blog post that I put
out that has some details of our findings
working on the M1 support and what's coming up there soon.
We don't have the release ready yet,
but I'm going to demo right now.
But keep an eye out on our blog going
forward to see when that M1 processor support comes out.
Let's go ahead and dive on into the IDE.
Today I'm going to take you through
some of those things I just mentioned,
the new stuff that we're working on.
Here you're looking at the Visual Studio 2022 for Mac IDE.
Right away, if you've used prior versions,
you might notice a few things.
Our status messaging is moved from
the window title on down to the bottom of
the IDE and you'll see this when I do things
like go to run my project, which we'll do right now.
Status messaging moves down towards the bottom.
The tabs have a more modern macOS
feel as well as a Visual Studio feel to them.
If you weren't familiar with Visual Studio for Mac
there's three major types of projects you can work on.
There's this case, I'm working on a .NET Project.
This one I believe is .NET 5.
The IDE supports building apps
for the web and the console with .NET Core 3.1,
.NET 5 and now .NET 6,
as well as building out mobile applications
using traditional Xamarin projects.
MAUI support will be coming soon and it's not in the build yet.
But if you're looking for .NET 6 and MAUI support,
stay tuned on the blog,
there'll be updates after the calendar year to support that.
Then finally, if you're a game developer for Unity,
you can go and edit your script in VS for
Mac and be able to edit and
debug those in the IDE moving back and forth from Unity,
that's all supported in this preview release.
What I'm demoing right now is
a sample application we've had for
a bit that is like an online marketplace.
Then here I can add something to my cart.
I was looking at a bug that was going on in
here that we can just troubleshoot together.
This is where I can
remove an item from my cart by changing the quantity to
zero and I click this "Update" button
and it's supposed to go away,
but it's not going away.
Let's go back to Visual Studio for Mac.
I'll troubleshoot this and see what's going on there.
Now, right now we're in a debug mode,
the time being and we're going stand here actually.
I know that the code I want to look at is in
this piece of the application called the BasketService.
If I use the search bar up in the IDE,
I can search for BasketService.
This bar, it searches both files, types,
and members in your code,
as well as commands in the IDE menu items.
In this case, I'm going to pick into the BasketService class.
I know that what I want to work
on is a method that's called SetQuantities.
I got this far in my debugging
previously and then had to stop here.
Let's go and set a break point
and I'm switching back to the browser,
we'll try this action again with
the "Update" button and then our break point gets hit.
You can, this is just to show
that our native UI is up and running.
All these usual features for debugging are here.
The ability to come in and work with
your Locals window, the Watch's window.
I could explore items inline
here and take a look at this collection,
drill into the different items.
All the tools here are used to using for
debugging are up and running in this preview.
I can actually see if I look down,
I had a note to myself that I just forgot about was to
actually implement this remove item functionality,
so I'm going to stop
debugging and we'll just write some code real quick.
The first thing I need to do, I know that there's
this basket object and I need to
call a remove empty items method on this.
Here's our IntelliSense list,
and it lets me filter through options like
members of the types of methods properties.
If I click on "RemoveEmptyItems'',
I can just type the semicolon now and it will auto close
the parentheses because it's got
no parameters to that method and finish off the line.
This is a change that came in,
I think in the past few releases,
just a nice little shortcut.
Then there's one more step in here with this basket repository,
where I need to call this UpdateAsync method,
which takes that basket as a member of it.
You can see some tooltips popping up here to show us ways to work
with this code and let's save that.
If I had implemented some unit tests for this piece of the code,
which I did not but if I did,
I could go into our test window right now and be
able to take these and run the unit tests.
There's a test results window that'll come
up and let me debug that.
In this case, I did not have unit tests for this,
which would have been a good practice.
We'll go ahead and run the project and
just see if it's fixed in the Web browser.
One other little item of note in here while this is running,
you might have noticed the menu items in the IDE are
different if you've been with us for
a while with Visual Studio for Mac.
This is one of those steps to make it
feel more like Visual Studio,
make it easier to bring what you're familiar with
from Visual Studio with you into Visual Studio for Mac.
We've got Git menu now,
Project, Build, Debug,
have items that you might be familiar with from
working in other Visual Studio products,
including a Quick Watch window,
which has been a request we've heard from a number of customers.
We were stopped at a break point,
now I could fire a quick watch.
Now let's double check to see if this is fixed for us.
We'll go and we'll add another item to the basket.
Let's see if we can go ahead and remove this.
I drop the counter and now I hit "Update".
Yay, now our item is fixed and the bug is done.
Next step would be let's commit this to source control.
I showed you some of our new menus a moment ago with the IDE.
Now if we go over here to the Get Changes window,
this is another big new feature that we're bringing in.
In Visual Studio, there's been a number of improvements over on
Windows to the Git experience over the past few years.
We're beginning to start bringing
these items into Visual Studio for Mac.
The Get Changes is one of the first,
now real big examples of that work.
Here I can come in and I could review changes that have been made.
Say to this csproj,
I could compare it with what's up
in Git and see what edits have been made.
I could take a look
at the history of any changes made to the file.
In this case, I've been working in this one service for a bit.
Let's go find the BasketService we were just working on.
I could take a look at history of changes that
were made to do note got left.
This is it something I forgot that it comes somewhere else.
I come through here and browse and get a summary of
changes that were made to that with history edits to this file.
Or as a final step, I can come
and just take the items that I want,
say this list looks good,
I want to move the BasketService up,
I can stage the change.
Now I can type in a commit message,
push it up to the server,
or pull an exit down and go from there.
This, I mentioned is one of the first steps
in the Git tooling we were working on.
We are also working toward adding in a Git branch selector.
It's not in the build you're using yet.
But it's another one to keep an eye on that
we will have before we release.
The plan is to release Visual Studio 2022 for
Mac after the new calendar year.
We're working on still few
finishing details and a Git branch selector will be one of those.
Let's go back to the source code for a moment,
which is a big area, a lot of us spend our days.
I want to call
your attention to the light bulbs that were coming out.
Now, you may already be familiar with the light bulbs,
but if not, let me explain how these work.
When I'm on a line of code like I am here,
you may see a light bulb pop up.
This is the IDE telling you that
there's a change you should make to your code,
either to meet the code formatting requirements
of your code base,
or to deal with something,
say it's identify in .NET,
like this is a built-in thing
that you should do with your source code.
Look for the light bulbs as
those strong suggestions to make changes.
There are other types such as a Screwdriver icon that shows up.
This will give you suggestions for
improvements that are maybe nice to have.
You could make them but not a strong suggestion.
In this case, if we come back up,
I'll click on the light bulb, it showed up.
What you're seeing here is our new Quick Fix dialogue.
We have changed this up,
brought back a Preview pane to show you what will happen if you
select on the left side one of
these suggested improvements to your code.
On the right side, it shows you what
that say refactoring will do to your codebase.
One of our themes in the work that we're doing in
the IDE is to improve accessibility.
This is one of the drivers for this new UI.
The previous solution wasn't
very accessible for working through items.
While we revisited making it into a more accessible UI,
we also worked on some improvements for making it easier
to quickly get to a refactoring you want to apply.
For example, right now I can hit
Option Enter, brings up that list.
I could say that I actually want to invert the if.
I can type a filter in and
then I'll just hit Enter and apply that change to my code.
I just mentioned accessibility.
That is another really big piece of
the native macOS UI work that we've got going on.
Previously, there are portions of
the UI that you couldn't really get into
well with Apple's built-in accessibility tools like VoiceOver,
the text-to-speech service that they provide.
Now that we're all native UI,
everything can be accessed using those tools.
If I were to come in here to
the System Preferences and go into the Accessibility settings.
Using some options like VoiceOver
to be able to navigate through my IDE,
or I can go in and we actually now have
a new high-contrast themes available,
both the dark and the light themes of the IDE.
Now you've got, if we go back and I
actually really like the way this looks that
I almost was thinking making it my daily color theme.
The stronger strokes around borders,
higher contrast, makes it pop more.
Likewise, this applies if we go to light mode.
This is always a fun,
easy way to see that it's a native UI for the IDE.
I can change the option now at
the system level and Visual Studio for Mac
over System Settings and
adapt to the light or the dark theme as you choose.
Or you can choose the auto theme with macOS which
will go light during the day time,
dark at night time. It's changed.
I'm going to go back to
dark and we'll turn back off high-contrast mode.
Now let's talk preferences for a moment.
This is where you could go if you wanted to
actually choose a different theme for the IDE,
you can go light if you prefer other apps and the OS to be light,
but maybe the OS is a dark theme or
you could mix it up, or in this case,
choose the default which is auto to adapt to the OS settings.
But preferences is a fun screen.
I always like to go on here on any new app I'm trying out.
It's a fun area to look and see what are some of
the options you might be able to
turn on in the product you're working with.
It's also one of the best examples of
our native UI work because this was one of
those places in the IDE that everything was
this other UI toolkit I mentioned.
Here, all of the controls are now native macOS UI.
There's a full refresh of the screen.
There's more of these screens we're still working on.
They aren't all in the Preview 3 released just yet,
but we're rolling out more and more of these.
By the time we hit our general release next year,
we'll have all the preferences brought over,
as well as a few sprinkling of some new options as
well that we'll be bringing in over time.
We just covered a bunch. Native UI of the product,
some new features from Windows like the Get Changes window.
I mentioned .NET 6 in C# 10.
I mentioned earlier, but I want to hit on
it again about what's coming soon with us running
the IDE on the .NET 6 common language runtime, the CLR.
That to users of the IDE will have some nice improvements for
things like as you work
with the file system and make some changes,
maybe through Git, the IDE
should be able to be more responsive and picking those
up because we've got a whole new low-level
like IO stack for the IDE.
Those are things that are harder to demo,
but that you'll see coming on as we change up
this last lower layer of the IDE and get it on .NET CLR.
I mentioned the refactoring a little bit and other fun
one here is what C# 10 in a project,
there's a few new refactorings too,
we'll have more on our release notes.
But for example, I could come in here now,
start converting my project over to C# 10 and use
this new refactoring to move my namespace to be file scope.
We've got a number of other nice things like
that across the IDE coming in,
more and more refactoring.
The list keeps growing.
Check our release notes to see more examples of
some of the ones available in the IDE these days.
Finally, I mentioned windowing changes.
One other thing coming soon is the ability to
more easily move around your tool Windows.
The build I'm running right now doesn't have some of this in,
but we're working to improve
the drag and drop experience for a tool Windows.
Much like Visual Studio,
gives you a spot you can drop your window and be able to dock,
say to get changes on the right side or the left side of the IDE,
that's a spot you'll see us improving.
In this build here,
you're able to come in and work with document group.
I could say a new vertical document group,
and be able to look at two documents side by side.
Move those back. It's another example of where we're adopting
some similar terminology from Visual Studio
where there's support for document groups.
With that, I'll just leave you with
some more information on where to get more details.
We put out a blog post about the Preview 3 release,
highlighting the items I mentioned here
today and talking a bit about what's next
with running natively on the M1 processor
as well as our Git branch selector.
You can go to the blog post,
download the release now,
and you want to stay up with us too,
we're working on a preview newsletter,
so you can join in and just get updates directly from the team
when we put out a new preview release and
what are the new features we've introduced,
giving you some opportunities to provide
some more feedback to us, things like those.
Please go ahead, take a look,
go check it out and let us know what you think.
Anytime going to the IDE,
you can use the Help menu, choose Report a Problem,
share your problems you run into,
and yeah, we thrive on your feedback.
The more that we can get in these
early days of previews, the better.
In closing that, again,
this release will be looking at generally available.
The final release of 2022 for Mac will be after the new year.
Preview 3 available now and look for
an update soon with that M1 native support.
Thanks so much for joining me today.
Hope you do well and happy coding.