If you are trying to print to a Windows printer shared over samba, you have to make the following changes:

1) Edit /etc/default/ufw and change the last line from:

Code:
IPT_MODULES="nf_conntrack_ftp nf_nat_ftp nf_conntrack_irc nf_nat_irc"
To:

Code:
IPT_MODULES="nf_conntrack_ftp nf_nat_ftp nf_conntrack_irc nf_nat_irc nf_conntrack_netbios_ns"
2) Create the following rules:

Code:
sudo ufw allow proto udp from 192.168.0.0/16 to any port 137
sudo ufw allow proto udp from 192.168.0.0/16 to any port 631