microsoft / Windows-appsample-photo-editor
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 75 units with 778 lines of code in units (35.0% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (64 lines of code)
    • 8 medium size units (278 lines of code)
    • 10 small units (139 lines of code)
    • 56 very small units (297 lines of code)
0% | 8% | 35% | 17% | 38%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
cpp0% | 9% | 42% | 21% | 26%
h0% | 0% | 0% | 0% | 100%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
PhotoEditor0% | 8% | 35% | 17% | 38%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
void DetailPage::PrepareSelectedEffects()
in PhotoEditor/DetailPage.cpp
64 9 0
void DetailPage::CreateEffectsGraph()
in PhotoEditor/DetailPage.cpp
44 9 0
IAsyncAction DetailPage::OnNavigatedTo()
in PhotoEditor/DetailPage.cpp
41 11 1
IAsyncAction MainPage::GetItemsAsync()
in PhotoEditor/MainPage.cpp
39 6 0
37 5 2
void DetailPage::TextBlock_Tapped()
in PhotoEditor/DetailPage.cpp
36 9 2
void DetailPage::UpdateEffectBrush()
in PhotoEditor/DetailPage.cpp
34 9 1
void DetailPage::InitializeEffectPreviews()
in PhotoEditor/DetailPage.cpp
25 1 0
IAsyncAction DetailPage::SaveButton_Click()
in PhotoEditor/DetailPage.cpp
22 3 2
void DetailPage::InitializeEffects()
in PhotoEditor/DetailPage.cpp
20 1 0
Frame App::CreateRootFrame()
in PhotoEditor/App.cpp
16 3 0
void DetailPage::UpdatePanelState()
in PhotoEditor/DetailPage.cpp
15 3 0
void DetailPage::UpdateButtonImageBrush()
in PhotoEditor/DetailPage.cpp
14 1 0
14 1 2
void DetailPage::UpdateMainImageBrush()
in PhotoEditor/DetailPage.cpp
14 1 0
void DetailPage::ApplyEffects()
in PhotoEditor/DetailPage.cpp
12 3 0
12 3 0
void DetailPage::UpdateZoomState()
in PhotoEditor/DetailPage.cpp
11 2 0
11 1 0
void DetailPage::ResetEffects()
in PhotoEditor/DetailPage.cpp
10 1 0