volume is directly proportional to temperature.

Oooops... I made a mistake. Sorry, here's a better explanation:

In isobaric compression, heat is transferred to or from the system to ensure that the pressure remains constant as the gas performs work or has work done on it

i) \(\displaystyle P_2 = P_1\) and;

ii) \(\displaystyle \frac{V_1}{T_1} = \frac{V_2}{T_2}\)

So... if you decrease the volume (\(\displaystyle V_2 < V_1\)), then temperature decreases.

However, if we instead consider "Adiabatic compression", where no heat is transferred to or from the system (Q = 0), the formula describing adiabatic compression is not given by the ideal gas law (even for an ideal gas). It is given by:

\(\displaystyle TV^{\gamma-1} = \text{constant}.\)

where \(\displaystyle \gamma\) is the ratio of heat capacities and is 1.66 for an ideal gas. We can do a similar set of mathematics above to obtain

\(\displaystyle T_1 V_1^{0.66} = T_2 V_2^{0.66}\)

So we get a different behaviour... because \(\displaystyle V_2\) is smaller than \(\displaystyle V_1\), \(\displaystyle T_2\) must increase.

So... the impact on the state of the gas depends on the kind of transition that is being done because there are three state variables in the formula, not two. You can use the ideal gas law to determine what the corresponding pressures are for those two states.